[ agent ] 优化部分内容
This commit is contained in:
13
常用脚本/uav脚本/uav关闭一些后端.sh
Normal file
13
常用脚本/uav脚本/uav关闭一些后端.sh
Normal file
@@ -0,0 +1,13 @@
|
||||
#!/usr/bin/env bash
|
||||
|
||||
namespace=zjjt
|
||||
|
||||
all_error_app_list=(cmii-uav-user cmii-uav-oauth cmii-admin-user cmii-admin-gateway cmii-uav-gateway cmii-uav-cloud-live cmii-uav-material-warehouse)
|
||||
|
||||
for app in ${all_error_app_list[@]};do
|
||||
echo "current app is ${app}"
|
||||
old_replicas=$(kubectl -n ${namespace} get deployment ${app} -o jsonpath='{.spec.replicas}')
|
||||
kubectl -n ${namespace} scale deployment ${app} --replicas=0
|
||||
sleep 1
|
||||
kubectl -n ${namespace} scale deployment ${app} --replicas=${old_replicas}
|
||||
done
|
||||
Reference in New Issue
Block a user