new file: Dockerfile
new file: Jenkinsfile Initial commit
This commit is contained in:
parent
dce6ffa7b4
commit
53d0090e5e
14
Dockerfile
Normal file
14
Dockerfile
Normal file
@ -0,0 +1,14 @@
|
||||
FROM buster-slim
|
||||
|
||||
MAINTAINER “Jonathan Ervine” <docker@ervine.org>
|
||||
|
||||
# Install updates
|
||||
|
||||
RUN apt update && apt upgrade
|
||||
RUN apt install unzip
|
||||
RUN mkdir /bedrock && cd /bedrock && curl -LO https://minecraft.azureedge.net/bin-linux/bedrock-server-1.14.32.1.zip
|
||||
RUN unzip bedrock-server-1.14.32.1.zip && rm bedrock-server-1.14.32.1.zip
|
||||
|
||||
EXPOSE 19132
|
||||
|
||||
CMD [ "/bedrock/bedrock-server" ]
|
||||
24
Jenkinsfile
vendored
Normal file
24
Jenkinsfile
vendored
Normal file
@ -0,0 +1,24 @@
|
||||
node("docker-node") {
|
||||
docker.withRegistry('https://harbor.ervine.dev', 'jenkins-to-harbor') {
|
||||
|
||||
git branch: "master", url: "ssh://git@git.ervine.org:2222/jonny/x86_64-debian-bedrock", credentialsId: 'jenkins-to-git'
|
||||
|
||||
sh "git rev-parse HEAD > .git/commit-id"
|
||||
def commit_id = readFile('.git/commit-id').trim()
|
||||
println commit_id
|
||||
|
||||
try {
|
||||
stage "build"
|
||||
def app = docker.build "library/x86_64/debian/bedrock"
|
||||
|
||||
stage "publish"
|
||||
app.push("${env.BUILD_NUMBER}")
|
||||
app.push("latest")
|
||||
|
||||
}
|
||||
}
|
||||
catch (err) {
|
||||
currentBuild.result = 'FAILURE'
|
||||
}
|
||||
}
|
||||
}
|
||||
Loading…
Reference in New Issue
Block a user