diff options
author | Maxim Devaev <[email protected]> | 2022-06-24 18:25:08 +0300 |
---|---|---|
committer | Maxim Devaev <[email protected]> | 2022-06-24 18:25:08 +0300 |
commit | bd5676222bb75c8b737e61169545fe7c3028c41c (patch) | |
tree | 497892f01fefdf88ccb1102c9427fbb63a9086c0 /kvmd.install | |
parent | 9e6edd0cd76bb43abf4f500fd3cd08e473d60a56 (diff) |
fixed permissions again
Diffstat (limited to 'kvmd.install')
-rw-r--r-- | kvmd.install | 11 |
1 files changed, 8 insertions, 3 deletions
diff --git a/kvmd.install b/kvmd.install index 2241db4a..6f3339e1 100644 --- a/kvmd.install +++ b/kvmd.install @@ -34,9 +34,14 @@ post_upgrade() { for target in nginx vnc; do chown root:root /etc/kvmd/$target/ssl - chown root:kvmd-$target /etc/kvmd/$target/ssl/* - chmod 440 /etc/kvmd/$target/ssl/server.key - chmod 444 /etc/kvmd/$target/ssl/server.crt + if [ -f /etc/kvmd/$target/ssl/server.key ]; then + chown root:kvmd-$target /etc/kvmd/$target/ssl/server.key + chmod 440 /etc/kvmd/$target/ssl/server.key + fi + if [ -f /etc/kvmd/$target/ssl/server.crt ]; then + chown root:kvmd-$target /etc/kvmd/$target/ssl/server.crt + chmod 444 /etc/kvmd/$target/ssl/server.crt + fi done echo "==> Patching configs ..." |