mirror of
https://github.com/YunoHost-Apps/yeswiki_ynh.git
synced 2024-09-03 18:05:56 +02:00
Merge pull request #90 from Lab-8916100448256/testing
feat(yunohost extension): Add a post app install hook to update app list
This commit is contained in:
commit
8fc8b780fb
2 changed files with 5 additions and 0 deletions
2
conf/sync_app_importer.sh
Normal file
2
conf/sync_app_importer.sh
Normal file
|
@ -0,0 +1,2 @@
|
||||||
|
#!/usr/bin/env bash
|
||||||
|
sudo -u __USER__ bash -c "cd __INSTALL_DIR__ && ./yeswicli importer:sync -s yunohost-cli"
|
|
@ -99,6 +99,9 @@ chmod +x $install_dir/tools/yunohost/private/scripts/*.sh
|
||||||
# Add app user in sudoers to authorize to launch yunohost cli commands without password
|
# Add app user in sudoers to authorize to launch yunohost cli commands without password
|
||||||
ynh_add_config --template="sudoers" --destination="/etc/sudoers.d/$app"
|
ynh_add_config --template="sudoers" --destination="/etc/sudoers.d/$app"
|
||||||
chown root:root /etc/sudoers.d/$app
|
chown root:root /etc/sudoers.d/$app
|
||||||
|
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
|
||||||
|
chmod +x /etc/yunohost/hooks.d/post_app_install/$app_sync_app_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
|
||||||
|
|
Loading…
Reference in a new issue