From 417419971675417d1d33b9f3d92c21f6c9cf116d Mon Sep 17 00:00:00 2001
From: Ralph Bean <rbean@redhat.com>
Date: May 01 2018 16:18:30 +0000
Subject: [PATCH 1/2] F28 is released.  :)


---

diff --git a/Dockerfile b/Dockerfile
index 1b2d34e..ead4d0f 100644
--- a/Dockerfile
+++ b/Dockerfile
@@ -1,4 +1,4 @@
-FROM fedora:27
+FROM fedora:28
 LABEL \
     name="WaiverDB application" \
     vendor="WaiverDB developers" \
diff --git a/Jenkinsfile b/Jenkinsfile
index c622def..80315e5 100644
--- a/Jenkinsfile
+++ b/Jenkinsfile
@@ -82,14 +82,6 @@ node('fedora') {
                 """
                 archiveArtifacts artifacts: 'mock-result/el7/**'
             },
-            'F26': {
-                sh """
-                mkdir -p mock-result/f26
-                flock /etc/mock/fedora-26-x86_64.cfg \
-                /usr/bin/mock -v --enable-network --resultdir=mock-result/f26 -r fedora-26-x86_64 --clean --rebuild rpmbuild-output/*.src.rpm
-                """
-                archiveArtifacts artifacts: 'mock-result/f26/**'
-            },
             'F27': {
                 sh """
                 mkdir -p mock-result/f27
@@ -98,6 +90,14 @@ node('fedora') {
                 """
                 archiveArtifacts artifacts: 'mock-result/f27/**'
             },
+            'F28': {
+                sh """
+                mkdir -p mock-result/f28
+                flock /etc/mock/fedora-28-x86_64.cfg \
+                /usr/bin/mock -v --enable-network --resultdir=mock-result/f28 -r fedora-28-x86_64 --clean --rebuild rpmbuild-output/*.src.rpm
+                """
+                archiveArtifacts artifacts: 'mock-result/f28/**'
+            },
         )
     }
     stage('Invoke Rpmlint') {
@@ -105,24 +105,24 @@ node('fedora') {
             'EPEL7': {
                 sh 'rpmlint -f rpmlint-config.py mock-result/el7/*.rpm'
             },
-            'F26': {
-                sh 'rpmlint -f rpmlint-config.py mock-result/f26/*.rpm'
-            },
             'F27': {
                 sh 'rpmlint -f rpmlint-config.py mock-result/f27/*.rpm'
             },
+            'F28': {
+                sh 'rpmlint -f rpmlint-config.py mock-result/f28/*.rpm'
+            },
         )
     }
 }
 node('docker') {
     checkout scm
     stage('Build Docker container') {
-        unarchive mapping: ['mock-result/f26/': '.']
-        def f26_rpm = findFiles(glob: 'mock-result/f26/**/*.noarch.rpm')[0]
+        unarchive mapping: ['mock-result/f28/': '.']
+        def f28_rpm = findFiles(glob: 'mock-result/f28/**/*.noarch.rpm')[0]
         /* XXX: remove this once we divorce waiverdb-cli from waiverdb. */
-        def waiverdb_common = findFiles(glob: 'mock-result/f26/**/waiverdb-common-*.noarch.rpm')[0]
+        def waiverdb_common = findFiles(glob: 'mock-result/f28/**/waiverdb-common-*.noarch.rpm')[0]
         def appversion = sh(returnStdout: true, script: """
-            rpm2cpio ${f26_rpm} | \
+            rpm2cpio ${f28_rpm} | \
             cpio --quiet --extract --to-stdout ./usr/lib/python\\*/site-packages/waiverdb\\*.egg-info/PKG-INFO | \
             awk '/^Version: / {print \$2}'
         """).trim()
@@ -136,13 +136,13 @@ node('docker') {
             /* Note that the docker.build step has some magic to guess the
              * Dockerfile used, which will break if the build directory (here ".")
              * is not the final argument in the string. */
-            def image = docker.build "factory2/waiverdb:internal-${appversion}", "--build-arg waiverdb_rpm=$f26_rpm --build-arg waiverdb_common_rpm=$waiverdb_common ."
+            def image = docker.build "factory2/waiverdb:internal-${appversion}", "--build-arg waiverdb_rpm=$f28_rpm --build-arg waiverdb_common_rpm=$waiverdb_common ."
             image.push()
         }
         docker.withRegistry(
                 'https://quay.io/',
                 'quay-io-factory2-builder-sa-credentials') {
-            def image = docker.build "factory2/waiverdb:${appversion}", "--build-arg waiverdb_rpm=$f26_rpm --build-arg waiverdb_common_rpm=$waiverdb_common ."
+            def image = docker.build "factory2/waiverdb:${appversion}", "--build-arg waiverdb_rpm=$f28_rpm --build-arg waiverdb_common_rpm=$waiverdb_common ."
             image.push()
         }
         /* Save container version for later steps (this is ugly but I can't find anything better...) */

From 2a31074811c440a172440b8bd4426fba68749f43 Mon Sep 17 00:00:00 2001
From: Ralph Bean <rbean@redhat.com>
Date: May 01 2018 17:03:33 +0000
Subject: [PATCH 2/2] Get /etc/mock/fedora-28-x86_64.cfg


---

diff --git a/Jenkinsfile b/Jenkinsfile
index 80315e5..b667b40 100644
--- a/Jenkinsfile
+++ b/Jenkinsfile
@@ -12,6 +12,8 @@ node('fedora') {
         sh 'sudo dnf -y install python3-flake8 python3-pylint python3-pytest python3-sphinx python3-sphinxcontrib-httpdomain'
         /* Needed for mock EPEL7 builds: https://bugzilla.redhat.com/show_bug.cgi?id=1528272 */
         sh 'sudo dnf -y install dnf-utils'
+        /* Needed to get the latest /etc/mock/fedora-28-x86_64.cfg */
+        sh 'sudo dnf -y update mock-core-configs'
         /* Unit tests need local Postgres */
         sh """
         sudo dnf -y remove postgresql-server || true

