feat: call ps_rebuild from post-app-rename-setup
This commit is contained in:
1 parent
77f9862549
commit
0740636d53
2 files changed
+16
-1
No files matched your search
@@ -30,7 +30,6 @@ cmd-apps-rename() {
|
|||||||
[[ -f "$DOKKU_ROOT/$NEW_APP/URLS" ]] && sed -i -e "s/$OLD_APP/$NEW_APP/g" "$DOKKU_ROOT/$NEW_APP/URLS"
|
[[ -f "$DOKKU_ROOT/$NEW_APP/URLS" ]] && sed -i -e "s/$OLD_APP/$NEW_APP/g" "$DOKKU_ROOT/$NEW_APP/URLS"
|
||||||
[[ -f "$DOKKU_ROOT/$NEW_APP/VHOST" ]] && sed -i -e "s/$OLD_APP/$NEW_APP/g" "$DOKKU_ROOT/$NEW_APP/VHOST"
|
[[ -f "$DOKKU_ROOT/$NEW_APP/VHOST" ]] && sed -i -e "s/$OLD_APP/$NEW_APP/g" "$DOKKU_ROOT/$NEW_APP/VHOST"
|
||||||
[[ -f "$DOKKU_ROOT/$NEW_APP/hooks/pre-receive" ]] && sed -i -e "s/git-hook $OLD_APP/git-hook $NEW_APP/g" "$DOKKU_ROOT/$NEW_APP/hooks/pre-receive"
|
[[ -f "$DOKKU_ROOT/$NEW_APP/hooks/pre-receive" ]] && sed -i -e "s/git-hook $OLD_APP/git-hook $NEW_APP/g" "$DOKKU_ROOT/$NEW_APP/hooks/pre-receive"
|
||||||
ps_rebuild "$NEW_APP"
|
|
||||||
plugn trigger post-app-rename "$OLD_APP" "$NEW_APP"
|
plugn trigger post-app-rename "$OLD_APP" "$NEW_APP"
|
||||||
docker_cleanup "$OLD_APP" "true"
|
docker_cleanup "$OLD_APP" "true"
|
||||||
echo "Renaming $OLD_APP to $NEW_APP... done"
|
echo "Renaming $OLD_APP to $NEW_APP... done"
|
||||||
|
|||||||
Executable
+16
@@ -0,0 +1,16 @@
|
|||||||
|
#!/usr/bin/env bash
|
||||||
|
set -eo pipefail
|
||||||
|
[[ $DOKKU_TRACE ]] && set -x
|
||||||
|
source "$PLUGIN_CORE_AVAILABLE_PATH/common/functions"
|
||||||
|
source "$PLUGIN_AVAILABLE_PATH/config/functions"
|
||||||
|
source "$PLUGIN_AVAILABLE_PATH/ps/functions"
|
||||||
|
|
||||||
|
trigger-ps-post-app-rename-setup() {
|
||||||
|
declare desc="ps post-app-rename-setup plugin trigger"
|
||||||
|
declare trigger="post-app-rename-setup"
|
||||||
|
declare OLD_APP="$1" NEW_APP="$2"
|
||||||
|
|
||||||
|
ps_rebuild "$NEW_APP"
|
||||||
|
}
|
||||||
|
|
||||||
|
trigger-ps-post-app-rename-setup "$@"
|
||||||
Reference in new issue
Block a user