diff --git a/scripts/upgrade b/scripts/upgrade index 7bb4e81..c454647 100644 --- a/scripts/upgrade +++ b/scripts/upgrade @@ -27,14 +27,8 @@ sudo rm -rf $final_path/* extract_source $final_path # Files owned by root, www-data can just read -sudo find $final_path -type f | xargs sudo chmod 644 -sudo find $final_path -type d | xargs sudo chmod 755 -sudo chown -R root: $final_path - -# except for data and tmp subdir, where www-data must have write permissions -sudo mkdir -p $final_path/{data,tmp} -sudo chown -R www-data:root $final_path/{data,tmp} -sudo chmod 700 $final_path/{data,tmp} +sudo chown www-data:www-data $final_path -R +sudo chmod 755 $final_path -R # Modify Nginx configuration file and copy it to Nginx conf directory sed -i "s@YNH_WWW_PATH@$path@g" ../conf/nginx.conf