1
0
Fork 0
mirror of https://github.com/YunoHost-Apps/yeswiki_ynh.git synced 2024-09-03 18:05:56 +02:00

chmod of hooks folder

This commit is contained in:
Douze Baie 2024-07-03 11:05:37 +02:00
parent 1b04f525d9
commit c6d1275d6e
2 changed files with 16 additions and 9 deletions

View file

@ -100,27 +100,31 @@ chown root:root /etc/sudoers.d/$app
# Add a post app install hook to sync the app importer # Add a post app install hook to sync the app importer
mkdir -p /etc/yunohost/hooks.d/post_app_install mkdir -p /etc/yunohost/hooks.d/post_app_install
chmod 700 /etc/yunohost/hooks.d/post_app_install
ynh_add_config --template="sync_app_importer.sh" --destination="/etc/yunohost/hooks.d/post_app_install/${app}_sync_app_importer.sh" ynh_add_config --template="sync_app_importer.sh" --destination="/etc/yunohost/hooks.d/post_app_install/${app}_sync_app_importer.sh"
chown root:root /etc/yunohost/hooks.d/post_app_install/${app}_sync_app_importer.sh chown root:root /etc/yunohost/hooks.d/post_app_install/${app}_sync_app_importer.sh
chmod +x /etc/yunohost/hooks.d/post_app_install/${app}_sync_app_importer.sh chmod 700 /etc/yunohost/hooks.d/post_app_install/${app}_sync_app_importer.sh
# Add a post app remove hook to sync the app importer # Add a post app remove hook to sync the app importer
mkdir -p /etc/yunohost/hooks.d/post_app_remove mkdir -p /etc/yunohost/hooks.d/post_app_remove
chmod 700 /etc/yunohost/hooks.d/post_app_remove
ynh_add_config --template="sync_app_importer.sh" --destination="/etc/yunohost/hooks.d/post_app_remove/${app}_sync_app_importer.sh" ynh_add_config --template="sync_app_importer.sh" --destination="/etc/yunohost/hooks.d/post_app_remove/${app}_sync_app_importer.sh"
chown root:root /etc/yunohost/hooks.d/post_app_remove/${app}_sync_app_importer.sh chown root:root /etc/yunohost/hooks.d/post_app_remove/${app}_sync_app_importer.sh
chmod +x /etc/yunohost/hooks.d/post_app_remove/${app}_sync_app_importer.sh chmod 700 /etc/yunohost/hooks.d/post_app_remove/${app}_sync_app_importer.sh
# Add a post user create hook to sync the user importer # Add a post user create hook to sync the user importer
mkdir -p /etc/yunohost/hooks.d/post_user_create mkdir -p /etc/yunohost/hooks.d/post_user_create
chmod 700 /etc/yunohost/hooks.d/post_user_create
ynh_add_config --template="sync_user_importer.sh" --destination="/etc/yunohost/hooks.d/post_user_create/${app}_sync_user_importer.sh" ynh_add_config --template="sync_user_importer.sh" --destination="/etc/yunohost/hooks.d/post_user_create/${app}_sync_user_importer.sh"
chown root:root /etc/yunohost/hooks.d/post_user_create/${app}_sync_user_importer.sh chown root:root /etc/yunohost/hooks.d/post_user_create/${app}_sync_user_importer.sh
chmod +x /etc/yunohost/hooks.d/post_user_create/${app}_sync_user_importer.sh chmod 700 /etc/yunohost/hooks.d/post_user_create/${app}_sync_user_importer.sh
# Add a post user delete hook to sync the user importer # Add a post user delete hook to sync the user importer
mkdir -p /etc/yunohost/hooks.d/post_user_delete mkdir -p /etc/yunohost/hooks.d/post_user_delete
chmod 700 /etc/yunohost/hooks.d/post_user_delete
ynh_add_config --template="sync_user_importer.sh" --destination="/etc/yunohost/hooks.d/post_user_delete/${app}_sync_user_importer.sh" ynh_add_config --template="sync_user_importer.sh" --destination="/etc/yunohost/hooks.d/post_user_delete/${app}_sync_user_importer.sh"
chown root:root /etc/yunohost/hooks.d/post_user_delete/${app}_sync_user_importer.sh chown root:root /etc/yunohost/hooks.d/post_user_delete/${app}_sync_user_importer.sh
chmod +x /etc/yunohost/hooks.d/post_user_delete/${app}_sync_user_importer.sh chmod 700 /etc/yunohost/hooks.d/post_user_delete/${app}_sync_user_importer.sh
# At last, run the YunoHost app importer # At last, run the YunoHost app importer
ynh_script_progression --message="Import YunoHost apps in bazar" --weight=2 ynh_script_progression --message="Import YunoHost apps in bazar" --weight=2

View file

@ -82,28 +82,31 @@ chown root:root /etc/sudoers.d/$app
# Add a post app install hook to sync the app importer # Add a post app install hook to sync the app importer
mkdir -p /etc/yunohost/hooks.d/post_app_install mkdir -p /etc/yunohost/hooks.d/post_app_install
chmod 700 /etc/yunohost/hooks.d/post_app_install
ynh_add_config --template="sync_app_importer.sh" --destination="/etc/yunohost/hooks.d/post_app_install/${app}_sync_app_importer.sh" ynh_add_config --template="sync_app_importer.sh" --destination="/etc/yunohost/hooks.d/post_app_install/${app}_sync_app_importer.sh"
chown root:root /etc/yunohost/hooks.d/post_app_install/${app}_sync_app_importer.sh chown root:root /etc/yunohost/hooks.d/post_app_install/${app}_sync_app_importer.sh
chmod +x /etc/yunohost/hooks.d/post_app_install/${app}_sync_app_importer.sh chmod 700 /etc/yunohost/hooks.d/post_app_install/${app}_sync_app_importer.sh
# Add a post app remove hook to sync the app importer # Add a post app remove hook to sync the app importer
mkdir -p /etc/yunohost/hooks.d/post_app_remove mkdir -p /etc/yunohost/hooks.d/post_app_remove
chmod 700 /etc/yunohost/hooks.d/post_app_remove
ynh_add_config --template="sync_app_importer.sh" --destination="/etc/yunohost/hooks.d/post_app_remove/${app}_sync_app_importer.sh" ynh_add_config --template="sync_app_importer.sh" --destination="/etc/yunohost/hooks.d/post_app_remove/${app}_sync_app_importer.sh"
chown root:root /etc/yunohost/hooks.d/post_app_remove/${app}_sync_app_importer.sh chown root:root /etc/yunohost/hooks.d/post_app_remove/${app}_sync_app_importer.sh
chmod +x /etc/yunohost/hooks.d/post_app_remove/${app}_sync_app_importer.sh chmod 700 /etc/yunohost/hooks.d/post_app_remove/${app}_sync_app_importer.sh
# Add a post user create hook to sync the user importer # Add a post user create hook to sync the user importer
mkdir -p /etc/yunohost/hooks.d/post_user_create mkdir -p /etc/yunohost/hooks.d/post_user_create
chmod 700 /etc/yunohost/hooks.d/post_user_create
ynh_add_config --template="sync_user_importer.sh" --destination="/etc/yunohost/hooks.d/post_user_create/${app}_sync_user_importer.sh" ynh_add_config --template="sync_user_importer.sh" --destination="/etc/yunohost/hooks.d/post_user_create/${app}_sync_user_importer.sh"
chown root:root /etc/yunohost/hooks.d/post_user_create/${app}_sync_user_importer.sh chown root:root /etc/yunohost/hooks.d/post_user_create/${app}_sync_user_importer.sh
chmod +x /etc/yunohost/hooks.d/post_user_create/${app}_sync_user_importer.sh chmod 700 /etc/yunohost/hooks.d/post_user_create/${app}_sync_user_importer.sh
# Add a post user delete hook to sync the user importer # Add a post user delete hook to sync the user importer
mkdir -p /etc/yunohost/hooks.d/post_user_delete mkdir -p /etc/yunohost/hooks.d/post_user_delete
chmod 700 /etc/yunohost/hooks.d/post_user_delete
ynh_add_config --template="sync_user_importer.sh" --destination="/etc/yunohost/hooks.d/post_user_delete/${app}_sync_user_importer.sh" ynh_add_config --template="sync_user_importer.sh" --destination="/etc/yunohost/hooks.d/post_user_delete/${app}_sync_user_importer.sh"
chown root:root /etc/yunohost/hooks.d/post_user_delete/${app}_sync_user_importer.sh chown root:root /etc/yunohost/hooks.d/post_user_delete/${app}_sync_user_importer.sh
chmod +x /etc/yunohost/hooks.d/post_user_delete/${app}_sync_user_importer.sh chmod 700 /etc/yunohost/hooks.d/post_user_delete/${app}_sync_user_importer.sh
if [ $(grep yunohost_sso_domain "$install_dir/wakka.config.php" | wc -l) = "0" ]; then if [ $(grep yunohost_sso_domain "$install_dir/wakka.config.php" | wc -l) = "0" ]; then