fix runDir startup

pull/16/head
Brian Picciano 3 years ago
parent 624a38af2b
commit 9a9b94e677
  1. 10
      default.nix

@ -78,7 +78,13 @@
entrypoint = pkgs.writeScript "mediocre-blog-entrypoint" '' entrypoint = pkgs.writeScript "mediocre-blog-entrypoint" ''
#!/bin/sh #!/bin/sh
mkdir -p ${config.runDir}
set -e
if [ ! -d ${config.runDir} ]; then
mkdir -p ${config.runDir}
fi
mkdir -p ${config.dataDir} mkdir -p ${config.dataDir}
exec ${pkgs.circus}/bin/circusd ${circusCfg} exec ${pkgs.circus}/bin/circusd ${circusCfg}
''; '';
@ -93,6 +99,8 @@
Restart=always Restart=always
RestartSec=1s RestartSec=1s
User=mediocregopher User=mediocregopher
Group=mediocregopher
RuntimeDirectory=mediocre-blog
ExecStart=${entrypoint} ExecStart=${entrypoint}
[Install] [Install]

Loading…
Cancel
Save