Ver código fonte

更新 'Jenkinsfile'

chenghongxi 4 anos atrás
pai
commit
be41953a51
1 arquivos alterados com 1 adições e 4 exclusões
  1. 1 4
      Jenkinsfile

+ 1 - 4
Jenkinsfile

@@ -3,10 +3,6 @@ def git_url="http://10.68.0.122:3000/fanyijian/k8s.git"
 def jenkins_home="/var/jenkins_home/workspace/k8s/"
 def xy_image="registry-vpc.cn-beijing.aliyuncs.com/xinyue-jenkins/"
 def release="${BUILD_NUMBER}"
-environment {
-	PowerShell = 'JenkinsFile\\web-site\\deploy.ps1'
-	String0 =  "$params.servers"
- }
 
 node {
     stage('pull code') {
@@ -17,6 +13,7 @@ node {
         for (int i = 0; i < projectList.length ; i++) {
              echo "${projectList[i]}"
              script: "sh cd ${jenkins_home}${projectList[i]}"
+             sh "docker build -t ${xy_image}${projectList[i]}:${release} -f ${jenkins_home}${projectList[i]}/Dockerfile ${jenkins_home}${projectList[i]}"
         }      
     }
 }