mirror of
https://github.com/YunoHost-Apps/movim_ynh.git
synced 2024-09-03 19:46:19 +02:00
cleaning
This commit is contained in:
parent
384611cb5b
commit
5fe2cf2f43
7 changed files with 45 additions and 53 deletions
|
@ -1,6 +1,3 @@
|
||||||
# See here for more informations
|
|
||||||
# https://github.com/YunoHost/package_check#syntax-check_process-file
|
|
||||||
|
|
||||||
;; Test complet
|
;; Test complet
|
||||||
; Manifest
|
; Manifest
|
||||||
domain="domain.tld"
|
domain="domain.tld"
|
||||||
|
@ -9,7 +6,6 @@
|
||||||
is_public=1
|
is_public=1
|
||||||
password="phrasedepasse"
|
password="phrasedepasse"
|
||||||
language="fr"
|
language="fr"
|
||||||
port=9537 (PORT)
|
|
||||||
; Checks
|
; Checks
|
||||||
pkg_linter=1
|
pkg_linter=1
|
||||||
setup_sub_dir=1
|
setup_sub_dir=1
|
||||||
|
@ -28,4 +24,4 @@ Notification=none
|
||||||
;;; Upgrade options
|
;;; Upgrade options
|
||||||
; commit=80bdea70f80aafef673718911ad492ddc54aab5c
|
; commit=80bdea70f80aafef673718911ad492ddc54aab5c
|
||||||
name=Testing (#23)
|
name=Testing (#23)
|
||||||
manifest_arg=domain=DOMAIN&path=PATH&admin=USER&language=fr&is_public=1&password=phrasedepasse&port=9537&
|
manifest_arg=domain=DOMAIN&path=PATH&admin=USER&language=fr&is_public=1&password=phrasedepasse&
|
||||||
|
|
3
doc/DISCLAIMER_fr.md
Normal file
3
doc/DISCLAIMER_fr.md
Normal file
|
@ -0,0 +1,3 @@
|
||||||
|
## Configuration
|
||||||
|
|
||||||
|
* Comment configurer cette application : via le panneau d'administration a cette adresse https://example.com/movim/?admin. Le nom d'utilisateur et le mot de passe sont définis lors de l'installation.
|
BIN
doc/screenshots/movim.png
Normal file
BIN
doc/screenshots/movim.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 534 KiB |
|
@ -8,6 +8,13 @@
|
||||||
},
|
},
|
||||||
"version": "0.19~ynh2",
|
"version": "0.19~ynh2",
|
||||||
"url": "https://movim.eu",
|
"url": "https://movim.eu",
|
||||||
|
"upstream": {
|
||||||
|
"license": "AGPL-3.0-or-later",
|
||||||
|
"website": "https://movim.eu",
|
||||||
|
"demo": "https://nl.movim.eu/?login",
|
||||||
|
"admindoc": "https://github.com/movim/movim/wiki",
|
||||||
|
"code": "https://github.com/movim/movim"
|
||||||
|
},
|
||||||
"license": "AGPL-3.0-or-later",
|
"license": "AGPL-3.0-or-later",
|
||||||
"maintainer": {
|
"maintainer": {
|
||||||
"name": "",
|
"name": "",
|
||||||
|
|
|
@ -68,6 +68,14 @@ ynh_script_progression --message="Installing dependencies..." --weight=1
|
||||||
# Install packages
|
# Install packages
|
||||||
ynh_exec_warn_less ynh_install_app_dependencies $pkg_dependencies
|
ynh_exec_warn_less ynh_install_app_dependencies $pkg_dependencies
|
||||||
|
|
||||||
|
#=================================================
|
||||||
|
# CREATE DEDICATED USER
|
||||||
|
#=================================================
|
||||||
|
ynh_script_progression --message="Configuring system user..." --weight=3
|
||||||
|
|
||||||
|
# Create a system user
|
||||||
|
ynh_system_user_create --username=$app --home_dir="$final_path"
|
||||||
|
|
||||||
#=================================================
|
#=================================================
|
||||||
# CREATE A POSTGRESQL DATABASE
|
# CREATE A POSTGRESQL DATABASE
|
||||||
#=================================================
|
#=================================================
|
||||||
|
@ -91,6 +99,10 @@ ynh_app_setting_set --app=$app --key=final_path --value=$final_path
|
||||||
# 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="$final_path"
|
ynh_setup_source --dest_dir="$final_path"
|
||||||
|
|
||||||
|
chmod 750 "$final_path"
|
||||||
|
chmod -R o-rwx "$final_path"
|
||||||
|
chown -R $app:www-data "$final_path"
|
||||||
|
|
||||||
#=================================================
|
#=================================================
|
||||||
# NGINX CONFIGURATION
|
# NGINX CONFIGURATION
|
||||||
#=================================================
|
#=================================================
|
||||||
|
@ -99,14 +111,6 @@ ynh_script_progression --message="Configuring NGINX web server..." --weight=11
|
||||||
# Create a dedicated NGINX config
|
# Create a dedicated NGINX config
|
||||||
ynh_add_nginx_config
|
ynh_add_nginx_config
|
||||||
|
|
||||||
#=================================================
|
|
||||||
# CREATE DEDICATED USER
|
|
||||||
#=================================================
|
|
||||||
ynh_script_progression --message="Configuring system user..." --weight=3
|
|
||||||
|
|
||||||
# Create a system user
|
|
||||||
ynh_system_user_create --username=$app
|
|
||||||
|
|
||||||
#=================================================
|
#=================================================
|
||||||
# PHP-FPM CONFIGURATION
|
# PHP-FPM CONFIGURATION
|
||||||
#=================================================
|
#=================================================
|
||||||
|
@ -125,7 +129,8 @@ ynh_script_progression --message="Modifying a config file..." --weight=1
|
||||||
|
|
||||||
ynh_add_config --template="../conf/db.example.inc.php" --destination="$final_path/config/db.inc.php"
|
ynh_add_config --template="../conf/db.example.inc.php" --destination="$final_path/config/db.inc.php"
|
||||||
|
|
||||||
ynh_store_file_checksum --file="$final_path/config/db.inc.php"
|
chmod 400 "$final_path/config/db.inc.php"
|
||||||
|
chown $app:$app "$final_path/config/db.inc.php"
|
||||||
|
|
||||||
#=================================================
|
#=================================================
|
||||||
# Install PHP dependencies using composer
|
# Install PHP dependencies using composer
|
||||||
|
@ -156,16 +161,6 @@ pushd $final_path
|
||||||
php$phpversion daemon.php config --username=$admin --password=$password --quiet
|
php$phpversion daemon.php config --username=$admin --password=$password --quiet
|
||||||
popd
|
popd
|
||||||
|
|
||||||
#=================================================
|
|
||||||
# GENERIC FINALIZATION
|
|
||||||
#=================================================
|
|
||||||
# SET PERMISSIONS
|
|
||||||
#=================================================
|
|
||||||
|
|
||||||
chmod 750 "$final_path"
|
|
||||||
chmod -R o-rwx "$final_path"
|
|
||||||
chown -R $app:www-data "$final_path"
|
|
||||||
|
|
||||||
#=================================================
|
#=================================================
|
||||||
# INTEGRATE SERVICE IN YUNOHOST
|
# INTEGRATE SERVICE IN YUNOHOST
|
||||||
#=================================================
|
#=================================================
|
||||||
|
|
|
@ -53,6 +53,14 @@ test ! -d $final_path \
|
||||||
|
|
||||||
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"
|
||||||
|
|
||||||
|
#=================================================
|
||||||
|
# RECREATE THE DEDICATED USER
|
||||||
|
#=================================================
|
||||||
|
ynh_script_progression --message="Recreating the dedicated system user..." --weight=1
|
||||||
|
|
||||||
|
# Create the dedicated user (if not existing)
|
||||||
|
ynh_system_user_create --username=$app --home_dir="$final_path"
|
||||||
|
|
||||||
#=================================================
|
#=================================================
|
||||||
# RESTORE THE APP MAIN DIR
|
# RESTORE THE APP MAIN DIR
|
||||||
#=================================================
|
#=================================================
|
||||||
|
@ -60,19 +68,6 @@ ynh_script_progression --message="Restoring Movim main directory..." --weight=1
|
||||||
|
|
||||||
ynh_restore_file --origin_path="$final_path"
|
ynh_restore_file --origin_path="$final_path"
|
||||||
|
|
||||||
#=================================================
|
|
||||||
# RECREATE THE DEDICATED USER
|
|
||||||
#=================================================
|
|
||||||
ynh_script_progression --message="Recreating the dedicated system user..." --weight=1
|
|
||||||
|
|
||||||
# Create the dedicated user (if not existing)
|
|
||||||
ynh_system_user_create --username=$app
|
|
||||||
|
|
||||||
#=================================================
|
|
||||||
# RESTORE USER RIGHTS
|
|
||||||
#=================================================
|
|
||||||
|
|
||||||
# Restore permissions on app files
|
|
||||||
chmod 750 "$final_path"
|
chmod 750 "$final_path"
|
||||||
chmod -R o-rwx "$final_path"
|
chmod -R o-rwx "$final_path"
|
||||||
chown -R $app:www-data "$final_path"
|
chown -R $app:www-data "$final_path"
|
||||||
|
|
|
@ -79,6 +79,14 @@ ynh_script_progression --message="Stopping a systemd service..." --weight=23
|
||||||
|
|
||||||
ynh_systemd_action --service_name=$app --action=stop --log_path="/var/log/$app/$app.log"
|
ynh_systemd_action --service_name=$app --action=stop --log_path="/var/log/$app/$app.log"
|
||||||
|
|
||||||
|
#=================================================
|
||||||
|
# CREATE DEDICATED USER
|
||||||
|
#=================================================
|
||||||
|
ynh_script_progression --message="Making sure dedicated system user exists..." --weight=1
|
||||||
|
|
||||||
|
# Create a dedicated user (if not existing)
|
||||||
|
ynh_system_user_create --username=$app --home_dir="$final_path"
|
||||||
|
|
||||||
#=================================================
|
#=================================================
|
||||||
# DOWNLOAD, CHECK AND UNPACK SOURCE
|
# DOWNLOAD, CHECK AND UNPACK SOURCE
|
||||||
#=================================================
|
#=================================================
|
||||||
|
@ -91,6 +99,10 @@ then
|
||||||
ynh_setup_source --dest_dir="$final_path"
|
ynh_setup_source --dest_dir="$final_path"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
chmod 750 "$final_path"
|
||||||
|
chmod -R o-rwx "$final_path"
|
||||||
|
chown -R $app:www-data "$final_path"
|
||||||
|
|
||||||
#=================================================
|
#=================================================
|
||||||
# NGINX CONFIGURATION
|
# NGINX CONFIGURATION
|
||||||
#=================================================
|
#=================================================
|
||||||
|
@ -106,14 +118,6 @@ ynh_script_progression --message="Upgrading dependencies..." --weight=4
|
||||||
|
|
||||||
ynh_exec_warn_less ynh_install_app_dependencies $pkg_dependencies
|
ynh_exec_warn_less ynh_install_app_dependencies $pkg_dependencies
|
||||||
|
|
||||||
#=================================================
|
|
||||||
# CREATE DEDICATED USER
|
|
||||||
#=================================================
|
|
||||||
ynh_script_progression --message="Making sure dedicated system user exists..." --weight=7
|
|
||||||
|
|
||||||
# Create a dedicated user (if not existing)
|
|
||||||
ynh_system_user_create --username=$app
|
|
||||||
|
|
||||||
#=================================================
|
#=================================================
|
||||||
# PHP-FPM CONFIGURATION
|
# PHP-FPM CONFIGURATION
|
||||||
#=================================================
|
#=================================================
|
||||||
|
@ -124,14 +128,6 @@ ynh_replace_string --match_string="__TIMEZONE__" --replace_string="$timezone" --
|
||||||
|
|
||||||
ynh_add_fpm_config --package="$extra_php_dependencies"
|
ynh_add_fpm_config --package="$extra_php_dependencies"
|
||||||
|
|
||||||
#=================================================
|
|
||||||
# SET PERMISSIONS
|
|
||||||
#=================================================
|
|
||||||
|
|
||||||
chmod 750 "$final_path"
|
|
||||||
chmod -R o-rwx "$final_path"
|
|
||||||
chown -R $app:www-data "$final_path"
|
|
||||||
|
|
||||||
#=================================================
|
#=================================================
|
||||||
# INTEGRATE SERVICE IN YUNOHOST
|
# INTEGRATE SERVICE IN YUNOHOST
|
||||||
#=================================================
|
#=================================================
|
||||||
|
|
Loading…
Add table
Reference in a new issue