master- Sync Repo

This commit is contained in:
Mali Bayhan
2021-12-10 09:49:13 -08:00
parent 77e3169e6b
commit 6c2157dac5
18 changed files with 505 additions and 0 deletions

View File

@@ -0,0 +1,18 @@
#!groovy
pipeline {
agent any
stages {
stage('Build') {
steps {
dir('user-service') {
sh "../mvnw clean verify " +
"-Dpact.provider.version=${GIT_COMMIT} " +
"-Dpact.verifier.publishResults=true"
}
}
}
}
}

View File

@@ -0,0 +1,38 @@
#!groovy
pipeline {
agent any
parameters {
string(name: 'GIT_COMMIT', defaultValue: '', description: 'Version (a.k.a. git commit) to deploy')
}
options {
skipDefaultCheckout()
}
stages {
stage('Check Pact Verifications') {
steps {
sh 'curl -LO https://github.com/pact-foundation/pact-ruby-standalone/releases/download/v1.88.3/pact-1.88.3-linux-x86_64.tar.gz'
sh 'tar xzf pact-1.88.3-linux-x86_64.tar.gz'
dir('pact/bin') {
sh "./pact-broker can-i-deploy -a user-service -b http://pact_broker -e ${GIT_COMMIT} --to prod"
}
}
}
stage('Deploy') {
steps {
echo 'Deploying to prod now...'
}
}
stage('Tag Pact') {
steps {
dir('pact/bin') {
sh "./pact-broker create-version-tag -a user-service -b http://pact_broker -e ${GIT_COMMIT} -t prod"
}
}
}
}
}