mirror of
https://github.com/YunoHost-Apps/synapse_ynh.git
synced 2024-09-03 20:26:38 +02:00
Fix package linter and update install badge
This commit is contained in:
parent
5d67006818
commit
bf5e61c816
3 changed files with 14 additions and 14 deletions
|
@ -3,7 +3,7 @@
|
|||
![](https://matrix.org/blog/wp-content/uploads/2015/01/logo1.png)
|
||||
|
||||
[![Integration level](https://dash.yunohost.org/integration/synapse.svg)](https://dash.yunohost.org/appci/app/synapse) ![](https://ci-apps.yunohost.org/ci/badges/synapse.status.svg) ![](https://ci-apps.yunohost.org/ci/badges/synapse.maintain.svg)
|
||||
[![Install Synapse with YunoHost](https://install-app.yunohost.org/install-with-yunohost.png)](https://install-app.yunohost.org/?app=synapse)
|
||||
[![Install Synapse with YunoHost](https://install-app.yunohost.org/install-with-yunohost.svg)](https://install-app.yunohost.org/?app=synapse)
|
||||
|
||||
> *This package allows you to install Synapse quickly and simply on a YunoHost server.
|
||||
If you don't have YunoHost, please see [here](https://yunohost.org/#/install) to know how to install and enjoy it.*
|
||||
|
|
|
@ -20,7 +20,7 @@ ynh_abort_if_errors
|
|||
#=================================================
|
||||
# LOAD SETTINGS
|
||||
#=================================================
|
||||
ynh_script_progression --message="Loading installation settings..." --weight=2
|
||||
ynh_print_info --message="Loading installation settings..."
|
||||
|
||||
app=$YNH_APP_INSTANCE_NAME
|
||||
|
||||
|
@ -48,7 +48,7 @@ data_path="/home/yunohost.app/matrix-$app"
|
|||
#=================================================
|
||||
# BACKUP THE APP MAIN DIR
|
||||
#=================================================
|
||||
ynh_script_progression --message="Backing up the main app directory..." --weight=1
|
||||
ynh_print_info --message="Backing up the main app directory..."
|
||||
|
||||
ynh_backup --src_path="$final_path"
|
||||
ynh_backup --src_path="$final_www_path"
|
||||
|
@ -56,7 +56,7 @@ ynh_backup --src_path="$final_www_path"
|
|||
#=================================================
|
||||
# BACKUP THE NGINX CONFIGURATION
|
||||
#=================================================
|
||||
ynh_script_progression --message="Backing up nginx web server configuration..." --weight=1
|
||||
ynh_print_info --message="Backing up nginx web server configuration..."
|
||||
|
||||
# BACKUP THE PHP-FPM CONFIGURATION
|
||||
ynh_backup --src_path "/etc/php/7.0/fpm/pool.d/$app.conf"
|
||||
|
@ -70,14 +70,14 @@ fi
|
|||
#=================================================
|
||||
# BACKUP THE POSTGRESQL DATABASE
|
||||
#=================================================
|
||||
ynh_script_progression --message="Backing up the PostgreSQL database..." --weight=2
|
||||
ynh_print_info --message="Backing up the PostgreSQL database..."
|
||||
|
||||
ynh_psql_dump_db --database="$synapse_db_name" > ${YNH_CWD}/dump.sql
|
||||
|
||||
#=================================================
|
||||
# BACKUP FAIL2BAN CONFIGURATION
|
||||
#=================================================
|
||||
ynh_script_progression --message="Backing up fail2ban configuration" --weight=1
|
||||
ynh_print_info --message="Backing up fail2ban configuration"
|
||||
|
||||
ynh_backup --src_path="/etc/fail2ban/jail.d/$app.conf"
|
||||
ynh_backup --src_path="/etc/fail2ban/filter.d/$app.conf"
|
||||
|
@ -87,14 +87,14 @@ ynh_backup --src_path="/etc/fail2ban/filter.d/$app.conf"
|
|||
#=================================================
|
||||
# BACKUP SYNAPSE CONFIG
|
||||
#=================================================
|
||||
ynh_script_progression --message="Backing up synapse configuration..." --weight=2
|
||||
ynh_print_info --message="Backing up synapse configuration..."
|
||||
|
||||
ynh_backup --src_path="/etc/matrix-$app"
|
||||
|
||||
#=================================================
|
||||
# BACKUP SYSTEMD
|
||||
#=================================================
|
||||
ynh_script_progression --message="Backing up systemd configuration..." --weight=1
|
||||
ynh_print_info --message="Backing up systemd configuration..."
|
||||
|
||||
ynh_backup --src_path="/etc/default/matrix-$app"
|
||||
ynh_backup --src_path="/etc/systemd/system/matrix-$app.service"
|
||||
|
@ -104,21 +104,21 @@ ynh_backup --src_path="/etc/systemd/system/coturn-$app.service"
|
|||
#=================================================
|
||||
# BACKUP SYNAPSE DATA
|
||||
#=================================================
|
||||
ynh_script_progression --message="Backing up synapse data..." --weight=1
|
||||
ynh_print_info --message="Backing up synapse data..."
|
||||
|
||||
ynh_backup --src_path="$data_path" --is_big=1
|
||||
|
||||
#=================================================
|
||||
# BACKUP SYNAPSE LOG
|
||||
#=================================================
|
||||
ynh_script_progression --message="Backing up synapse log..." --weight=1
|
||||
ynh_print_info --message="Backing up synapse log..."
|
||||
|
||||
ynh_backup --src_path="/var/log/matrix-$app"
|
||||
|
||||
#=================================================
|
||||
# BACKUP HOOKS
|
||||
#=================================================
|
||||
ynh_script_progression --message="Backing up synapse hook..." --weight=1
|
||||
ynh_print_info --message="Backing up synapse hook..."
|
||||
|
||||
# Copy hook
|
||||
ynh_backup --src_path "/etc/yunohost/hooks.d/post_cert_update/50-$app"
|
||||
|
@ -127,4 +127,4 @@ ynh_backup --src_path "/etc/yunohost/hooks.d/post_cert_update/50-$app"
|
|||
# END OF SCRIPT
|
||||
#=================================================
|
||||
|
||||
ynh_script_progression --message="Backup script completed for $app. (YunoHost will then actually copy those files to the archive)." --last
|
||||
ynh_print_info --message="Backup script completed for $app. (YunoHost will then actually copy those files to the archive)."
|
||||
|
|
|
@ -128,8 +128,8 @@ ynh_psql_execute_file_as_root --file="${YNH_CWD}/dump.sql" --database="$synapse_
|
|||
ynh_script_progression --message="Enable systemd services" --weight=2
|
||||
|
||||
# systemctl daemon-reload
|
||||
systemctl enable matrix-$app.service
|
||||
systemctl enable coturn-$app.service
|
||||
systemctl enable matrix-$app.service --quiet
|
||||
systemctl enable coturn-$app.service --quiet
|
||||
|
||||
#=================================================
|
||||
# ADVERTISE SERVICE IN ADMIN PANEL
|
||||
|
|
Loading…
Reference in a new issue