nixos/mailman: fix clearing static files

This commit is contained in:
Linus Heckemann 2020-04-30 08:18:52 +02:00
parent 32c556b039
commit 1b8af3e1ae

View file

@ -334,7 +334,7 @@ in {
requiredBy = [ "mailman-uwsgi.service" ];
restartTriggers = [ config.environment.etc."mailman3/settings.py".source ];
script = ''
find "${settings.STATIC_ROOT}/" -mindepth 1 -delete
[[ -e "${settings.STATIC_ROOT}" ]] && find "${settings.STATIC_ROOT}/" -mindepth 1 -delete
${pythonEnv}/bin/mailman-web migrate
${pythonEnv}/bin/mailman-web collectstatic
${pythonEnv}/bin/mailman-web compress