aboutsummaryrefslogtreecommitdiffstats
path: root/Jenkinsfile
blob: 27bb5265cf17f203e2e7875c390416b1403c0a21 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
pipeline {
    agent {
        kubernetes {
            yamlFile 'centos7-rpmbuild.yaml'
            defaultContainer 'centos7-rpmbuild'
            slaveConnectTimeout '3600'
            nodeSelector 'kubernetes.io/os=linux,kubernetes.io/arch=amd64'
        }
    }

    options {
        buildDiscarder(logRotator(numToKeepStr: '5'))
        disableConcurrentBuilds()
    }

    triggers {
        pollSCM('H * * * *')
    }

    stages {
        stage('Run shell') {
            steps {
                sh '''
                    uname -a
                    printenv | sort
                    cat /etc/os-release
                    export CENTOS_MIRROR=http://spunk.home.kraxel.org/centos/
                    export EPEL_MIRROR=http://spunk.home.kraxel.org/epel/
                    /usr/local/bin/configure-mirror
                    dnf update -y
                '''
            }
        }
    }
}