mirror of
https://github.com/YunoHost-Apps/etherpad_mypads_ynh.git
synced 2024-09-03 18:36:09 +02:00
commit
053e3fee8d
13 changed files with 110 additions and 26 deletions
|
@ -1,6 +1,6 @@
|
|||
# Etherpad with mypads plugin for YunoHost
|
||||
|
||||
[](https://dash.yunohost.org/appci/app/etherpad_mypads)
|
||||
[](https://dash.yunohost.org/appci/app/etherpad_mypads)  [](https://github.com/YunoHost/Apps/#what-to-do-if-i-cant-maintain-my-app-anymore-)
|
||||
[](https://install-app.yunohost.org/?app=etherpad_mypads)
|
||||
|
||||
*[Lire ce readme en français.](./README_fr.md)*
|
||||
|
@ -42,7 +42,7 @@ Supported, with LDAP.
|
|||
|
||||
* x86-64b - [](https://ci-apps.yunohost.org/ci/apps/etherpad_mypads/)
|
||||
* ARMv8-A - [](https://ci-apps-arm.yunohost.org/ci/apps/etherpad_mypads/)
|
||||
* Jessie x86-64b - [](https://ci-stretch.nohost.me/ci/apps/etherpad_mypads/)
|
||||
* Buster x86-64b - [](https://ci-buster.nohost.me/ci/apps/etherpad_mypads/)
|
||||
|
||||
## Limitations
|
||||
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
# Etherpad avec plugin mypads pour YunoHost
|
||||
|
||||
[](https://dash.yunohost.org/appci/app/etherpad_mypads)
|
||||
[](https://dash.yunohost.org/appci/app/etherpad_mypads)  [](https://github.com/YunoHost/Apps/#what-to-do-if-i-cant-maintain-my-app-anymore-)
|
||||
[](https://install-app.yunohost.org/?app=etherpad_mypads)
|
||||
|
||||
*[Read this readme in english.](./README.md)*
|
||||
|
@ -42,7 +42,7 @@ Supportée, avec LDAP.
|
|||
|
||||
* x86-64b - [](https://ci-apps.yunohost.org/ci/apps/etherpad_mypads/)
|
||||
* ARMv8-A - [](https://ci-apps-arm.yunohost.org/ci/apps/etherpad_mypads/)
|
||||
* Jessie x86-64b - [](https://ci-stretch.nohost.me/ci/apps/etherpad_mypads/)
|
||||
* Buster x86-64b - [](https://ci-buster.nohost.me/ci/apps/etherpad_mypads/)
|
||||
|
||||
## Limitations
|
||||
|
||||
|
|
|
@ -9,6 +9,24 @@
|
|||
export="libreoffice"
|
||||
mypads=1
|
||||
useldap=1
|
||||
; Actions
|
||||
is_public=0|1
|
||||
; Config_panel
|
||||
main.export.export=none|abiword|libreoffice
|
||||
main.pad_configuration.pad_config_nocolors=1|0
|
||||
main.pad_configuration.pad_config_showlinenumbers=0|1
|
||||
main.pad_configuration.pad_config_chatandusers=1|0
|
||||
main.pad_configuration.pad_config_alwaysshowchat=1|0
|
||||
main.pad_configuration.pad_config_show_markdown=1|0
|
||||
main.pad_configuration.pad_config_pageview=1|0
|
||||
main.pad_configuration.pad_config_automatic_logout=0|1
|
||||
main.mypads_configuration.mypads=0|1
|
||||
main.mypads_configuration.useldap=0|1
|
||||
main.is_public.is_public=1|0
|
||||
main.overwrite_files.overwrite_settings=0|1
|
||||
main.overwrite_files.overwrite_credentials=0|1
|
||||
main.overwrite_files.overwrite_nginx=0|1
|
||||
main.overwrite_files.overwrite_systemd=0|1
|
||||
; Checks
|
||||
pkg_linter=1
|
||||
setup_sub_dir=1
|
||||
|
@ -21,6 +39,8 @@
|
|||
multi_instance=0
|
||||
port_already_use=1 (9001)
|
||||
change_url=1
|
||||
actions=1
|
||||
config_panel=1
|
||||
;; Test sans mypads
|
||||
; Manifest
|
||||
domain="domain.tld" (DOMAIN)
|
||||
|
@ -68,7 +88,7 @@
|
|||
Level 5=auto
|
||||
;;; Options
|
||||
Email=
|
||||
Notification=down
|
||||
Notification=change
|
||||
;;; Upgrade options
|
||||
; commit=8bf300413ec3adcb416d168d2e9e98975dd9405b
|
||||
name= Fix nodejs & global update
|
||||
|
|
|
@ -14,7 +14,7 @@
|
|||
"email": "maniackc_dev@crudelis.fr"
|
||||
},
|
||||
"requirements": {
|
||||
"yunohost": ">= 3.5"
|
||||
"yunohost": ">= 3.6"
|
||||
},
|
||||
"multi_instance": true,
|
||||
"services": [
|
||||
|
|
|
@ -9,6 +9,13 @@
|
|||
source scripts/_common.sh
|
||||
source /usr/share/yunohost/helpers
|
||||
|
||||
#=================================================
|
||||
# MANAGE SCRIPT FAILURE
|
||||
#=================================================
|
||||
|
||||
# Exit if an error occurs during the execution of the script
|
||||
ynh_abort_if_errors
|
||||
|
||||
#=================================================
|
||||
# RETRIEVE ARGUMENTS
|
||||
#=================================================
|
||||
|
@ -29,14 +36,14 @@ then
|
|||
# abiword is already a dependence of etherpad_mypads.
|
||||
# abiword should be removed.
|
||||
abiword=0
|
||||
action1=installed
|
||||
action2=Installing
|
||||
action1=removed
|
||||
action2=Removing
|
||||
else
|
||||
# abiword isn't a dependence of etherpad_mypads.
|
||||
# abiword should be installed.
|
||||
abiword=1
|
||||
action1=removed
|
||||
action2=Removing
|
||||
action1=installed
|
||||
action2=Installing
|
||||
fi
|
||||
|
||||
ynh_print_info --message="Abiword will be $action1."
|
||||
|
|
|
@ -9,6 +9,13 @@
|
|||
source scripts/_common.sh
|
||||
source /usr/share/yunohost/helpers
|
||||
|
||||
#=================================================
|
||||
# MANAGE SCRIPT FAILURE
|
||||
#=================================================
|
||||
|
||||
# Exit if an error occurs during the execution of the script
|
||||
ynh_abort_if_errors
|
||||
|
||||
#=================================================
|
||||
# RETRIEVE ARGUMENTS
|
||||
#=================================================
|
||||
|
@ -29,14 +36,14 @@ then
|
|||
# libreoffice is already a dependence of etherpad_mypads.
|
||||
# libreoffice should be removed.
|
||||
libreoffice=0
|
||||
action1=installed
|
||||
action2=Installing
|
||||
action1=removed
|
||||
action2=Removing
|
||||
else
|
||||
# libreoffice isn't a dependence of etherpad_mypads.
|
||||
# libreoffice should be installed.
|
||||
libreoffice=1
|
||||
action1=removed
|
||||
action2=Removing
|
||||
action1=installed
|
||||
action2=Installing
|
||||
fi
|
||||
|
||||
ynh_print_info --message="Libreoffice will be $action1."
|
||||
|
|
|
@ -9,6 +9,13 @@
|
|||
source scripts/_common.sh
|
||||
source /usr/share/yunohost/helpers
|
||||
|
||||
#=================================================
|
||||
# MANAGE SCRIPT FAILURE
|
||||
#=================================================
|
||||
|
||||
# Exit if an error occurs during the execution of the script
|
||||
ynh_abort_if_errors
|
||||
|
||||
#=================================================
|
||||
# RETRIEVE ARGUMENTS
|
||||
#=================================================
|
||||
|
|
|
@ -8,6 +8,13 @@
|
|||
|
||||
source /usr/share/yunohost/helpers
|
||||
|
||||
#=================================================
|
||||
# MANAGE SCRIPT FAILURE
|
||||
#=================================================
|
||||
|
||||
# Exit if an error occurs during the execution of the script
|
||||
ynh_abort_if_errors
|
||||
|
||||
#=================================================
|
||||
# RETRIEVE ARGUMENTS
|
||||
#=================================================
|
||||
|
|
|
@ -9,6 +9,13 @@
|
|||
source scripts/_common.sh
|
||||
source /usr/share/yunohost/helpers
|
||||
|
||||
#=================================================
|
||||
# MANAGE SCRIPT FAILURE
|
||||
#=================================================
|
||||
|
||||
# Exit if an error occurs during the execution of the script
|
||||
ynh_abort_if_errors
|
||||
|
||||
#=================================================
|
||||
# RETRIEVE ARGUMENTS
|
||||
#=================================================
|
||||
|
|
|
@ -6,11 +6,12 @@
|
|||
# IMPORT GENERIC HELPERS
|
||||
#=================================================
|
||||
|
||||
source _common.sh
|
||||
source /usr/share/yunohost/helpers
|
||||
# Load common variables for all scripts.
|
||||
source _variables
|
||||
|
||||
source _common.sh
|
||||
source /usr/share/yunohost/helpers
|
||||
|
||||
#=================================================
|
||||
# RETRIEVE ARGUMENTS
|
||||
#=================================================
|
||||
|
@ -157,6 +158,11 @@ show_config() {
|
|||
#=================================================
|
||||
|
||||
apply_config() {
|
||||
|
||||
#=================================================
|
||||
# MODIFY ETHERPAD CONFIG
|
||||
#=================================================
|
||||
|
||||
restart_etherpad=0
|
||||
|
||||
# Change configuration if needed
|
||||
|
@ -245,6 +251,9 @@ apply_config() {
|
|||
ynh_replace_string --match_string="\(\"abiword\" *: \).*," --replace_string="\1null," --target_file="$config_file"
|
||||
ynh_replace_string --match_string="\(\"soffice\" *: \).*," --replace_string="\1null," --target_file="$config_file"
|
||||
fi
|
||||
|
||||
ynh_app_setting_set --app=$app --key=export --value="$export"
|
||||
|
||||
restart_etherpad=1
|
||||
fi
|
||||
|
||||
|
@ -261,6 +270,9 @@ apply_config() {
|
|||
fi
|
||||
popd
|
||||
chown -R $app: $final_path/node_modules
|
||||
|
||||
ynh_app_setting_set --app=$app --key=mypads --value="$mypads"
|
||||
|
||||
restart_etherpad=1
|
||||
fi
|
||||
|
||||
|
@ -273,6 +285,9 @@ apply_config() {
|
|||
else
|
||||
ynh_replace_string --match_string="\(.*\) //useldap" --replace_string="//noldap\1" --target_file="$final_path/settings.json"
|
||||
fi
|
||||
|
||||
ynh_app_setting_set --app=$app --key=useldap --value="$useldap"
|
||||
|
||||
restart_etherpad=1
|
||||
fi
|
||||
|
||||
|
@ -283,14 +298,25 @@ apply_config() {
|
|||
ynh_systemd_action --action=restart --line_match="You can access your Etherpad instance at" --log_path="/var/log/$app/etherpad.log" --timeout="120"
|
||||
fi
|
||||
|
||||
#=================================================
|
||||
# MODIFY PUBLIC ACCESSIBILITY
|
||||
#=================================================
|
||||
|
||||
# Change public accessibility
|
||||
if [ "$is_public" = "1" ]
|
||||
if [ "$is_public" != "$old_is_public" ]
|
||||
then
|
||||
yunohost app action run $app public_private --args is_public=1
|
||||
else
|
||||
yunohost app action run $app public_private --args is_public=0
|
||||
if [ "$is_public" = "1" ]
|
||||
then
|
||||
yunohost app action run $app public_private --args is_public=1
|
||||
else
|
||||
yunohost app action run $app public_private --args is_public=0
|
||||
fi
|
||||
fi
|
||||
|
||||
#=================================================
|
||||
# MODIFY OVERWRITTING SETTINGS
|
||||
#=================================================
|
||||
|
||||
# Set overwrite_settings
|
||||
ynh_app_setting_set --app=$app --key=overwrite_settings --value="$overwrite_settings"
|
||||
# Set overwrite_credentials
|
||||
|
|
|
@ -6,11 +6,12 @@
|
|||
# IMPORT GENERIC HELPERS
|
||||
#=================================================
|
||||
|
||||
source _common.sh
|
||||
source /usr/share/yunohost/helpers
|
||||
# Load common variables for all scripts.
|
||||
source _variables
|
||||
|
||||
source _common.sh
|
||||
source /usr/share/yunohost/helpers
|
||||
|
||||
#=================================================
|
||||
# MANAGE FAILURE OF THE SCRIPT
|
||||
#=================================================
|
||||
|
|
|
@ -6,11 +6,12 @@
|
|||
# IMPORT GENERIC HELPERS
|
||||
#=================================================
|
||||
|
||||
source ../settings/scripts/_common.sh
|
||||
source /usr/share/yunohost/helpers
|
||||
# Load common variables for all scripts.
|
||||
source ../settings/scripts/_variables
|
||||
|
||||
source ../settings/scripts/_common.sh
|
||||
source /usr/share/yunohost/helpers
|
||||
|
||||
#=================================================
|
||||
# MANAGE SCRIPT FAILURE
|
||||
#=================================================
|
||||
|
|
|
@ -6,11 +6,12 @@
|
|||
# IMPORT GENERIC HELPERS
|
||||
#=================================================
|
||||
|
||||
source _common.sh
|
||||
source /usr/share/yunohost/helpers
|
||||
# Load common variables for all scripts.
|
||||
source _variables
|
||||
|
||||
source _common.sh
|
||||
source /usr/share/yunohost/helpers
|
||||
|
||||
#=================================================
|
||||
# LOAD SETTINGS
|
||||
#=================================================
|
||||
|
|
Loading…
Add table
Reference in a new issue