Post-deploy abra.sh hooks #235
Loading…
x
Reference in New Issue
Block a user
No description provided.
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Describe the problem to be solved
e.g. when you deploy Nextcloud and would like to have some apps installed automagically.
Describe the solution you would like
abra_postdeploy_hook
(or whatever) function is read fromabra.sh
and ran if present after a deploy. Potentially configurable via--hooks
(or whatever) flags ondeploy
?Centralising on coop-cloud/organising#301.
I reopen this, because
abra app cmd
#301 still has to be run manually after each deploy or upgrade if necessary.My proposal is to introduce two new env variables:
POST_DEPLOY_CMDS=<container> <command> <arguments>|<container> <command2> <arguments2>|...
andPOST_UPGRADE_CMDS
. These variables contain abra.sh commands that should be executed after each deployment/upgrade.For example for nextcloud:
POST_UPGRADE_CMDS="app run_occ db:add-missing-indices|app run_occ db:convert-filecache-bigint"
POST_DEPLOY_CMDS="app set_default_quota|app install_onlyoffice"
Abra should wait until all health checks are successful and than automagically run these commands.
This requires working health checks and coop-cloud/organising#437 so it won't abort before the health checks are finished.
Would love to see this, thanks @moritz!
Nice! Love it 🚀