This commit is contained in:
zeaslity
2024-10-30 16:30:51 +08:00
commit 437acbeb63
3363 changed files with 653948 additions and 0 deletions

View File

@@ -0,0 +1,12 @@
#!/bin/bash
export name_space=ly
export new_tag=5.1.0
export deployment_name=cmii-uav-tower
image_prefix=$(kubectl -n ${name_space} get deployment ${deployment_name} -o=jsonpath='{.spec.template.spec.containers[*].image}' | cut -d":" -f1)
echo "image grep is => ${image_prefix}"
kubectl -n ${name_space} patch deployment ${deployment_name} -p "{\"spec\":{\"template\":{\"spec\":{\"containers\":[{\"name\":\"${deployment_name}\",\"image\": \"${image_prefix}:${new_tag}\"}]}}}}"