mirror of
https://github.com/YunoHost-Apps/django_example_ynh.git
synced 2024-09-03 18:26:21 +02:00
Fix file permissions
This commit is contained in:
parent
131346524e
commit
d922d27119
3 changed files with 11 additions and 11 deletions
|
@ -105,7 +105,7 @@ ynh_script_progression --message="Install project via pip..." --weight=80
|
||||||
|
|
||||||
python3 -m venv "${final_path}/venv"
|
python3 -m venv "${final_path}/venv"
|
||||||
cp ../conf/requirements.txt "$final_path/requirements.txt"
|
cp ../conf/requirements.txt "$final_path/requirements.txt"
|
||||||
chown -R "$app" "$final_path"
|
chown -R "$app:" "$final_path"
|
||||||
|
|
||||||
#run source in a 'sub shell'
|
#run source in a 'sub shell'
|
||||||
(
|
(
|
||||||
|
@ -204,9 +204,9 @@ yunohost service add $app --description="Web based management to catalog things"
|
||||||
#=================================================
|
#=================================================
|
||||||
|
|
||||||
# Set permissions to app files
|
# Set permissions to app files
|
||||||
chown -R "$app" "$log_path"
|
chown -R "$app:" "$log_path"
|
||||||
chown -R "$app" "$public_path"
|
chown -R "$app:" "$public_path"
|
||||||
chown -R "$app" "$final_path"
|
chown -R "$app:" "$final_path"
|
||||||
|
|
||||||
#=================================================
|
#=================================================
|
||||||
# SETUP SYSTEMD
|
# SETUP SYSTEMD
|
||||||
|
|
|
@ -70,8 +70,8 @@ ynh_system_user_create --username=$app --home_dir="$final_path" --use_shell
|
||||||
#=================================================
|
#=================================================
|
||||||
|
|
||||||
# Restore permissions on app files
|
# Restore permissions on app files
|
||||||
chown -R "$app" "$public_path"
|
chown -R "$app:" "$public_path"
|
||||||
chown -R "$app" "$final_path"
|
chown -R "$app:" "$final_path"
|
||||||
|
|
||||||
#=================================================
|
#=================================================
|
||||||
# SPECIFIC RESTORATION
|
# SPECIFIC RESTORATION
|
||||||
|
@ -112,7 +112,7 @@ yunohost service add $app --description="Web based management to catalog things"
|
||||||
|
|
||||||
mkdir -p "$log_path"
|
mkdir -p "$log_path"
|
||||||
touch "${log_file}"
|
touch "${log_file}"
|
||||||
chown -R "$app" "$log_path"
|
chown -R "$app:" "$log_path"
|
||||||
ynh_restore_file --origin_path="/etc/logrotate.d/$app"
|
ynh_restore_file --origin_path="/etc/logrotate.d/$app"
|
||||||
|
|
||||||
#=================================================
|
#=================================================
|
||||||
|
|
|
@ -89,7 +89,7 @@ ynh_script_progression --message="Upgrade project via pip..." --weight=80
|
||||||
|
|
||||||
python3 -m venv "${final_path}/venv"
|
python3 -m venv "${final_path}/venv"
|
||||||
cp ../conf/requirements.txt "$final_path/requirements.txt"
|
cp ../conf/requirements.txt "$final_path/requirements.txt"
|
||||||
chown -R "$app" "$final_path"
|
chown -R "$app:" "$final_path"
|
||||||
|
|
||||||
#run source in a 'sub shell'
|
#run source in a 'sub shell'
|
||||||
(
|
(
|
||||||
|
@ -196,9 +196,9 @@ yunohost service add $app --description="Web based management to catalog things"
|
||||||
#=================================================
|
#=================================================
|
||||||
|
|
||||||
# Set permissions to app files
|
# Set permissions to app files
|
||||||
chown -R "$app" "$log_path"
|
chown -R "$app:" "$log_path"
|
||||||
chown -R "$app" "$public_path"
|
chown -R "$app:" "$public_path"
|
||||||
chown -R "$app" "$final_path"
|
chown -R "$app:" "$final_path"
|
||||||
|
|
||||||
#=================================================
|
#=================================================
|
||||||
# Start django_example_ynh via systemd
|
# Start django_example_ynh via systemd
|
||||||
|
|
Loading…
Add table
Reference in a new issue