1
0
Fork 0
mirror of https://github.com/YunoHost-Apps/freescout_ynh.git synced 2024-09-03 18:36:23 +02:00

Merge pull request #47 from YunoHost-Apps/ci-auto-update-1.8.144

Upgrade to v1.8.144
This commit is contained in:
Salamandar 2024-06-19 22:36:57 +02:00 committed by GitHub
commit 40bd3bd93b
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
13 changed files with 62 additions and 93 deletions

View file

@ -18,7 +18,7 @@ It shall NOT be edited by hand.
FreeScout is the super lightweight and powerful free open source help desk and shared inbox built with PHP (Laravel framework). Now you can enjoy free Zendesk & Help Scout without giving up privacy or locking yourself into a service you don't control.
**Shipped version:** 1.8.143~ynh1
**Shipped version:** 1.8.144~ynh1
**Demo:** <https://demo.freescout.net/login>

View file

@ -18,7 +18,7 @@ No se debe editar a mano.
FreeScout is the super lightweight and powerful free open source help desk and shared inbox built with PHP (Laravel framework). Now you can enjoy free Zendesk & Help Scout without giving up privacy or locking yourself into a service you don't control.
**Versión actual:** 1.8.143~ynh1
**Versión actual:** 1.8.144~ynh1
**Demo:** <https://demo.freescout.net/login>

View file

@ -18,7 +18,7 @@ EZ editatu eskuz.
FreeScout is the super lightweight and powerful free open source help desk and shared inbox built with PHP (Laravel framework). Now you can enjoy free Zendesk & Help Scout without giving up privacy or locking yourself into a service you don't control.
**Paketatutako bertsioa:** 1.8.143~ynh1
**Paketatutako bertsioa:** 1.8.144~ynh1
**Demoa:** <https://demo.freescout.net/login>

View file

@ -18,7 +18,7 @@ Il NE doit PAS être modifié à la main.
FreeScout est un service d'assistance open source gratuit ultra léger et puissant et une boîte de réception partagée construite avec PHP (framework Laravel). Vous pouvez désormais profiter gratuitement de Zendesk et Help Scout sans renoncer à votre confidentialité ni vous enfermer dans un service que vous ne contrôlez pas.
**Version incluse:** 1.8.143~ynh1
**Version incluse:** 1.8.144~ynh1
**Démo:** <https://demo.freescout.net/login>

View file

@ -18,7 +18,7 @@ NON debe editarse manualmente.
FreeScout is the super lightweight and powerful free open source help desk and shared inbox built with PHP (Laravel framework). Now you can enjoy free Zendesk & Help Scout without giving up privacy or locking yourself into a service you don't control.
**Versión proporcionada:** 1.8.143~ynh1
**Versión proporcionada:** 1.8.144~ynh1
**Demo:** <https://demo.freescout.net/login>

View file

@ -18,7 +18,7 @@
FreeScout is the super lightweight and powerful free open source help desk and shared inbox built with PHP (Laravel framework). Now you can enjoy free Zendesk & Help Scout without giving up privacy or locking yourself into a service you don't control.
**分发版本:** 1.8.143~ynh1
**分发版本:** 1.8.144~ynh1
**演示:** <https://demo.freescout.net/login>

View file

@ -7,7 +7,7 @@ name = "FreeScout"
description.en = "Help desk & shared mailbox"
description.fr = "Service d'assistance et boîte aux lettres partagée"
version = "1.8.143~ynh1"
version = "1.8.144~ynh1"
maintainers = []
@ -50,8 +50,8 @@ ram.runtime = "50M"
[resources.sources]
[resources.sources.main]
url = "https://github.com/freescout-helpdesk/freescout/archive/refs/tags/1.8.143.tar.gz"
sha256 = "ee4abf76475d2c4a239bb2c9e05b24a8b7184bdefc753a3478e9db8000d0e128"
url = "https://github.com/freescout-helpdesk/freescout/archive/refs/tags/1.8.144.tar.gz"
sha256 = "fd6c9f01803ee81a5d37c2a116d0a9a614418d354aded9641d7a2db1e1a3a23c"
autoupdate.strategy = "latest_github_tag"
[resources.system_user]

View file

@ -1,7 +1,5 @@
#!/bin/bash
#=================================================
# GENERIC START
#=================================================
# IMPORT GENERIC HELPERS
#=================================================

View file

@ -1,7 +1,5 @@
#!/bin/bash
#=================================================
# GENERIC STARTING
#=================================================
# IMPORT GENERIC HELPERS
#=================================================
@ -9,7 +7,6 @@
source _common.sh
source /usr/share/yunohost/helpers
#=================================================
# MODIFY URL IN NGINX CONF
#=================================================
@ -18,14 +15,14 @@ ynh_script_progression --message="Updating NGINX web server configuration..." --
ynh_change_url_nginx_config
#=================================================
# ADD A CONFIGURATION
# SPECIFIC MODIFICATIONS
#=================================================
ynh_script_progression --message="Adding a configuration file..." --weight=1
ynh_replace_string --match_string="APP_URL=https://$old_domain" --replace_string="APP_URL=https://$new_domain" --target_file=$install_dir/.env
ynh_replace_string --match_string="APP_URL=https://$old_domain" --replace_string="APP_URL=https://$new_domain" \
--target_file="$install_dir/.env"
pushd $install_dir
php$phpversion artisan freescout:clear-cache
pushd "$install_dir"
"php$phpversion" artisan freescout:clear-cache
popd
#=================================================

View file

@ -1,7 +1,5 @@
#!/bin/bash
#=================================================
# GENERIC START
#=================================================
# IMPORT GENERIC HELPERS
#=================================================
@ -9,13 +7,15 @@
source _common.sh
source /usr/share/yunohost/helpers
email=$(ynh_user_get_info --username=$admin --key=mail)
firstname=$(yunohost user list --fields firstname --output-as json | jq -r .users.$admin.firstname)
lastname=$(yunohost user list --fields lastname --output-as json | jq -r .users.$admin.lastname)
#=================================================
# INITIALIZE AND STORE SETTINGS
#=================================================
email=$(ynh_user_get_info --username="$admin" --key="mail")
firstname=$(ynh_user_get_info --username="$admin" --key="firstname")
lastname=$(ynh_user_get_info --username="$admin" --key="lastname")
timezone=$(cat /etc/timezone)
#=================================================
# APP "BUILD" (DEPLOYING SOURCES, VENV, COMPILING ETC)
#=================================================
# DOWNLOAD, CHECK AND UNPACK SOURCE
#=================================================
@ -23,12 +23,20 @@ ynh_script_progression --message="Setting up source files..." --weight=1
ynh_setup_source --dest_dir="$install_dir"
chmod -R o-rwx "$install_dir"
chown -R $app:www-data "$install_dir"
chmod ug=rwX,o-rwx "$install_dir"
chown -R "$app:www-data" "$install_dir"
usermod -g www-data $app
find $install_dir -type f -exec chmod 664 {} \;
find $install_dir -type d -exec chmod 775 {} \;
usermod -g www-data "$app"
#=================================================
# APP INITIAL CONFIGURATION
#=================================================
ynh_script_progression --message="Adding $app's configuration files..." --weight=1
ynh_add_config --template=".env.example" --destination="$install_dir/.env"
chmod 600 "$install_dir/.env"
chown "$app:$app" "$install_dir/.env"
#=================================================
# SYSTEM CONFIGURATION
@ -43,32 +51,20 @@ ynh_add_config --template="cron" --destination="/etc/cron.d/$app"
chown root: "/etc/cron.d/$app"
chmod 644 "/etc/cron.d/$app"
#=================================================
# APP INITIAL CONFIGURATION
#=================================================
# ADD A CONFIGURATION
#=================================================
ynh_script_progression --message="Adding a configuration file..." --weight=1
ynh_add_config --template=".env.example" --destination="$install_dir/.env"
chmod 600 "$install_dir/.env"
chown $app:$app "$install_dir/.env"
#=================================================
# FINAL FREESCOUT INSTALL
#=================================================
ynh_script_progression --message="Install $app" --weight=5
ynh_script_progression --message="Finalizing $app installation..." --weight=1
pushd $install_dir
php$phpversion artisan key:generate --no-interaction --force
php$phpversion artisan freescout:clear-cache
php$phpversion artisan storage:link
php$phpversion artisan migrate --no-interaction --force
php$phpversion artisan freescout:create-user --role=admin --firstName=$firstname --lastName=$lastname --email=$email --password=$password --no-interaction
chgrp -R www-data storage bootstrap/cache public/css/builds public/js/builds
chmod -R ug+rwx storage bootstrap/cache public/css/builds public/js/builds
pushd "$install_dir"
"php$phpversion" artisan key:generate --no-interaction --force
"php$phpversion" artisan freescout:clear-cache
"php$phpversion" artisan storage:link
"php$phpversion" artisan migrate --no-interaction --force
"php$phpversion" artisan freescout:create-user --role="admin" --firstName="$firstname" --lastName="$lastname" --email="$email" --password="$password" --no-interaction
chgrp -R www-data storage bootstrap/cache public/css/builds public/js/builds
chmod -R ug+rwx storage bootstrap/cache public/css/builds public/js/builds
popd
#=================================================

View file

@ -1,7 +1,5 @@
#!/bin/bash
#=================================================
# GENERIC START
#=================================================
# IMPORT GENERIC HELPERS
#=================================================
@ -10,9 +8,7 @@ source _common.sh
source /usr/share/yunohost/helpers
#=================================================
# REMOVE SYSTEM CONFIGURATIONS
#=================================================
# REMOVE SYSTEMD SERVICE
# REMOVE SYSTEMD SERVICE
#=================================================
ynh_script_progression --message="Removing system configurations related to $app..." --weight=1

View file

@ -1,7 +1,5 @@
#!/bin/bash
#=================================================
# GENERIC START
#=================================================
# IMPORT GENERIC HELPERS
#=================================================
@ -17,21 +15,18 @@ ynh_script_progression --message="Restoring the app main directory..." --weight=
ynh_restore_file --origin_path="$install_dir"
chmod -R o-rwx "$install_dir"
chown -R $app:www-data "$install_dir"
chown -R "$app:www-data" "$install_dir"
#=================================================
# RESTORE THE MYSQL DATABASE
#=================================================
ynh_script_progression --message="Restoring the MySQL database..." --weight=1
ynh_mysql_connect_as --user=$db_user --password=$db_pwd --database=$db_name < ./db.sql
ynh_mysql_connect_as --user="$db_user" --password="$db_pwd" --database="$db_name" < ./db.sql
#=================================================
# RESTORE SYSTEM CONFIGURATIONS
#=================================================
# RESTORE THE PHP-FPM CONFIGURATION
#=================================================
ynh_script_progression --message="Restoring system configurations related to $app..." --weight=1
ynh_restore_file --origin_path="/etc/php/$phpversion/fpm/pool.d/$app.conf"
@ -40,14 +35,12 @@ ynh_restore_file --origin_path="/etc/nginx/conf.d/$domain.d/$app.conf"
ynh_restore_file --origin_path="/etc/cron.d/$app"
#=================================================
# GENERIC FINALIZATION
#=================================================
# RELOAD NGINX AND PHP-FPM OR THE APP SERVICE
#=================================================
ynh_script_progression --message="Reloading NGINX web server and $app's service..." --weight=1
ynh_systemd_action --service_name=php$phpversion-fpm --action=reload
ynh_systemd_action --service_name="php$phpversion-fpm" --action=reload
ynh_systemd_action --service_name=nginx --action=reload

View file

@ -1,7 +1,5 @@
#!/bin/bash
#=================================================
# GENERIC START
#=================================================
# IMPORT GENERIC HELPERS
#=================================================
@ -9,23 +7,26 @@
source _common.sh
source /usr/share/yunohost/helpers
email=$(ynh_user_get_info --username=$admin --key=mail)
firstname=$(ynh_user_get_info --username=$admin --key=firstname)
lastname=$(ynh_user_get_info --username=$admin --key=lastname)
#=================================================
# "REBUILD" THE APP (DEPLOY NEW SOURCES, RERUN NPM BUILD...)
# INITIALIZE AND STORE SETTINGS
#=================================================
email=$(ynh_user_get_info --username="$admin" --key="mail")
firstname=$(ynh_user_get_info --username="$admin" --key="firstname")
lastname=$(ynh_user_get_info --username="$admin" --key="lastname")
#=================================================
# DOWNLOAD, CHECK AND UNPACK SOURCE
#=================================================
ynh_script_progression --message="Upgrading source files..." --weight=1
ynh_secure_remove --file="/$install_dir/vendor"
# FIXME: use --full_replace=1
ynh_secure_remove --file="$install_dir/vendor"
ynh_setup_source --dest_dir="$install_dir" # --full_replace=1 --keep='.env'
ynh_setup_source --dest_dir="$install_dir" --keep=".env" #--full_replace=1
chmod -R o-rwx "$install_dir"
chown -R $app:www-data "$install_dir"
chown -R "$app:www-data" "$install_dir"
#=================================================
# REAPPLY SYSTEM CONFIGURATIONS
@ -36,26 +37,14 @@ ynh_add_fpm_config
ynh_add_nginx_config
#=================================================
# RECONFIGURE THE APP (UPDATE CONF, APPLY MIGRATIONS...)
#=================================================
# UPDATE A CONFIG FILE
#=================================================
#ynh_script_progression --message="Updating a configuration file..." --weight=1
#ynh_add_config --template=".env.example" --destination="$install_dir/.env"
#chmod 400 "$install_dir/.env"
#chown $app:$app "$install_dir/.env"
#=================================================
# FINAL FREESCOUT INSTALL
#=================================================
ynh_script_progression --message="Install $app" --weight=5
pushd $install_dir
php$phpversion artisan freescout:clear-cache
php$phpversion artisan migrate --no-interaction --force
pushd "$install_dir"
"php$phpversion" artisan freescout:clear-cache
"php$phpversion" artisan migrate --no-interaction --force
popd
#=================================================