Skip to content

Commit

Permalink
add jenkinsfile and comment entryponint
Browse files Browse the repository at this point in the history
  • Loading branch information
sdelrio committed Sep 25, 2017
1 parent 544b020 commit a65efee
Show file tree
Hide file tree
Showing 2 changed files with 43 additions and 1 deletion.
42 changes: 42 additions & 0 deletions Jenkinsfile
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'
}
}
}
2 changes: 1 addition & 1 deletion entrypoint.sh
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,6 @@ if [ -z "$CLAYMOREPORT" ]; then
CLAYMOREPORT=3333
fi


# Entrypoint that connects to IP $IP:$CLAYMOREPORT, each $FREQUENCY seconds and listn on port $LISTENPORT
python /usr/local/bin/claymore-exporter.py -t $IP -f $FREQUENCY -p $LISTENPORT -c $CLAYMOREPORT

0 comments on commit a65efee

Please sign in to comment.