pomerium: use /var/lib/pomerium for autocert state

This commit is contained in:
Luke Granger-Brown 2020-12-28 17:12:06 +00:00
parent 8ed1d0665e
commit 8956bc3207

View file

@ -30,9 +30,12 @@ with lib;
after = [ "network.target" ];
wantedBy = [ "multi-user.target" ];
Environment.AUTOCERT_DIR = "/var/lib/pomerium/autocert";
serviceConfig = {
DynamicUser = true;
ExecStart = pkgs.writeShellScript "run-pomerium" ''
mkdir -p "$AUTOCERT_DIR"
if [[ -v CREDENTIALS_DIRECTORY ]]; then
cd "$CREDENTIALS_DIRECTORY"
fi