mirror of
https://github.com/YunoHost-Apps/lionwiki-t2t_ynh.git
synced 2024-09-03 19:36:27 +02:00
adding ynh_backup_if_checksum protection on some files
This commit is contained in:
parent
c18587ba2a
commit
1bcd5c671c
2 changed files with 12 additions and 2 deletions
|
@ -296,6 +296,10 @@ fi
|
|||
# Calculate and store the config file checksum into the app settings
|
||||
##ynh_store_file_checksum --file="$final_path/CONFIG_FILE"
|
||||
|
||||
ynh_store_file_checksum --file="$final_path/config.php"
|
||||
ynh_store_file_checksum --file="$final_path/config.t2t"
|
||||
ynh_store_file_checksum --file="$final_path/menu.php"
|
||||
|
||||
#=================================================
|
||||
# GENERIC FINALIZATION
|
||||
#=================================================
|
||||
|
|
|
@ -153,9 +153,15 @@ ynh_add_fpm_config
|
|||
|
||||
### Verify the checksum of a file, stored by `ynh_store_file_checksum` in the install script.
|
||||
### And create a backup of this file if the checksum is different. So the file will be backed up if the admin had modified it.
|
||||
ynh_backup_if_checksum_is_different --file="$final_path/CONFIG_FILE"
|
||||
ynh_backup_if_checksum_is_different --file="$final_path/config.php"
|
||||
ynh_backup_if_checksum_is_different --file="$final_path/config.t2t"
|
||||
ynh_backup_if_checksum_is_different --file="$final_path/menu.php"
|
||||
# Recalculate and store the checksum of the file for the next upgrade.
|
||||
ynh_store_file_checksum --file="$final_path/CONFIG_FILE"
|
||||
ynh_store_file_checksum --file="$final_path/config.php"
|
||||
ynh_store_file_checksum --file="$final_path/config.t2t"
|
||||
ynh_store_file_checksum --file="$final_path/menu.php"
|
||||
|
||||
|
||||
|
||||
#=================================================
|
||||
# SETUP LOGROTATE
|
||||
|
|
Loading…
Add table
Reference in a new issue