From 5ec5b82a9ae4d5c9ccb64778f0bb18f50716ba06 Mon Sep 17 00:00:00 2001 From: lihongjie0209 Date: Sat, 12 Aug 2023 11:15:49 +0800 Subject: [PATCH] =?UTF-8?q?=E5=AE=8C=E5=96=84jenkins=E6=96=87=E4=BB=B6,=20?= =?UTF-8?q?=E5=A2=9E=E5=8A=A0=E9=83=A8=E7=BD=B2=E6=B5=81=E7=A8=8B?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- Jenkinsfile | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/Jenkinsfile b/Jenkinsfile index 68aee67f..7c65ddbc 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -65,6 +65,18 @@ pipeline{ } + stage("重新部署"){ + + + steps{ + + sh "kubectl --kubeconfig=/root/kube/k3s.yaml apply -k k8s/${env.BRANCH_NAME}/" + sh "kubectl --kubeconfig=/root/kube/k3s.yaml rollout restart deployment/coal-api --namespace coal-${env.BRANCH_NAME}/" + + + } + + } }