NixOS-Config/nixos/server/package-configs/cinny/default.nix

32 lines
583 B
Nix
Raw Normal View History

2024-03-31 22:06:47 +02:00
{
config,
pkgs,
inputs,
lib,
...
}: let
port = 2143;
in {
virtualisation.oci-containers.containers."cinny" = {
autoStart = true;
ports = ["${toString port}:80"];
image = "cinny:latest";
};
services.nginx = {
enable = true;
virtualHosts = {
"cinny.gladtherescake.eu" = {
## Force HTTP redirect to HTTPS
forceSSL = true;
## LetsEncrypt
enableACME = true;
locations."/" = {
proxyPass = "http://localhost:${toString port}";
proxyWebsockets = true;
};
};
};
};
}