tarsnap: fix up permissions of existing cache directories
commit5ccbfb2dcce22000cc279f92a9e357f11af9fe77
authorAristid Breitkreuz <aristidb@gmail.com>
dateMon 4 May 2015, 18:58 (12 years ago)
parent3e17d6e
nixos/modules/services/backup/tarsnap.nix+2
@@ -249,6 +249,8 @@ in
249249 script = ''
250250 mkdir -p -m 0755 ${dirOf cfg.cachedir}
251251 mkdir -p -m 0700 ${cfg.cachedir}
252+ chown root:root ${cfg.cachedir}
253+ chmod 0700 ${cfg.cachedir}
252254 DIRS=`cat /etc/tarsnap/$1.dirs`
253255 exec tarsnap --configfile /etc/tarsnap/$1.conf -c -f $1-$(date +"%Y%m%d%H%M%S") $DIRS
254256 '';