mirror of
https://github.com/YunoHost-Apps/prosody_ynh.git
synced 2024-09-03 20:15:57 +02:00
cleaning
This commit is contained in:
parent
9ff4a8900c
commit
da1a096d04
6 changed files with 19 additions and 13 deletions
|
@ -1 +1,2 @@
|
||||||
* Prosody will not replace the XMPP service Metronome integrated in YunoHost, it has been implemented for some specific apps that require Prosody
|
* Prosody will not replace the XMPP service Metronome integrated in YunoHost, it has been implemented for some specific apps that require Prosody.
|
||||||
|
|
||||||
|
|
1
doc/ADMIN_fr.md
Normal file
1
doc/ADMIN_fr.md
Normal file
|
@ -0,0 +1 @@
|
||||||
|
* Prosody ne remplacera pas le service XMPP Metronome intégré à YunoHost, il a été implémenté pour certaines applications spécifiques nécessitant Prosody.
|
1
doc/DESCRIPTION_fr.md
Normal file
1
doc/DESCRIPTION_fr.md
Normal file
|
@ -0,0 +1 @@
|
||||||
|
Prosody est un serveur de communication XMPP moderne. Il vise à être facile à installer et à configurer, et efficace avec les ressources système. De plus, pour les développeurs, il vise à être facile à étendre et à fournir un système flexible sur lequel développer rapidement des fonctionnalités supplémentaires ou prototyper de nouveaux protocoles.
|
|
@ -19,8 +19,11 @@ code = "https://hg.prosody.im/"
|
||||||
yunohost = ">= 11.2"
|
yunohost = ">= 11.2"
|
||||||
architectures = "all"
|
architectures = "all"
|
||||||
multi_instance = false
|
multi_instance = false
|
||||||
|
|
||||||
ldap = false
|
ldap = false
|
||||||
|
|
||||||
sso = false
|
sso = false
|
||||||
|
|
||||||
disk = "50M"
|
disk = "50M"
|
||||||
ram.build = "50M"
|
ram.build = "50M"
|
||||||
ram.runtime = "50M"
|
ram.runtime = "50M"
|
||||||
|
|
|
@ -14,8 +14,8 @@ source /usr/share/yunohost/helpers
|
||||||
#=================================================
|
#=================================================
|
||||||
# REMOVE SERVICE INTEGRATION IN YUNOHOST
|
# 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`)
|
|
||||||
if ynh_exec_warn_less yunohost service status $app >/dev/null
|
if ynh_exec_warn_less yunohost service status $app >/dev/null
|
||||||
then
|
then
|
||||||
ynh_script_progression --message="Removing $app service integration..."
|
ynh_script_progression --message="Removing $app service integration..."
|
||||||
|
@ -33,7 +33,7 @@ ynh_remove_logrotate
|
||||||
#=================================================
|
#=================================================
|
||||||
# REMOVE VARIOUS FILES
|
# REMOVE VARIOUS FILES
|
||||||
#=================================================
|
#=================================================
|
||||||
ynh_script_progression --message="Removing various files..."
|
ynh_script_progression --message="Removing various files..." --weight=1
|
||||||
|
|
||||||
# Remove a directory securely
|
# Remove a directory securely
|
||||||
ynh_secure_remove --file="$config_path"
|
ynh_secure_remove --file="$config_path"
|
||||||
|
@ -50,7 +50,7 @@ ynh_secure_remove --file="/usr/bin/prosody-migrator"
|
||||||
#=================================================
|
#=================================================
|
||||||
# ENABLE METRONOME
|
# ENABLE METRONOME
|
||||||
#=================================================
|
#=================================================
|
||||||
ynh_script_progression --message="Enabling Metronome..."
|
ynh_script_progression --message="Enabling Metronome..." --weight=1
|
||||||
|
|
||||||
if systemctl list-unit-files metronome.service &>/dev/null
|
if systemctl list-unit-files metronome.service &>/dev/null
|
||||||
then
|
then
|
||||||
|
@ -62,4 +62,4 @@ fi
|
||||||
# END OF SCRIPT
|
# END OF SCRIPT
|
||||||
#=================================================
|
#=================================================
|
||||||
|
|
||||||
ynh_script_progression --message="Removal of $app completed"
|
ynh_script_progression --message="Removal of $app completed" --last
|
||||||
|
|
|
@ -13,7 +13,7 @@ source /usr/share/yunohost/helpers
|
||||||
#=================================================
|
#=================================================
|
||||||
# DISABLE METRONOME
|
# DISABLE METRONOME
|
||||||
#=================================================
|
#=================================================
|
||||||
ynh_script_progression --message="Disabling Metronome..."
|
ynh_script_progression --message="Disabling Metronome..." --weight=1
|
||||||
|
|
||||||
if systemctl list-unit-files metronome.service &>/dev/null
|
if systemctl list-unit-files metronome.service &>/dev/null
|
||||||
then
|
then
|
||||||
|
@ -24,7 +24,7 @@ fi
|
||||||
#=================================================
|
#=================================================
|
||||||
# RESTORE THE CONFIG DIR
|
# RESTORE THE CONFIG DIR
|
||||||
#=================================================
|
#=================================================
|
||||||
ynh_script_progression --message="Restoring the config directory..."
|
ynh_script_progression --message="Restoring the config directory..." --weight=1
|
||||||
|
|
||||||
ynh_restore_file --origin_path="$config_path"
|
ynh_restore_file --origin_path="$config_path"
|
||||||
|
|
||||||
|
@ -48,7 +48,7 @@ chmod 750 "$config_path/certs"
|
||||||
#=================================================
|
#=================================================
|
||||||
# RESTORE THE DATA DIRECTORY
|
# RESTORE THE DATA DIRECTORY
|
||||||
#=================================================
|
#=================================================
|
||||||
ynh_script_progression --message="Restoring the data directory..."
|
ynh_script_progression --message="Restoring the data directory..." --weight=1
|
||||||
|
|
||||||
ynh_restore_file --origin_path="$data_dir" --not_mandatory
|
ynh_restore_file --origin_path="$data_dir" --not_mandatory
|
||||||
ynh_restore_file --origin_path="/var/lib/$app" --not_mandatory
|
ynh_restore_file --origin_path="/var/lib/$app" --not_mandatory
|
||||||
|
@ -59,7 +59,7 @@ chown -R $app:$app "/var/lib/$app"
|
||||||
#=================================================
|
#=================================================
|
||||||
# RESTORE SYSTEMD
|
# RESTORE SYSTEMD
|
||||||
#=================================================
|
#=================================================
|
||||||
ynh_script_progression --message="Restoring the systemd configuration..."
|
ynh_script_progression --message="Restoring the systemd configuration..." --weight=1
|
||||||
|
|
||||||
ynh_restore_file --origin_path="/etc/systemd/system/$app.service"
|
ynh_restore_file --origin_path="/etc/systemd/system/$app.service"
|
||||||
systemctl enable $app.service --quiet
|
systemctl enable $app.service --quiet
|
||||||
|
@ -67,7 +67,7 @@ systemctl enable $app.service --quiet
|
||||||
#=================================================
|
#=================================================
|
||||||
# RESTORE THE LOGROTATE CONFIGURATION
|
# RESTORE THE LOGROTATE CONFIGURATION
|
||||||
#=================================================
|
#=================================================
|
||||||
ynh_script_progression --message="Restoring the logrotate configuration..."
|
ynh_script_progression --message="Restoring the logrotate configuration..." --weight=1
|
||||||
|
|
||||||
mkdir -p "/var/log/$app"
|
mkdir -p "/var/log/$app"
|
||||||
chmod 750 "/var/log/$app"
|
chmod 750 "/var/log/$app"
|
||||||
|
@ -79,14 +79,14 @@ ynh_restore_file --origin_path="/etc/logrotate.d/$app"
|
||||||
#=================================================
|
#=================================================
|
||||||
# INTEGRATE SERVICE IN YUNOHOST
|
# INTEGRATE SERVICE IN YUNOHOST
|
||||||
#=================================================
|
#=================================================
|
||||||
ynh_script_progression --message="Integrating service in YunoHost..."
|
ynh_script_progression --message="Integrating service in YunoHost..." --weight=1
|
||||||
|
|
||||||
yunohost service add $app --log="/var/log/$app/$app.log"
|
yunohost service add $app --log="/var/log/$app/$app.log"
|
||||||
|
|
||||||
#=================================================
|
#=================================================
|
||||||
# START SYSTEMD SERVICE
|
# START SYSTEMD SERVICE
|
||||||
#=================================================
|
#=================================================
|
||||||
ynh_script_progression --message="Starting a systemd service..."
|
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.log"
|
||||||
|
|
||||||
|
@ -96,4 +96,4 @@ ynh_systemd_action --service_name=$app --action="start" --log_path="/var/log/$ap
|
||||||
# END OF SCRIPT
|
# END OF SCRIPT
|
||||||
#=================================================
|
#=================================================
|
||||||
|
|
||||||
ynh_script_progression --message="Restoration completed for $app"
|
ynh_script_progression --message="Restoration completed for $app" --last
|
||||||
|
|
Loading…
Add table
Reference in a new issue