Commit af8aa5ff by lichengming
parents 781f9c70 b88e9b15
pipeline {
agent any
stages {
stage('git pull') {
steps {
echo '=== Build web-soil Begin'
checkout([$class: 'GitSCM', branches: [[name: 'dev']], doGenerateSubmoduleConfigurations: false, extensions: [[$class: 'CleanBeforeCheckout']], submoduleCfg: [],
userRemoteConfigs: [[credentialsId: 'patzn-zmq', url: 'http://git.patzn.com/wangweidong/pt-cloud-service-soil-web.git']]])
echo '=== Build web-soil End'
}
}
stage('Npm run build') {
steps {
nodejs('node14'){
sh '''
node --version
npm --version
yarn --version
yarn config set registry https://registry.npm.taobao.org
yarn config set sass_binary_site https://npm.taobao.org/mirrors/node-sass/
yarn
NODE_ENV=zhyf STATIC_URL=http://static.lims.com nuxt build
'''
}
}
}
stage('Docker build and push') {
steps {
echo '=== Build docker image Begin'
sh """
docker build -t patzn-web-soil:2.0 .
docker login -u patzn -p Qw123qwe https://192.168.0.140
docker tag patzn-web-soil:2.0 192.168.0.140/zhyf/web-soil:1.0
docker push 192.168.0.140/zhyf/web-soil:1.0
"""
echo '=== Build docker image End'
}
}
}
}
......@@ -20,7 +20,7 @@
"@nuxtjs/axios": "^5.3.6",
"@nuxtjs/dotenv": "^1.3.0",
"@nuxtjs/pwa": "^2.6.0",
"@nuxtjs/router": "^1.1.0",
"@nuxtjs/router": "1.3.2",
"cookie-universal-nuxt": "^2.0.14",
"cross-env": "^5.2.0",
"dateformat": "^3.0.3",
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment