aboutsummaryrefslogtreecommitdiff
path: root/Jenkinsfile
blob: e8645bb02dc4791eb24c925472610621dc225208 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
String cron_string = BRANCH_NAME == "master" ? "@weekly" : ""

pipeline {
    agent any
    triggers { cron(cron_string) }
    options { ansiColor('xterm') }
    stages {
        stage('Build') { steps { sh 'bash .scripts.d/20-build.sh' } }
        // stage('Test') { steps { sh 'bash .scripts.d/30-test.sh' } }
        stage('Publish') {
            environment { DOCKERHUB_TOKEN = credentials('DOCKERHUB_TOKEN') }
            steps { sh 'bash .scripts.d/40-publish.sh' }
        }
    }
    post {
        always {
            // junit 'build/reports/*.xml'
            step([$class: 'Mailer',
                notifyEveryUnstableBuild: true,
                recipients: "christian+jenkins@segundo.io",
                sendToIndividuals: true])
        }
    }
}