Skip to content

Commit fd7a8f1

Browse files
lassulusgarbas
lassulus
authored andcommittedMay 11, 2017
nixos/security/acme: fix acme folder permissions
1 parent 8b17444 commit fd7a8f1

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed
 

‎nixos/modules/security/acme.nix

+4-1
Original file line numberDiff line numberDiff line change
@@ -185,12 +185,15 @@ in
185185
path = [ pkgs.simp_le ];
186186
preStart = ''
187187
mkdir -p '${cfg.directory}'
188-
chown -R '${data.user}:${data.group}' '${cfg.directory}'
188+
chown 'root:root' '${cfg.directory}'
189+
chmod 755 '${cfg.directory}'
189190
if [ ! -d '${cpath}' ]; then
190191
mkdir '${cpath}'
191192
fi
192193
chmod ${rights} '${cpath}'
193194
chown -R '${data.user}:${data.group}' '${cpath}'
195+
mkdir -p '${data.webroot}/.well-known/acme-challenge'
196+
chown -R '${data.user}:${data.group}' '${data.webroot}/.well-known/acme-challenge'
194197
'';
195198
script = ''
196199
cd '${cpath}'

0 commit comments

Comments
 (0)
Please sign in to comment.