大量更新

This commit is contained in:
zeaslity
2026-05-19 14:28:44 +08:00
parent a8f6bda703
commit 9fc3372fa3
5299 changed files with 423176 additions and 426690 deletions

View File

@@ -1,17 +1,23 @@
#!/bin/bash
wget https://oss.demo.uavcmlc.com/cmlc-installation/downloadfile/amd/jq-linux-amd64 -O /usr/local/bin/jq
wget https://oss.demo.uavcmlc.com/cmlc-installation/tmp/jq-linux-amd64 -O /usr/local/bin/jq
#wget https://oss.demo.uavcmlc.com/cmlc-installation/downloadfile/aarch/jq-linux-arm64 -O /usr/local/bin/jq
chmod +x /usr/local/bin/jq
export name_space=xayd
kubectl delete pods -n $name_space --field-selector status.phase!=Running --force
kubectl get pods -n $name_space -o json | jq -r '.items[] | select(.status.containerStatuses[0].ready == false) | .metadata.name' | xargs -r kubectl delete pod -n $name_space --force
export name_space_list=(kube-system kubernetes-dashboard ingress-nginx bj-sh-uas-260511)
export name_space_list=(bj-sh-uas-260511)
for name_space in ${name_space_list[*]};do
kubectl delete pods -n $name_space --field-selector status.phase!=Running --force
kubectl get pods -n $name_space -o json | jq -r '.items[] | select(.status.containerStatuses[0].ready == false) | .metadata.name' | xargs -r kubectl delete pod -n $name_space --force
done
kubectl -n ${name_space} delete pod helm-nacos-0 --force

View File

@@ -1,30 +0,0 @@
#!/usr/bin/env bash
name_space=zjyd
delete_all_fronted_cmii_pod(){
all_pod_list=($(kubectl get pods -n "$name_space" -o=jsonpath='{.items[*].metadata.name}' | tr " " "\n"))
for pod in "${all_pod_list[@]}"; do
if echo "$pod" | grep -q "platform"; then
echo ""
echo "current pod is $pod"
kubectl -n "$name_space" delete pod "$pod" --force
fi
done
}
delete_all_backend_cmii_pod(){
all_pod_list=($(kubectl get pods -n "$name_space" -o=jsonpath='{.items[*].metadata.name}' | tr " " "\n"))
for pod in "${all_pod_list[@]}"; do
if echo "$pod" | grep -v "platform" | grep -q "cmii"; then
echo ""
echo "current pod is $pod"
kubectl -n "$name_space" delete pod "$pod" --force
fi
done
}
delete_all_backend_cmii_pod
delete_all_fronted_cmii_pod