-
Notifications
You must be signed in to change notification settings - Fork 1
/
Jenkinsfile
37 lines (30 loc) · 798 Bytes
/
Jenkinsfile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
pipeline {
agent any
environment {
SERVICE_NAME = "fin-trading-app-mongodb"
REPOSITORY_TAG="${YOUR_DOCKERHUB_USERNAME}/${ORGANIZATION_NAME}-${SERVICE_NAME}:${BUILD_ID}"
}
stages {
stage('Preparation') {
steps {
cleanWs()
git credentialsId: 'GitHub', url: "https://github.com/${ORGANIZATION_NAME}/${SERVICE_NAME}"
}
}
stage('Build') {
steps {
sh '''echo No build required for Mongodb'''
}
}
stage('Build and Push Image') {
steps {
sh 'echo No docker image for Mongodb'
}
}
stage('Deploy to Cluster') {
steps {
sh 'envsubst < ${WORKSPACE}/deploy.yml | kubectl apply -f -'
}
}
}
}