3 def values = project.split('/')
4 if ( values.size() > 1 ) {
7 // no prefix, likely just the project name then
11 def project_checkout() {
12 // checkout the project
13 git url: "https://osm.etsi.org/gerrit/${GERRIT_PROJECT}"
15 sh "git fetch origin ${GERRIT_REFSPEC}"
16 if (GERRIT_PATCHSET_REVISION.size() > 0 ) {
17 sh "git checkout -f ${GERRIT_PATCHSET_REVISION}"
21 def devops_checkout() {
23 git url: 'https://osm.etsi.org/gerrit/osm/devops'
37 container_name = "${GERRIT_PROJECT}-${GERRIT_BRANCH}"
39 mdg = Get_MDG("${GERRIT_PROJECT}")
40 println("MDG is ${mdg}")
42 stage('Docker-Build') {
43 sh "docker build -t ${container_name} ."
46 withDockerContainer("${container_name}") {
47 stage('Docker-Setup') {
49 groupadd -o -g $(id -g) -r jenkins
50 useradd -o -u $(id -u) --create-home -r -g jenkins jenkins
54 sh 'devops-stages/stage-test.sh'
57 sh 'devops-stages/stage-build.sh'
60 sh 'devops-stages/stage-archive.sh'
61 archiveArtifacts artifacts: "dists/**,pool/${mdg}/*.deb", fingerprint: true