Ownership of ghost binary

This commit is contained in:
Bob Mottram 2017-08-07 10:51:21 +01:00
parent 079c5acc78
commit 0ee00f775c
1 changed files with 6 additions and 0 deletions

View File

@ -200,6 +200,9 @@ function upgrade_ghost {
ghost_replace_services ghost_replace_services
ghost_remove_offsite_links ghost_remove_offsite_links
if [ -f /usr/local/bin/ghost ]; then
chown root:root /usr/local/bin/ghost
fi
chown -R ghost: /var/www/${GHOST_DOMAIN_NAME}/htdocs chown -R ghost: /var/www/${GHOST_DOMAIN_NAME}/htdocs
systemctl restart ghost systemctl restart ghost
} }
@ -526,6 +529,9 @@ function install_ghost {
function_check add_ddns_domain function_check add_ddns_domain
add_ddns_domain $GHOST_DOMAIN_NAME add_ddns_domain $GHOST_DOMAIN_NAME
if [ -f /usr/local/bin/ghost ]; then
chown root:root /usr/local/bin/ghost
fi
chown -R ghost: /var/www/${GHOST_DOMAIN_NAME}/htdocs chown -R ghost: /var/www/${GHOST_DOMAIN_NAME}/htdocs
set_completion_param "ghost domain" "$GHOST_DOMAIN_NAME" set_completion_param "ghost domain" "$GHOST_DOMAIN_NAME"
if ! grep -q "ghost version:" ${COMPLETION_FILE}; then if ! grep -q "ghost version:" ${COMPLETION_FILE}; then