feat(OVHCloud): Setup example caddy virtualHost

This commit is contained in:
GaspardCulis 2024-09-27 15:41:13 +02:00
parent 4283a215a1
commit 000b708e81

View file

@ -1,5 +1,6 @@
{ {
modulesPath, modulesPath,
config,
inputs, inputs,
pkgs, pkgs,
... ...
@ -22,11 +23,20 @@
}; };
# Proxy # Proxy
environment.systemPackages = with pkgs; [
nss.tools
];
services.caddy = { services.caddy = {
enable = true; enable = true;
package = inputs.caddy.packages.${pkgs.system}.caddy; package = inputs.caddy.packages.${pkgs.system}.caddy;
virtualHosts."localhost".extraConfig = '' virtualHosts."siuu.gasdev.fr".extraConfig = ''
respond "Hello, world!" respond "Hello, world!"
''; '';
}; };
systemd.services.caddy = {
serviceConfig = {
EnvironmentFile = config.sops.templates."caddy.env".path;
};
};
} }