mirror of
https://github.com/YunoHost-Apps/homarr_ynh.git
synced 2024-09-03 19:26:00 +02:00
commit
3a37559710
13 changed files with 22 additions and 39 deletions
|
@ -29,7 +29,7 @@ It integrates with the services you use to display information on the homepage (
|
||||||
- Very light-weight and fast.
|
- Very light-weight and fast.
|
||||||
|
|
||||||
|
|
||||||
**Shipped version:** 0.15.3~ynh2
|
**Shipped version:** 0.15.3~ynh3
|
||||||
|
|
||||||
**Demo:** <https://homarr.ajnart.fr/fr>
|
**Demo:** <https://homarr.ajnart.fr/fr>
|
||||||
|
|
||||||
|
|
|
@ -29,7 +29,7 @@ It integrates with the services you use to display information on the homepage (
|
||||||
- Very light-weight and fast.
|
- Very light-weight and fast.
|
||||||
|
|
||||||
|
|
||||||
**Versión actual:** 0.15.3~ynh2
|
**Versión actual:** 0.15.3~ynh3
|
||||||
|
|
||||||
**Demo:** <https://homarr.ajnart.fr/fr>
|
**Demo:** <https://homarr.ajnart.fr/fr>
|
||||||
|
|
||||||
|
|
|
@ -29,7 +29,7 @@ It integrates with the services you use to display information on the homepage (
|
||||||
- Very light-weight and fast.
|
- Very light-weight and fast.
|
||||||
|
|
||||||
|
|
||||||
**Paketatutako bertsioa:** 0.15.3~ynh2
|
**Paketatutako bertsioa:** 0.15.3~ynh3
|
||||||
|
|
||||||
**Demoa:** <https://homarr.ajnart.fr/fr>
|
**Demoa:** <https://homarr.ajnart.fr/fr>
|
||||||
|
|
||||||
|
|
|
@ -28,7 +28,7 @@ Il s'intègre aux services que vous utilisez pour afficher des informations sur
|
||||||
- Des widgets pouvant afficher tous types d'informations.
|
- Des widgets pouvant afficher tous types d'informations.
|
||||||
|
|
||||||
|
|
||||||
**Version incluse :** 0.15.3~ynh2
|
**Version incluse :** 0.15.3~ynh3
|
||||||
|
|
||||||
**Démo :** <https://homarr.ajnart.fr/fr>
|
**Démo :** <https://homarr.ajnart.fr/fr>
|
||||||
|
|
||||||
|
|
|
@ -29,7 +29,7 @@ It integrates with the services you use to display information on the homepage (
|
||||||
- Very light-weight and fast.
|
- Very light-weight and fast.
|
||||||
|
|
||||||
|
|
||||||
**Versión proporcionada:** 0.15.3~ynh2
|
**Versión proporcionada:** 0.15.3~ynh3
|
||||||
|
|
||||||
**Demo:** <https://homarr.ajnart.fr/fr>
|
**Demo:** <https://homarr.ajnart.fr/fr>
|
||||||
|
|
||||||
|
|
|
@ -29,7 +29,7 @@ It integrates with the services you use to display information on the homepage (
|
||||||
- Very light-weight and fast.
|
- Very light-weight and fast.
|
||||||
|
|
||||||
|
|
||||||
**分发版本:** 0.15.3~ynh2
|
**分发版本:** 0.15.3~ynh3
|
||||||
|
|
||||||
**演示:** <https://homarr.ajnart.fr/fr>
|
**演示:** <https://homarr.ajnart.fr/fr>
|
||||||
|
|
||||||
|
|
|
@ -7,7 +7,7 @@ Type=simple
|
||||||
User=__APP__
|
User=__APP__
|
||||||
Group=__APP__
|
Group=__APP__
|
||||||
WorkingDirectory=__INSTALL_DIR__/
|
WorkingDirectory=__INSTALL_DIR__/
|
||||||
Environment="PATH=__ENV_PATH__"
|
Environment="__YNH_NODE_LOAD_PATH__"
|
||||||
Environment="NODE_ENV=production"
|
Environment="NODE_ENV=production"
|
||||||
Environment="PORT=__PORT__"
|
Environment="PORT=__PORT__"
|
||||||
ExecStart=/usr/bin/yarn start
|
ExecStart=/usr/bin/yarn start
|
||||||
|
|
|
@ -5,7 +5,7 @@ name = "Homarr"
|
||||||
description.en = "Customizable browser's home page to interact with your homeserver's Docker containers"
|
description.en = "Customizable browser's home page to interact with your homeserver's Docker containers"
|
||||||
description.fr = "Page d'accueil personnalisable pour interagir avec les conteneurs Docker de votre serveur"
|
description.fr = "Page d'accueil personnalisable pour interagir avec les conteneurs Docker de votre serveur"
|
||||||
|
|
||||||
version = "0.15.3~ynh2"
|
version = "0.15.3~ynh3"
|
||||||
|
|
||||||
maintainers = ["eric_G"]
|
maintainers = ["eric_G"]
|
||||||
|
|
||||||
|
|
|
@ -22,15 +22,11 @@ ynh_print_info --message="Declaring files to be backed up..."
|
||||||
ynh_backup --src_path="$install_dir"
|
ynh_backup --src_path="$install_dir"
|
||||||
|
|
||||||
#=================================================
|
#=================================================
|
||||||
# BACKUP THE NGINX CONFIGURATION
|
# SYSTEM CONFIGURATION
|
||||||
#=================================================
|
#=================================================
|
||||||
|
|
||||||
ynh_backup --src_path="/etc/nginx/conf.d/$domain.d/$app.conf"
|
ynh_backup --src_path="/etc/nginx/conf.d/$domain.d/$app.conf"
|
||||||
|
|
||||||
#=================================================
|
|
||||||
# BACKUP SYSTEMD
|
|
||||||
#=================================================
|
|
||||||
|
|
||||||
ynh_backup --src_path="/etc/systemd/system/$app.service"
|
ynh_backup --src_path="/etc/systemd/system/$app.service"
|
||||||
|
|
||||||
#=================================================
|
#=================================================
|
||||||
|
|
|
@ -32,14 +32,13 @@ chmod -R o-rwx "$install_dir"
|
||||||
chown -R $app:www-data "$install_dir"
|
chown -R $app:www-data "$install_dir"
|
||||||
|
|
||||||
#=================================================
|
#=================================================
|
||||||
# NGINX CONFIGURATION
|
# APP INITIAL CONFIGURATION
|
||||||
#=================================================
|
#=================================================
|
||||||
ynh_script_progression --message="Configuring NGINX web server..." --weight=1
|
ynh_script_progression --message="Adding $app's configuration files..." --weight=1
|
||||||
|
|
||||||
# Create a dedicated NGINX config
|
# Create a dedicated NGINX config
|
||||||
ynh_add_nginx_config
|
ynh_add_nginx_config
|
||||||
|
|
||||||
env_path="$PATH"
|
|
||||||
# Create a dedicated systemd config
|
# Create a dedicated systemd config
|
||||||
ynh_add_systemd_config
|
ynh_add_systemd_config
|
||||||
|
|
||||||
|
|
|
@ -10,10 +10,9 @@ source _common.sh
|
||||||
source /usr/share/yunohost/helpers
|
source /usr/share/yunohost/helpers
|
||||||
|
|
||||||
#=================================================
|
#=================================================
|
||||||
# STANDARD REMOVE
|
# REMOVE SYSTEM CONFIGURATIONS
|
||||||
#=================================================
|
|
||||||
# REMOVE SERVICE INTEGRATION IN YUNOHOST
|
|
||||||
#=================================================
|
#=================================================
|
||||||
|
ynh_script_progression --message="Removing system configurations related to $app..." --weight=1
|
||||||
|
|
||||||
# Remove the service from the list of services known by YunoHost (added from `yunohost service add`)
|
# Remove the service from the list of services known by YunoHost (added from `yunohost service add`)
|
||||||
if ynh_exec_warn_less yunohost service status $app >/dev/null
|
if ynh_exec_warn_less yunohost service status $app >/dev/null
|
||||||
|
|
|
@ -31,9 +31,9 @@ ynh_script_progression --message="Reinstalling dependencies..." --weight=1
|
||||||
ynh_exec_warn_less ynh_install_nodejs --nodejs_version=$nodejs_version
|
ynh_exec_warn_less ynh_install_nodejs --nodejs_version=$nodejs_version
|
||||||
|
|
||||||
#=================================================
|
#=================================================
|
||||||
# RESTORE THE NGINX CONFIGURATION
|
# RESTORE SYSTEM CONFIGURATIONS
|
||||||
#=================================================
|
#=================================================
|
||||||
ynh_script_progression --message="Restoring the NGINX web server configuration..." --weight=1
|
ynh_script_progression --message="Restoring system configurations related to $app..." --weight=1
|
||||||
|
|
||||||
ynh_restore_file --origin_path="/etc/nginx/conf.d/$domain.d/$app.conf"
|
ynh_restore_file --origin_path="/etc/nginx/conf.d/$domain.d/$app.conf"
|
||||||
|
|
||||||
|
@ -43,9 +43,9 @@ systemctl enable $app.service --quiet
|
||||||
yunohost service add $app --description="Customizable browser's home page" --log="/var/log/$app/$app.log"
|
yunohost service add $app --description="Customizable browser's home page" --log="/var/log/$app/$app.log"
|
||||||
|
|
||||||
#=================================================
|
#=================================================
|
||||||
# START SYSTEMD SERVICE
|
# RELOAD NGINX AND PHP-FPM OR THE APP SERVICE
|
||||||
#=================================================
|
#=================================================
|
||||||
ynh_script_progression --message="Starting a systemd service..." --weight=1
|
ynh_script_progression --message="Reloading NGINX web server and $app's service..." --weight=1
|
||||||
|
|
||||||
ynh_systemd_action --service_name=$app --action="start" --log_path="systemd"
|
ynh_systemd_action --service_name=$app --action="start" --log_path="systemd"
|
||||||
|
|
||||||
|
|
|
@ -12,12 +12,6 @@ source /usr/share/yunohost/helpers
|
||||||
secret=$(ynh_string_random --length=24)
|
secret=$(ynh_string_random --length=24)
|
||||||
timezone=$(cat /etc/timezone)
|
timezone=$(cat /etc/timezone)
|
||||||
|
|
||||||
#=================================================
|
|
||||||
# CHECK VERSION
|
|
||||||
#=================================================
|
|
||||||
|
|
||||||
upgrade_type=$(ynh_check_app_version_changed)
|
|
||||||
|
|
||||||
#=================================================
|
#=================================================
|
||||||
# STANDARD UPGRADE STEPS
|
# STANDARD UPGRADE STEPS
|
||||||
#=================================================
|
#=================================================
|
||||||
|
@ -30,14 +24,10 @@ ynh_systemd_action --service_name=$app --action="stop" --log_path="systemd"
|
||||||
#=================================================
|
#=================================================
|
||||||
# DOWNLOAD, CHECK AND UNPACK SOURCE
|
# DOWNLOAD, CHECK AND UNPACK SOURCE
|
||||||
#=================================================
|
#=================================================
|
||||||
|
|
||||||
if [ "$upgrade_type" == "UPGRADE_APP" ]
|
|
||||||
then
|
|
||||||
ynh_script_progression --message="Upgrading source files..." --weight=1
|
ynh_script_progression --message="Upgrading source files..." --weight=1
|
||||||
|
|
||||||
# Download, check integrity, uncompress and patch the source from app.src
|
# Download, check integrity, uncompress and patch the source from app.src
|
||||||
ynh_setup_source --dest_dir="$install_dir" --full_replace=1
|
ynh_setup_source --dest_dir="$install_dir" --full_replace=1
|
||||||
fi
|
|
||||||
|
|
||||||
chmod -R o-rwx "$install_dir"
|
chmod -R o-rwx "$install_dir"
|
||||||
chown -R $app:www-data "$install_dir"
|
chown -R $app:www-data "$install_dir"
|
||||||
|
@ -51,14 +41,13 @@ ynh_script_progression --message="Upgrading dependencies..." --weight=1
|
||||||
ynh_exec_warn_less ynh_install_nodejs --nodejs_version=$nodejs_version
|
ynh_exec_warn_less ynh_install_nodejs --nodejs_version=$nodejs_version
|
||||||
|
|
||||||
#=================================================
|
#=================================================
|
||||||
# NGINX CONFIGURATION
|
# REAPPLY SYSTEM CONFIGURATIONS
|
||||||
#=================================================
|
#=================================================
|
||||||
ynh_script_progression --message="Upgrading NGINX web server configuration..." --weight=1
|
ynh_script_progression --message="Upgrading system configurations related to $app..." --weight=1
|
||||||
|
|
||||||
# Create a dedicated NGINX config
|
# Create a dedicated NGINX config
|
||||||
ynh_add_nginx_config
|
ynh_add_nginx_config
|
||||||
|
|
||||||
env_path="$PATH"
|
|
||||||
# Create a dedicated systemd config
|
# Create a dedicated systemd config
|
||||||
ynh_add_systemd_config
|
ynh_add_systemd_config
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue