From d2cf69a3199f50922a4f6b897374516596ea1493 Mon Sep 17 00:00:00 2001 From: vesem Date: Thu, 18 Feb 2021 20:56:56 -0500 Subject: [PATCH] Added jenkinsfile --- Jenkinsfile | 30 ++++++++++++++++++++++++++++++ 1 file changed, 30 insertions(+) create mode 100644 Jenkinsfile diff --git a/Jenkinsfile b/Jenkinsfile new file mode 100644 index 0000000..86423c5 --- /dev/null +++ b/Jenkinsfile @@ -0,0 +1,30 @@ +pipeline { + agent any + + options { + disableConcurrentBuilds() + buildDiscarder(logRotator(daysToKeepStr: '180', numToKeepStr: '30')) + } + + stages { + stage('Setup Vars') { + steps { + script { + dockerBuildImage = 'registry.digitalocean.com/nerdfortress/cardano' + } + } + } + stage('build: create container') { + steps { + sh "docker build -t ${env.dockerBuildImage} ${env.tempDir}" + } + } + stage('build: push container') { + steps { + sh "doctl auth init" + sh "doctl registry login" + sh "docker push ${env.dockerBuildImage}" + } + } + } +} \ No newline at end of file