diff --git a/conf/config.yaml.default b/conf/config.yaml.default index eae2461..e0b6431 100644 --- a/conf/config.yaml.default +++ b/conf/config.yaml.default @@ -2,7 +2,7 @@ server: # Per default, turtl will listen on all IP addresses # You can choose the IP it will use with this parameter - host: _IP_SERVER__ + host: __PUBLIC_IP4__ port: __PORT__ db: diff --git a/conf/systemd.service b/conf/systemd.service index d1578c1..6936a63 100644 --- a/conf/systemd.service +++ b/conf/systemd.service @@ -9,10 +9,10 @@ User=__APP__ Group=__APP__ WorkingDirectory=__FINALPATH__/ Environment="PATH=__ENV_PATH__" -ExecStart=__YNH_NODE__ __FINALPATH__/entrypoint.sh +ExecStart=__YNH_NODE__ __FINALPATH__/server.js StandardOutput=syslog StandardError=syslog -SyslogIdentifier=turtl +SyslogIdentifier=__APP__ Restart=always RestartSec=10 StartLimitInterval=900 diff --git a/scripts/install b/scripts/install index 5f14a66..e64ef57 100755 --- a/scripts/install +++ b/scripts/install @@ -103,7 +103,6 @@ chown $app:$app $final_path/plugins chmod 750 "$final_path" chmod -R o-rwx "$final_path" chown -R $app:www-data "$final_path" -chmod +x $final_path/entrypoint.sh #================================================= # NGINX CONFIGURATION @@ -144,7 +143,7 @@ chown -R $app:www-data "$datadir" #================================================= ynh_script_progression --message="Adding a configuration file..." --weight=1 -ip_server="$(curl -s ip.yunohost.org)" || true +public_ip4="$(curl -s ip.yunohost.org)" || true ynh_add_config --template="../conf/config.yaml.default" --destination="$final_path/config/config.yaml" chmod 400 "$final_path/config/config.yaml" diff --git a/scripts/upgrade b/scripts/upgrade index 77b7c67..baed730 100755 --- a/scripts/upgrade +++ b/scripts/upgrade @@ -56,9 +56,6 @@ ynh_systemd_action --service_name=$app --action="stop" --log_path="/var/log/$app #================================================= ynh_script_progression --message="Ensuring downward compatibility..." --weight=1 -### If nobody installed your app before 4.1, -### then you may safely remove these lines - # Cleaning legacy permissions if ynh_legacy_permissions_exists; then ynh_legacy_permissions_delete_all