2021-11-18 19:18:16 +01:00
|
|
|
# Machine virtuelle AUDIO
|
2021-11-16 19:39:34 +01:00
|
|
|
|
2021-11-18 19:18:16 +01:00
|
|
|
## Système
|
2021-11-16 19:39:34 +01:00
|
|
|
|
|
|
|
### Matériel virtuel
|
|
|
|
|
2021-11-18 19:18:16 +01:00
|
|
|
CPU : 1
|
|
|
|
RAM : 957384 KB
|
2021-11-16 19:39:34 +01:00
|
|
|
Stockage de masse : 50 Gio
|
2021-11-18 19:18:16 +01:00
|
|
|
Swap : désactivé
|
2021-11-16 19:39:34 +01:00
|
|
|
|
|
|
|
### Logiciel
|
|
|
|
|
|
|
|
Système d'exploitation : Debian GNU/Linux-libre 11 (Bullseye)
|
|
|
|
Noyau : Linux-libre LTS (`linux-libre-lts` des dépôts https://linux-libre.fsfla.org)
|
|
|
|
Sécurités de la maintenance : `etckeeper`, `mollyguard`, `git`, `tig`, `screen`
|
|
|
|
Mail Transfer Agent : `postfix`
|
|
|
|
|
|
|
|
### Caractéristiques notables
|
|
|
|
|
|
|
|
Domaine : dns.libre-en-communs.org
|
2021-11-27 01:18:14 +01:00
|
|
|
Adresse ipv4 publique : 80.67.176.33
|
|
|
|
Adresse ipv4 interne : 192.168.1.186
|
|
|
|
Adresse ipv6 publique : 2001:910:1021::186
|
2021-11-18 19:18:16 +01:00
|
|
|
|
|
|
|
## Serveur web (installation basique)
|
|
|
|
Installation d'un service nginx pour :
|
|
|
|
- la gestion des certificats SSL ;
|
|
|
|
- l'installation d'une page d'information sur comment se connecter au Mumble ;
|
|
|
|
- la possible installation d'un service client web pour Mumble ;
|
|
|
|
- l'éventuel déploiement de StatoolInfos ;
|
|
|
|
- …
|
|
|
|
|
|
|
|
Ouvrir les ports http (80) et https (443) :
|
|
|
|
```
|
|
|
|
ufw allow 'Nginx HTTP'
|
|
|
|
ufw allow 'Nginx HTTPS'
|
|
|
|
```
|
|
|
|
|
|
|
|
Installer les paquets :
|
|
|
|
```
|
|
|
|
apt-get install nginx python3-certbot-nginx
|
|
|
|
```
|
|
|
|
|
|
|
|
Configurer a minima le site web dans `/etc/nginx/sites-available/audio.a-lec.org` :
|
|
|
|
```
|
|
|
|
server
|
|
|
|
{
|
|
|
|
listen 80;
|
|
|
|
listen [::]:80;
|
|
|
|
|
|
|
|
server_name audio.a-lec.org;
|
|
|
|
|
|
|
|
access_log /var/log/nginx/audio.a-lec.org-access.log;
|
|
|
|
error_log /var/log/nginx/audio.a-lec.org-error.log;
|
|
|
|
}
|
|
|
|
```
|
|
|
|
|
|
|
|
Activer la configuration :
|
|
|
|
```
|
|
|
|
cd /etc/nginx/sites-enable/
|
|
|
|
ln -s ../sites-available/audio.a-lec.org
|
|
|
|
```
|
|
|
|
|
|
|
|
Vérifier que c'est bon et recharger :
|
|
|
|
```
|
|
|
|
nginx -t && systemctl reload nginx
|
|
|
|
```
|
|
|
|
|
|
|
|
Configurer le certificat SSl :
|
|
|
|
```
|
|
|
|
certbot --nginx
|
|
|
|
```
|
|
|
|
|
|
|
|
Mettre beau le fichier `/etc/nginx/sites-enabled/audio.a-lec.org` :
|
|
|
|
```
|
|
|
|
server
|
|
|
|
{
|
|
|
|
listen 80;
|
|
|
|
listen [::]:80;
|
|
|
|
|
|
|
|
server_name audio.a-lec.org;
|
|
|
|
|
|
|
|
access_log /var/log/nginx/audio.a-lec.org-access.log;
|
|
|
|
error_log /var/log/nginx/audio.a-lec.org-error.log;
|
|
|
|
|
|
|
|
return 302 https://$host$request_uri;
|
|
|
|
}
|
|
|
|
|
|
|
|
server
|
|
|
|
{
|
|
|
|
set_real_ip_from 192.169.1.1;
|
|
|
|
real_ip_header proxy_protocol;
|
|
|
|
listen [::]:443 ssl ipv6only=on;
|
|
|
|
listen 443 ssl;
|
|
|
|
|
|
|
|
server_name audio.a-lec.org;
|
|
|
|
|
|
|
|
access_log /var/log/nginx/audio.a-lec.org-access.log;
|
|
|
|
error_log /var/log/nginx/audio.a-lec.org-error.log;
|
|
|
|
|
|
|
|
ssl_certificate /etc/letsencrypt/live/audio.a-lec.org/fullchain.pem; # managed by Certbot
|
|
|
|
ssl_certificate_key /etc/letsencrypt/live/audio.a-lec.org/privkey.pem; # managed by Certbot
|
|
|
|
include /etc/letsencrypt/options-ssl-nginx.conf; # managed by Certbot
|
|
|
|
ssl_dhparam /etc/letsencrypt/ssl-dhparams.pem; # managed by Certbot
|
|
|
|
|
|
|
|
root /var/www/audio.a-lec.org;
|
|
|
|
location = /
|
|
|
|
{
|
|
|
|
index index.xhtml;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
```
|
|
|
|
|
|
|
|
Vérifier que c'est bon et recharger :
|
|
|
|
```
|
|
|
|
nginx -t && systemctl reload nginx
|
|
|
|
```
|