new file: Dockerfile

new file:   Jenkinsfile
Initial commit
This commit is contained in:
Jonathan Ervine 2020-04-01 14:40:09 +08:00
parent 571ca5dae9
commit 99ab89db67
2 changed files with 32 additions and 0 deletions

14
Dockerfile Normal file
View File

@ -0,0 +1,14 @@
# Base on latest (edge) alpine image
FROM harbor.ervine.dev/library/x86_64/alpine/alpine-3.10
MAINTAINER “Jonathan Ervine” <docker@ervine.org>
# Install updates
ENV LANG='en_US.UTF-8' \
LANGUAGE='en_US.UTF-8'
RUN apk update && apk -U upgrade && apk add python3 git
VOLUME /data
CMD [ "/bin/sh" ]

18
Jenkinsfile vendored Normal file
View File

@ -0,0 +1,18 @@
node("docker-node") {
docker.withRegistry('https://harbor.ervine.dev', 'jenkins-to-harbor') {
git branch: "3.10.3", url: "ssh://git@git.ervine.org:2222/jonny/alpine-kubespray-installer", credentialsId: 'jenkins-to-git'
sh "git rev-parse HEAD > .git/commit-id"
def commit_id = readFile('.git/commit-id').trim()
println commit_id
stage "build"
def app = docker.build "library/x86_64/alpine/kubespray"
stage "publish"
app.push("${env.BUILD_NUMBER}")
app.push("latest")
app.push("3.10")
}
}