Limit access to backup files

This commit is contained in:
Jeremy Gardais 2021-04-12 16:45:18 +02:00
parent a032babff6
commit de9548d9e9
Signed by: jegardai
GPG Key ID: E759BAA22501AF32
1 changed files with 5 additions and 0 deletions

View File

@ -120,6 +120,11 @@ main() { # {{{
ln --force -- "${local_bkp_dir}/pve.${TODAY_VAR}.tar.gz" "${local_bkp_dir}/pve.latest.tar.gz" \
|| exit 3
## }}}
## Fix backups permissions {{{
### Only readable by backup (user) and adm (group)
chown -R backup:adm -- "${local_bkp_dir}" \
&& chmod 'u+rwX,g+rX,o-rwx' -R -- "${local_bkp_dir}"
## }}}
}
# }}}