1
0
Fork 0
mirror of https://github.com/YunoHost-Apps/taskboard_ynh.git synced 2024-09-03 20:26:27 +02:00
taskboard_ynh/scripts/install

50 lines
1.5 KiB
Text
Raw Normal View History

2020-12-12 18:10:50 +01:00
#!/bin/bash
#=================================================
# GENERIC START
#=================================================
# IMPORT GENERIC HELPERS
#=================================================
source _common.sh
source /usr/share/yunohost/helpers
#=================================================
# DOWNLOAD, CHECK AND UNPACK SOURCE
#=================================================
ynh_script_progression --message="Setting up source files..." --weight=1
# Download, check integrity, uncompress and patch the source from app.src
2023-04-01 19:16:56 +02:00
ynh_setup_source --dest_dir="$install_dir"
2020-12-12 18:10:50 +01:00
2023-04-01 19:16:56 +02:00
chmod 750 "$install_dir"
2023-04-01 19:31:51 +02:00
chmod 775 "$install_dir/api"
2023-04-01 19:16:56 +02:00
chmod -R o-rwx "$install_dir"
chown -R $app:www-data "$install_dir"
2021-06-01 21:14:07 +02:00
2020-12-12 18:10:50 +01:00
#=================================================
# PHP-FPM CONFIGURATION
#=================================================
2021-08-30 17:21:43 +02:00
ynh_script_progression --message="Configuring PHP-FPM..." --weight=4
2020-12-12 18:10:50 +01:00
2024-06-24 11:28:25 +02:00
ynh_add_fpm_config
2023-01-07 07:53:48 +01:00
ynh_add_nginx_config
2021-08-30 17:20:07 +02:00
#=================================================
# ADD A CONFIGURATION
#=================================================
2021-08-30 17:21:43 +02:00
ynh_script_progression --message="Adding a configuration file..." --weight=2
2021-08-30 17:20:07 +02:00
dir="__DIR__"
2024-06-24 11:28:25 +02:00
ynh_add_config --template="Mailer.php" --destination="$install_dir/api/helpers/Mailer.php"
2021-08-30 17:20:07 +02:00
2023-04-01 19:16:56 +02:00
chmod 400 "$install_dir/api/helpers/Mailer.php"
chown $app:$app "$install_dir/api/helpers/Mailer.php"
2021-08-30 17:20:07 +02:00
2020-12-12 18:10:50 +01:00
#=================================================
# END OF SCRIPT
#=================================================
ynh_script_progression --message="Installation of TaskBoard completed" --last