fix: 流水线kubeconfig改用临时目录

This commit is contained in:
admin
2026-08-02 10:51:02 +08:00
parent 6a6a31f7d6
commit 33e7c9e0ef
+4 -2
View File
@@ -19,6 +19,8 @@ env:
jobs:
deploy:
runs-on: ubuntu-latest
env:
KUBECONFIG: /tmp/kubeconfig
steps:
- name: Checkout code
run: |
@@ -32,8 +34,8 @@ jobs:
curl -sLO "https://dl.k8s.io/release/$KUBECTL_VERSION/bin/linux/amd64/kubectl"
chmod +x kubectl
mv kubectl /usr/local/bin/
mkdir -p ~/.kube
echo "${{ secrets.KUBECONFIG_B64 }}" | base64 -d > ~/.kube/config
echo "${{ secrets.KUBECONFIG_B64 }}" | base64 -d > /tmp/kubeconfig
chmod 600 /tmp/kubeconfig
- name: Apply manifests
run: |