-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathJenkinsfile
More file actions
33 lines (27 loc) · 819 Bytes
/
Copy pathJenkinsfile
File metadata and controls
33 lines (27 loc) · 819 Bytes
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
library('jenkins_build')
node {
main {
def dockerImageName = "registry.elbert.us/dungeon"
def dockerImage
stage("Checkout") {
checkout scm
}
stage("Build") {
dockerImage = docker.build("${dockerImageName}:latest")
}
stage("Publish") {
dockerImage.push()
dockerImage.push(env.JOB_BASE_NAME)
}
if (env.BRANCH_NAME == "production") {
stage("Deploy") {
remote_deploy("azathoth.thenever", "dungeon", "./docker-compose-rlyeh.yml")
}
}
if (env.BRANCH_NAME == "remote") {
stage("Deploy") {
remote_deploy("remote.dungeon.elbert.us", "remote_dungeon", "./docker-compose-remote.yml")
}
}
}
}