1
0
Fork 0
mirror of https://github.com/YunoHost-Apps/droppy_ynh.git synced 2024-09-03 18:26:27 +02:00
This commit is contained in:
ericgaspar 2021-11-05 23:14:21 +01:00
parent 1aec6071f5
commit e8ab2bd94f
No known key found for this signature in database
GPG key ID: 574F281483054D44
4 changed files with 12 additions and 10 deletions

View file

@ -1,9 +1,9 @@
;; Test complet ;; Test complet
; Manifest ; Manifest
domain="domain.tld" (DOMAIN) domain="domain.tld"
path="/path" (PATH) path="/path"
admin="john" (USER) admin="john"
is_public=1 (PUBLIC|public=1|private=0) is_public=1
; Checks ; Checks
pkg_linter=1 pkg_linter=1
setup_sub_dir=1 setup_sub_dir=1
@ -15,7 +15,6 @@
#upgrade=1 from_commit=CommitHash #upgrade=1 from_commit=CommitHash
backup_restore=1 backup_restore=1
multi_instance=0 multi_instance=0
port_already_use=0
change_url=1 change_url=1
;;; Options ;;; Options
Email= Email=

View file

@ -119,8 +119,6 @@ ynh_app_setting_set --app=$app --key=data_path --value=$data_path
# Create datadir folder # Create datadir folder
mkdir -p $data_path mkdir -p $data_path
# Create config folder
mkdir -p $final_path/config
# Give permission to the datadir # Give permission to the datadir
chmod 750 "$data_path" chmod 750 "$data_path"
@ -141,7 +139,11 @@ ynh_add_systemd_config
#================================================= #=================================================
ynh_script_progression --message="Modifying a config file..." --weight=1 ynh_script_progression --message="Modifying a config file..." --weight=1
# Create config folder
mkdir -p $final_path/config
ynh_add_config --template="../conf/config.json.example" --destination="$final_path/config/config.json" ynh_add_config --template="../conf/config.json.example" --destination="$final_path/config/config.json"
chmod 600 "$final_path/config/config.json" chmod 600 "$final_path/config/config.json"
chown $app:$app "$final_path/config/config.json" chown $app:$app "$final_path/config/config.json"

View file

@ -64,7 +64,7 @@ ynh_secure_remove --file="$final_path"
if [ "${YNH_APP_PURGE:-0}" -eq 1 ] if [ "${YNH_APP_PURGE:-0}" -eq 1 ]
then then
ynh_script_progression --message="Removing app data directory..." --weight=1 ynh_script_progression --message="Removing app data directory..." --weight=1
ynh_secure_remove --file="$datadir" ynh_secure_remove --file="$data_path"
fi fi
#================================================= #=================================================
# REMOVE NGINX CONFIGURATION # REMOVE NGINX CONFIGURATION

View file

@ -127,6 +127,7 @@ fi
ynh_script_progression --message="Modifying a config file..." --weight=2 ynh_script_progression --message="Modifying a config file..." --weight=2
ynh_add_config --template="../conf/config.json.example" --destination="$final_path/config/config.json" ynh_add_config --template="../conf/config.json.example" --destination="$final_path/config/config.json"
chmod 600 "$final_path/config/config.json" chmod 600 "$final_path/config/config.json"
chown $app:$app "$final_path/config/config.json" chown $app:$app "$final_path/config/config.json"