Skip to content

Commit

Permalink
just: ensure peerpod vms are cleaned up on undeploy
Browse files Browse the repository at this point in the history
  • Loading branch information
davidweisse committed Nov 4, 2024
1 parent 3fb6a9d commit 1641635
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion justfile
Original file line number Diff line number Diff line change
Expand Up @@ -153,7 +153,7 @@ apply target=default_deploy_target:
kubectl apply -f ./{{ workspace_dir }}/deployment
# Delete Kubernetes manifests.
undeploy:
undeploy platform=default_platform:
#!/usr/bin/env bash
set -euo pipefail
if [[ ! -d ./{{ workspace_dir }} ]]; then
Expand All @@ -169,6 +169,11 @@ undeploy:
echo "Namespace $ns does not exist, nothing to undeploy."
exit 0
fi
if [[ {{ platform }} == "AKS-PEER-SNP" ]]; then
kubectl delete --cascade=foreground -f .//{{ workspace_dir }}/deployment
kubectl delete namespace $ns
exit 0
fi
if [[ -f ./{{ workspace_dir }}/deployment/ns.yml ]]; then
kubectl delete \
-f ./{{ workspace_dir }}/deployment \
Expand Down

0 comments on commit 1641635

Please sign in to comment.