zkk / VPS image gallery



Creo il webserver inserendo quanto segue nel file /etc/nginx/sites-avalaible/gallery:

server {
    listen 80;
    listen [::]:80;
    root /var/www/gallery;
    index index.html;
    server_name gallery.max73.it ;
    location / {
	  auth_basic		"Restricted Area";
	  auth_basic_user_file	/etc/nginx/conf.d/htpasswd;
    }
}

Creo la sua directory e lo attivo con la protezione ssl:

mkdir /var/www/gallery
ln -s /etc/nginx/sites-available/gallery /etc/nginx/sites-enabled/
systemctl reload nginx.service
certbot --nginx -d gallery.max73.it
systemctl reload nginx.service

Il sito è gestito da Hugo e caricato tramite rsync.