Deploy Pelican blog on NixOS server

Local

Testing pelican blog:

pelican content && pelican --listen

Development server will be at http://127.0.0.1:8000/

Deployement

Copy output/ folder to server:

rsync -avc --delete output/ philippe@MICROSERVER:/var/www/nphilou.fr

Generate + copy combo:

pelican content && rsync -avc --delete output/ philippe@MICROSERVER:/var/www/nphilou.fr

Remotely:

pelican content && rsync -avc -e 'ssh' --delete output/ philippe@nphilou.fr:/var/www/nphilou.fr

Edit configuration.nix:

services.nginx = {
    enable = true;
    virtualHosts = {
        "nphilou.fr" = {
            root = "/var/www/nphilou.fr";
        };
    };
};