From 0df40cb78a7452e1d3bd9ed5d43ca06441b30e90 Mon Sep 17 00:00:00 2001 From: crusader Date: Thu, 2 Feb 2023 12:10:53 +0000 Subject: [PATCH] environment test --- Jenkinsfile | 17 +++++++++-------- 1 file changed, 9 insertions(+), 8 deletions(-) diff --git a/Jenkinsfile b/Jenkinsfile index 4da5f67..d358d1b 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -94,14 +94,15 @@ podTemplate( serverUrl: env.K8s_SERVER_URL, contextName: env.K8s_CONTEXT_NAME, clusterName: env.K8s_CLUSTER_NAME]) { - sh """ - DEPLOY_DATE=$(date +"%Y-%m-%d %H:%M:%S") - sed -i.bak 's#__REGISTRY_URL__#'"${dockerRegistryUrl}"'#' ./.k8s/deployment.yaml - sed -i.bak 's#__IMAGE_NAME__#'"${env.CONTAINER_IMAGE_NAME}"'#' ./.k8s/deployment.yaml - sed -i.bak 's#__IMAGE_TAG__#'"${env.PROJECT_VERSION}"'#' ./.k8s/deployment.yaml - sed -i.bak 's#__DEPLOY_DATE__#'"${DEPLOY_DATE}"'#' ./.k8s/deployment.yaml - kubectl apply -f ./.k8s/deployment.yaml - """ + println "CONTAINER_IMAGE_NAME - ${env.CONTAINER_IMAGE_NAME}" + // sh """ + // DEPLOY_DATE=$(date +"%Y-%m-%d %H:%M:%S") + // sed -i.bak 's#__REGISTRY_URL__#'"${dockerRegistryUrl}"'#' ./.k8s/deployment.yaml + // sed -i.bak 's#__IMAGE_NAME__#'"${env.CONTAINER_IMAGE_NAME}"'#' ./.k8s/deployment.yaml + // sed -i.bak 's#__IMAGE_TAG__#'"${env.PROJECT_VERSION}"'#' ./.k8s/deployment.yaml + // sed -i.bak 's#__DEPLOY_DATE__#'"${DEPLOY_DATE}"'#' ./.k8s/deployment.yaml + // kubectl apply -f ./.k8s/deployment.yaml + // """ } } }