1
0
Fork 0
mirror of https://github.com/YunoHost-Apps/jellyfin_ynh.git synced 2024-09-03 19:26:29 +02:00

Wait for the service starting up

This commit is contained in:
tituspijean 2020-11-08 18:13:51 +01:00
parent e0ed7b183b
commit 0f07898dbb
3 changed files with 5 additions and 7 deletions

View file

@ -92,9 +92,8 @@ ynh_system_user_create --username=$app
# Load services once to generate system.xml # Load services once to generate system.xml
systemctl enable jellyfin systemctl enable jellyfin
systemctl start jellyfin ynh_systemd_action --service_name=$app --action="start" --log_path="/var/log/$app/$app$(date "+%Y%m%d").log" --line_match="Startup complete"
sleep 5 ynh_systemd_action --service_name=$app --action="stop"
systemctl stop jellyfin
# Port config # Port config
ynh_replace_string --match_string="<HttpServerPortNumber>8096</HttpServerPortNumber>" --replace_string="<HttpServerPortNumber>$port</HttpServerPortNumber>" --target_file="/etc/jellyfin/system.xml" ynh_replace_string --match_string="<HttpServerPortNumber>8096</HttpServerPortNumber>" --replace_string="<HttpServerPortNumber>$port</HttpServerPortNumber>" --target_file="/etc/jellyfin/system.xml"
@ -136,8 +135,7 @@ yunohost service add $app --description "Jellyfin media center" --log "/var/log/
ynh_script_progression --message="Starting a systemd service..." --weight=1 ynh_script_progression --message="Starting a systemd service..." --weight=1
# Start a systemd service # Start a systemd service
ynh_systemd_action --service_name=$app --action="start" --log_path="/var/log/$app/$app.log" ynh_systemd_action --service_name=$app --action="start" --log_path="/var/log/$app/$app$(date "+%Y%m%d").log" --line_match="Startup complete"
sleep 5
#================================================= #=================================================
# SETUP SSOWAT # SETUP SSOWAT

View file

@ -107,7 +107,7 @@ yunohost service add $app --description "Jellyfin media center" --log "/var/log/
#================================================= #=================================================
ynh_script_progression --message="Starting a systemd service..." --weight=1 ynh_script_progression --message="Starting a systemd service..." --weight=1
ynh_systemd_action --service_name=$app --action="start" --log_path="/var/log/$app/$app.log" ynh_systemd_action --service_name=$app --action="start" --log_path="/var/log/$app/$app$(date "+%Y%m%d").log" --line_match="Startup complete"
#================================================= #=================================================
# RESTORE THE LOGROTATE CONFIGURATION # RESTORE THE LOGROTATE CONFIGURATION

View file

@ -103,7 +103,7 @@ yunohost service add $app --description "Jellyfin media center" --log "/var/log/
#================================================= #=================================================
ynh_script_progression --message="Starting a systemd service..." --weight=1 ynh_script_progression --message="Starting a systemd service..." --weight=1
ynh_systemd_action --service_name=$app --action="start" --log_path="/var/log/$app/$app.log" ynh_systemd_action --service_name=$app --action="start" --log_path="/var/log/$app/$app$(date "+%Y%m%d").log" --line_match="Startup complete"
#================================================= #=================================================
# RELOAD NGINX # RELOAD NGINX