1
0
Fork 0
mirror of https://github.com/YunoHost-Apps/gotosocial_ynh.git synced 2024-09-03 19:16:06 +02:00

fix config file parameters

This commit is contained in:
OniriCorpe 2022-03-14 19:54:17 +01:00
parent a6149abff7
commit 27c618b2a3

View file

@ -175,13 +175,13 @@ ynh_script_progression --message="Updating a configuration file..." --weight=1
### The file will automatically be backed-up if it's found to be manually modified (because ### The file will automatically be backed-up if it's found to be manually modified (because
### ynh_add_config keeps track of the file's checksum) ### ynh_add_config keeps track of the file's checksum)
ynh_add_config --template="some_config_file" --destination="$final_path/some_config_file" ynh_add_config --template="config.yaml" --destination="$final_path/config.yaml"
# FIXME: this should be handled by the core in the future # FIXME: this should be handled by the core in the future
# You may need to use chmod 600 instead of 400, # You may need to use chmod 600 instead of 400,
# for example if the app is expected to be able to modify its own config # for example if the app is expected to be able to modify its own config
chmod 400 "$final_path/some_config_file" chmod 400 "$final_path/config.yaml"
chown $app:$app "$final_path/some_config_file" chown $app:$app "$final_path/config.yaml"
### For more complex cases where you want to replace stuff using regexes, ### For more complex cases where you want to replace stuff using regexes,
### you shoud rely on ynh_replace_string (which is basically a wrapper for sed) ### you shoud rely on ynh_replace_string (which is basically a wrapper for sed)