This commit is contained in:
2026-01-31 12:56:10 +08:00
parent c16cef42f3
commit 893925e15e
5 changed files with 1151 additions and 1 deletions

View File

@@ -199,7 +199,7 @@ pipeline {
done
echo "--- 最近 200 行 Pod 日志 ---"
for pod in \$(kubectl get pods -n ${K8s_namespace}-l "app=${Pod_container_name},environment=${Pod_environment}" -o jsonpath='{.items[*].metadata.name}'); do
for pod in \$(kubectl get pods -n ${K8s_namespace} -l "app=${Pod_container_name},environment=${Pod_environment}" -o jsonpath='{.items[*].metadata.name}'); do
echo "-- logs \$pod --"
kubectl logs \$pod -n ${K8s_namespace} --tail=200 || true
done