mirror of
https://github.com/kata-containers/kata-containers.git
synced 2025-06-24 14:32:33 +00:00
Merge pull request #7243 from sprt/ensure-cluster-no-exist
gha: k8s: Ensure cluster doesn't exist before creating it
This commit is contained in:
commit
48c3cec1f4
@ -32,6 +32,9 @@ function login_azure() {
|
||||
}
|
||||
|
||||
function create_cluster() {
|
||||
# First, ensure that the cluster didn't fail to get cleaned up from a previous run.
|
||||
delete_cluster || true
|
||||
|
||||
az aks create \
|
||||
-g "kataCI" \
|
||||
-n "$(_print_cluster_name)" \
|
||||
@ -142,8 +145,7 @@ function delete_cluster() {
|
||||
az aks delete \
|
||||
-g "kataCI" \
|
||||
-n "$(_print_cluster_name)" \
|
||||
--yes \
|
||||
--no-wait
|
||||
--yes
|
||||
}
|
||||
|
||||
function main() {
|
||||
|
Loading…
Reference in New Issue
Block a user