Remove useless user rights

pull/6/head
Jean-Baptiste Holcroft 7 years ago
parent 333e0973e6
commit 23645f9f33

@ -4,13 +4,13 @@
domain="domain.tld" (DOMAIN)
path="/path" (PATH)
; Checks
pkg_linter=0
setup_sub_dir=0
setup_root=0
pkg_linter=1
setup_sub_dir=1
setup_root=1
setup_nourl=0
setup_private=0
setup_public=0
upgrade=0
setup_public=1
upgrade=1
# test upgrade from latest published version
upgrade=1 from_commit=fd6350495d5a1d864ae30e1a61e18939fdb6a428
# test upgrade from latest git commit before Jibec's rewriting

@ -11,5 +11,5 @@ location __PATH__ {
uwsgi_read_timeout 3600;
uwsgi_param SCRIPT_NAME __PATH__;
uwsgi_modifier1 30;
uwsgi_pass unix://__FINALPATH__/socket;
uwsgi_pass unix:///tmp/__NAME__.socket;
}

@ -2,7 +2,7 @@
plugins = python
master = true
protocol = uwsgi
socket = __FINALPATH__/socket
socket = /tmp/__APP__.socket
virtualenv = __FINALPATH__/local
wsgi-file = __FINALPATH__/syncserver.wsgi
python-path = __FINALPATH__/local

@ -10,7 +10,7 @@ RemainAfterExit=yes
WorkingDirectory=__FINALPATH__
ExecStart=/usr/bin/uwsgi \
--ini __FINALPATH__/syncserver.ini \
--socket __FINALPATH__/socket
--socket /tmp/__APP__.socket
Restart=always
StandardError=syslog

@ -126,6 +126,7 @@ ynh_app_setting_set "$app" secret "$secret"
# Copy Files
cp ../conf/syncserver.ini "$final_path/syncserver.ini"
ynh_replace_string "__APP__" "$app" "$final_path/syncserver.ini"
ynh_replace_string "__DOMAIN__" "$domain" "$final_path/syncserver.ini"
ynh_replace_string "__PATH__" "$path_url" "$final_path/syncserver.ini"
ynh_replace_string "__NAME__" "$app" "$final_path/syncserver.ini"
@ -160,9 +161,7 @@ ynh_replace_string "__DB_NAME__" "$db_name" "$final_path/syncserver.ini"
# SECURE FILES AND DIRECTORIES
#=================================================
chown "$app":"$app" -R "$final_path"
find "$final_path"/ -type d -exec chmod 2755 {} \;
find "$final_path"/ -type f -exec chmod g+r,o+r {} \;
# no need, keep the default root:root
#=================================================
# SETUP LOGROTATE

@ -74,9 +74,7 @@ ynh_system_user_create "$app"
# RESTORE USER RIGHTS
#=================================================
chown "$app":"$app" -R "$final_path"
find "$final_path"/ -type d -exec chmod 2755 {} \;
find "$final_path"/ -type f -exec chmod g+r,o+r {} \;
# no need, keep the default root:root
#=================================================
# SPECIFIC RESTORATION

@ -127,6 +127,7 @@ ynh_system_user_create "$app"
# Copy Files
cp ../conf/syncserver.ini "$final_path/syncserver.ini"
ynh_replace_string "__APP__" "$app" "$final_path/syncserver.ini"
ynh_replace_string "__DOMAIN__" "$domain" "$final_path/syncserver.ini"
ynh_replace_string "__PATH__" "$path_url" "$final_path/syncserver.ini"
ynh_replace_string "__NAME__" "$app" "$final_path/syncserver.ini"
@ -143,9 +144,7 @@ ynh_replace_string "__DB_NAME__" "$db_name" "$final_path/syncserver.ini"
# SECURE FILES AND DIRECTORIES
#=================================================
chown "$app":"$app" -R "$final_path"
find "$final_path"/ -type d -exec chmod 2755 {} \;
find "$final_path"/ -type f -exec chmod g+r,o+r {} \;
# no need, keep the default root:root
#=================================================
# SETUP LOGROTATE

Loading…
Cancel
Save