使用pipeline集成部署springboot项目

阅读 54

2022-02-10

pipeline{
    agent any
    environment {
        RESPOSITORY='https://xxxxx.git'
    }
    stages {
        stage('git clone') {
            steps {
                echo "start git clone........."
                git credentialsId:'xxxxxxx', url:"${RESPOSITORY}",branch:"${NODE_NAME}"
             }
        }
        stage("maven build") {
            steps {
                echo 'build code ..............'
                withMaven (
                    maven: 'maven',
                    mavenLocalRepo: '.repository') {
                        sh 'mvn clean package -Dmaven.test.skip=true'
                    }
            }
        }

    }

精彩评论(0)

0 0 举报