From 4a27aab9322501f802c12da7909a3e5418c92db9 Mon Sep 17 00:00:00 2001 From: Jonathan Lebon Date: Tue, 3 Apr 2018 17:13:21 -0400 Subject: [PATCH] jenkins/papr: add custom jenkins imagestream In 3.6, we don't want to use the built-in `openshift/jenkins` imagestream because that tracks the `:latest` tag in Docker Hub rather than a versioned stable tag. This was done starting from v3.7. For now, let's just create our own imagestream to point to the v3.9 tag. See link in comments for more details. --- jenkins/paci-jenkins.yaml | 19 +++++++++++++++++-- papr/papr-trigger.py | 3 ++- 2 files changed, 19 insertions(+), 3 deletions(-) diff --git a/jenkins/paci-jenkins.yaml b/jenkins/paci-jenkins.yaml index 3c01000..cf87e81 100644 --- a/jenkins/paci-jenkins.yaml +++ b/jenkins/paci-jenkins.yaml @@ -22,6 +22,22 @@ objects: metadata: name: paci-jenkins namespace: ${NAMESPACE} +# this is a version of the openshift/jenkins locked to stable openshift tags, +# since we're using v3.6, which didn't do this versioning +# see: https://github.com/openshift/jenkins/issues/528#issuecomment-378381468 +# Once we move away from v3.6, we can drop this and change the paci-jenkins bc +# to use the openshift/jenkins:2 tag +- apiVersion: v1 + kind: ImageStream + metadata: + name: jenkins + namespace: ${NAMESPACE} + spec: + tags: + - name: stable + from: + kind: DockerImage + name: openshift/jenkins-2-centos7:v3.9 - apiVersion: v1 kind: BuildConfig metadata: @@ -41,8 +57,7 @@ objects: sourceStrategy: from: kind: ImageStreamTag - name: jenkins:latest - namespace: openshift + name: jenkins:stable forcePull: true output: to: diff --git a/papr/papr-trigger.py b/papr/papr-trigger.py index 8452946..4493a13 100755 --- a/papr/papr-trigger.py +++ b/papr/papr-trigger.py @@ -72,7 +72,8 @@ def generate_papr_pod(args): "name": "papr", "image": "172.30.1.1:5000/projectatomic-ci/papr", "imagePullPolicy": "Always", - "args": ["--debug", "--repo", args.repo], + "args": ["--debug", "runtest", "--conf", + "/etc/papr.conf", "--repo", args.repo], # XXX: pvc for git checkout caches # XXX: mount site.yaml configmap "volumeMounts": [