-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
add jenkinsfile and comment entryponint
- Loading branch information
Showing
2 changed files
with
43 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,42 @@ | ||
pipeline { | ||
agent { | ||
label "docker" | ||
} | ||
stages { | ||
stage("Checkout") { | ||
steps { | ||
script { | ||
currentBuild.displayName = "$BUILD_TIMESTAMP-$BUILD_ID" | ||
// currentBuild.description = "Description $BUILD_ID" | ||
} | ||
sh 'echo Current Build: $BUILD_TIMESTAMP-$BUILD_ID' | ||
checkout scm | ||
} | ||
} | ||
// /* stage("Docker build") { steps { | ||
// sh "docker build -t leszko/calculator:${BUILD_TIMESTAMP} ." | ||
// | ||
// } } | ||
stage("Build") { | ||
steps { | ||
script { | ||
def TAG="$BUILD_TIMESTAMP-$BUIlD_ID" | ||
def BASE_X86="jfloff/alpine-python" | ||
def BASE_ARM="resin/raspberry-pi-alpine-python" | ||
sh "export BASE_X86=jfloff/alpine-python" | ||
sh "export BASE_ARM=resin/raspberry-pi-alpine-python" | ||
sh "echo X86=${BASE_X86}" | ||
sh "echo ARM=${BASE_ARM}" | ||
sh 'docker version' | ||
sh "echo docker build --no-cache --build-arg BASE_IMAGE=$BASE_X86 -t sdelrio/claymore-exporter:${TAG} ." | ||
sh "docker build --no-cache --build-arg BASE_IMAGE=$BASE_X86 -t sdelrio/claymore-exporter:${TAG} ." | ||
} | ||
} | ||
} | ||
} | ||
post { | ||
always { | ||
sh 'docker system prune -af' | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters