From 374e92c645879da45be32ab47d96dbf39df4c0ae Mon Sep 17 00:00:00 2001 From: Oleg Nenashev Date: Sun, 12 Apr 2020 10:26:43 +0200 Subject: [PATCH 1/3] [INFRA-1105] - Update the base image to jenkins/agent:4.3-2, cleanup old metadata --- 11/debian/Dockerfile | 5 ++--- 11/nanoserver-1809/Dockerfile | 2 +- 11/windowsservercore-1809/Dockerfile | 3 +-- 8/alpine/Dockerfile | 5 ++--- 8/debian/Dockerfile | 5 ++--- 8/nanoserver-1809/Dockerfile | 3 +-- 8/windowsservercore-1809/Dockerfile | 3 ++- 7 files changed, 11 insertions(+), 15 deletions(-) diff --git a/11/debian/Dockerfile b/11/debian/Dockerfile index bcaeb9c6..246a6228 100644 --- a/11/debian/Dockerfile +++ b/11/debian/Dockerfile @@ -20,11 +20,10 @@ # OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN # THE SOFTWARE. -ARG version=4.3-1-jdk11 -FROM jenkins/slave:$version +ARG version=4.3-2-jdk11 +FROM jenkins/agent:$version ARG version -MAINTAINER Oleg Nenashev LABEL Description="This is a base image, which allows connecting Jenkins agents via JNLP protocols" Vendor="Jenkins project" Version="$version" ARG user=jenkins diff --git a/11/nanoserver-1809/Dockerfile b/11/nanoserver-1809/Dockerfile index 98f8e3f0..425c7821 100644 --- a/11/nanoserver-1809/Dockerfile +++ b/11/nanoserver-1809/Dockerfile @@ -21,7 +21,7 @@ # OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN # THE SOFTWARE. -ARG VERSION=4.3-1 +ARG VERSION=4.3-2 FROM jenkins/agent:${VERSION}-nanoserver-1809-jdk11 ARG VERSION diff --git a/11/windowsservercore-1809/Dockerfile b/11/windowsservercore-1809/Dockerfile index f66c9d3f..3ff83756 100644 --- a/11/windowsservercore-1809/Dockerfile +++ b/11/windowsservercore-1809/Dockerfile @@ -21,10 +21,9 @@ # OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN # THE SOFTWARE. -ARG VERSION=4.3-1 +ARG VERSION=4.3-2 FROM jenkins/agent:${VERSION}-windowsservercore-1809-jdk11 -ARG VERSION LABEL Description="This is a base image, which allows connecting Jenkins agents via JNLP protocols on Windows" Vendor="Jenkins Project" Version="$VERSION" ARG user=jenkins diff --git a/8/alpine/Dockerfile b/8/alpine/Dockerfile index 9c7475e9..483d08c9 100644 --- a/8/alpine/Dockerfile +++ b/8/alpine/Dockerfile @@ -20,11 +20,10 @@ # OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN # THE SOFTWARE. -ARG version=4.3-1-alpine -FROM jenkins/slave:$version +ARG version=4.3-2-alpine +FROM jenkins/agent:$version ARG version -MAINTAINER Oleg Nenashev LABEL Description="This is a base image, which allows connecting Jenkins agents via JNLP protocols" Vendor="Jenkins project" Version="$version" ARG user=jenkins diff --git a/8/debian/Dockerfile b/8/debian/Dockerfile index 90fcdee0..f50306d2 100644 --- a/8/debian/Dockerfile +++ b/8/debian/Dockerfile @@ -20,11 +20,10 @@ # OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN # THE SOFTWARE. -ARG version=4.3-1 -FROM jenkins/slave:$version +ARG version=4.3-2 +FROM jenkins/agent:$version ARG version -MAINTAINER Oleg Nenashev LABEL Description="This is a base image, which allows connecting Jenkins agents via JNLP protocols" Vendor="Jenkins project" Version="$version" ARG user=jenkins diff --git a/8/nanoserver-1809/Dockerfile b/8/nanoserver-1809/Dockerfile index cf4d34d3..29a670e4 100644 --- a/8/nanoserver-1809/Dockerfile +++ b/8/nanoserver-1809/Dockerfile @@ -21,10 +21,9 @@ # OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN # THE SOFTWARE. -ARG VERSION=4.3-1 +ARG VERSION=4.3-2 FROM jenkins/agent:${VERSION}-nanoserver-1809 -ARG VERSION LABEL Description="This is a base image, which allows connecting Jenkins agents via JNLP protocols on Windows" Vendor="Jenkins Project" Version="$VERSION" ARG user=jenkins diff --git a/8/windowsservercore-1809/Dockerfile b/8/windowsservercore-1809/Dockerfile index fc0a6bf6..fc29b8f8 100644 --- a/8/windowsservercore-1809/Dockerfile +++ b/8/windowsservercore-1809/Dockerfile @@ -21,8 +21,9 @@ # OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN # THE SOFTWARE. -ARG VERSION=4.3-1 +ARG VERSION=4.3-2 FROM jenkins/agent:${VERSION}-windowsservercore-1809 + LABEL Description="This is a base image, which allows connecting Jenkins agents via JNLP protocols on Windows" Vendor="Jenkins Project" Version="$VERSION" ARG user=jenkins From ed3f4ccbb317d24c9e91a891ff644ee33e4159b4 Mon Sep 17 00:00:00 2001 From: Oleg Nenashev Date: Mon, 13 Apr 2020 22:04:03 +0200 Subject: [PATCH 2/3] INFRA-1105 - Update the base image to 4.3-4 --- 11/debian/Dockerfile | 2 +- 11/nanoserver-1809/Dockerfile | 2 +- 11/windowsservercore-1809/Dockerfile | 2 +- 8/alpine/Dockerfile | 2 +- 8/debian/Dockerfile | 2 +- 8/nanoserver-1809/Dockerfile | 2 +- 8/windowsservercore-1809/Dockerfile | 2 +- 7 files changed, 7 insertions(+), 7 deletions(-) diff --git a/11/debian/Dockerfile b/11/debian/Dockerfile index 246a6228..4f88cb0b 100644 --- a/11/debian/Dockerfile +++ b/11/debian/Dockerfile @@ -20,7 +20,7 @@ # OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN # THE SOFTWARE. -ARG version=4.3-2-jdk11 +ARG version=4.3-4-jdk11 FROM jenkins/agent:$version ARG version diff --git a/11/nanoserver-1809/Dockerfile b/11/nanoserver-1809/Dockerfile index 425c7821..f7d243b2 100644 --- a/11/nanoserver-1809/Dockerfile +++ b/11/nanoserver-1809/Dockerfile @@ -21,7 +21,7 @@ # OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN # THE SOFTWARE. -ARG VERSION=4.3-2 +ARG VERSION=4.3-4 FROM jenkins/agent:${VERSION}-nanoserver-1809-jdk11 ARG VERSION diff --git a/11/windowsservercore-1809/Dockerfile b/11/windowsservercore-1809/Dockerfile index 3ff83756..700c4429 100644 --- a/11/windowsservercore-1809/Dockerfile +++ b/11/windowsservercore-1809/Dockerfile @@ -21,7 +21,7 @@ # OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN # THE SOFTWARE. -ARG VERSION=4.3-2 +ARG VERSION=4.3-4 FROM jenkins/agent:${VERSION}-windowsservercore-1809-jdk11 LABEL Description="This is a base image, which allows connecting Jenkins agents via JNLP protocols on Windows" Vendor="Jenkins Project" Version="$VERSION" diff --git a/8/alpine/Dockerfile b/8/alpine/Dockerfile index 483d08c9..06db51e9 100644 --- a/8/alpine/Dockerfile +++ b/8/alpine/Dockerfile @@ -20,7 +20,7 @@ # OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN # THE SOFTWARE. -ARG version=4.3-2-alpine +ARG version=4.3-4-alpine FROM jenkins/agent:$version ARG version diff --git a/8/debian/Dockerfile b/8/debian/Dockerfile index f50306d2..89ce5c12 100644 --- a/8/debian/Dockerfile +++ b/8/debian/Dockerfile @@ -20,7 +20,7 @@ # OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN # THE SOFTWARE. -ARG version=4.3-2 +ARG version=4.3-4 FROM jenkins/agent:$version ARG version diff --git a/8/nanoserver-1809/Dockerfile b/8/nanoserver-1809/Dockerfile index 29a670e4..854b3a9b 100644 --- a/8/nanoserver-1809/Dockerfile +++ b/8/nanoserver-1809/Dockerfile @@ -21,7 +21,7 @@ # OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN # THE SOFTWARE. -ARG VERSION=4.3-2 +ARG VERSION=4.3-4 FROM jenkins/agent:${VERSION}-nanoserver-1809 LABEL Description="This is a base image, which allows connecting Jenkins agents via JNLP protocols on Windows" Vendor="Jenkins Project" Version="$VERSION" diff --git a/8/windowsservercore-1809/Dockerfile b/8/windowsservercore-1809/Dockerfile index fc29b8f8..e8af6379 100644 --- a/8/windowsservercore-1809/Dockerfile +++ b/8/windowsservercore-1809/Dockerfile @@ -21,7 +21,7 @@ # OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN # THE SOFTWARE. -ARG VERSION=4.3-2 +ARG VERSION=4.3-4 FROM jenkins/agent:${VERSION}-windowsservercore-1809 LABEL Description="This is a base image, which allows connecting Jenkins agents via JNLP protocols on Windows" Vendor="Jenkins Project" Version="$VERSION" From b0be42751f6a3463f32b694bc1da251498f9ac37 Mon Sep 17 00:00:00 2001 From: Oleg Nenashev Date: Mon, 13 Apr 2020 22:49:05 +0200 Subject: [PATCH 3/3] Fix tests after renaming of the base image --- tests/jnlpAgent.Tests.ps1 | 7 +++---- tests/tests.bats | 9 +++++---- 2 files changed, 8 insertions(+), 8 deletions(-) diff --git a/tests/jnlpAgent.Tests.ps1 b/tests/jnlpAgent.Tests.ps1 index cec9123a..2d2df49d 100644 --- a/tests/jnlpAgent.Tests.ps1 +++ b/tests/jnlpAgent.Tests.ps1 @@ -1,11 +1,11 @@ Import-Module -DisableNameChecking -Force $PSScriptRoot/test_helpers.psm1 -$AGENT_IMAGE='jenkins-jnlp-agent' -$AGENT_CONTAINER='pester-jenkins-jnlp-agent' +$AGENT_IMAGE='jenkins-inbound-agent' +$AGENT_CONTAINER='pester-jenkins-inbound-agent' $SHELL="powershell.exe" $FOLDER = Get-EnvOrDefault 'FOLDER' '' -$VERSION = Get-EnvOrDefault 'VERSION' '4.0.1-1' +$VERSION = Get-EnvOrDefault 'VERSION' '4.3-4' $REAL_FOLDER=Resolve-Path -Path "$PSScriptRoot/../${FOLDER}" @@ -106,7 +106,6 @@ Describe "[$JDK $FLAVOR] build args" { } It 'uses build args correctly' { - #$TEST_VERSION="3.36" $TEST_VERSION="4.3" $TEST_USER="foo" diff --git a/tests/tests.bats b/tests/tests.bats index b92970b4..3ff055e4 100755 --- a/tests/tests.bats +++ b/tests/tests.bats @@ -78,17 +78,18 @@ function teardown () { cd "${BATS_TEST_DIRNAME}"/.. || false local ARG_TEST_VERSION - local TEST_VERSION="3.36" + local TEST_VERSION="4.3" + local DOCKER_AGENT_VERSION_SUFFIX="4" local TEST_USER="root" if [[ "${FLAVOR}" = "debian" ]] then - ARG_TEST_VERSION="${TEST_VERSION}-1" + ARG_TEST_VERSION="${TEST_VERSION}-${DOCKER_AGENT_VERSION_SUFFIX}" elif [[ "${FLAVOR}" = "jdk11" ]] then - ARG_TEST_VERSION="${TEST_VERSION}-1-jdk11" + ARG_TEST_VERSION="${TEST_VERSION}-${DOCKER_AGENT_VERSION_SUFFIX}-jdk11" else - ARG_TEST_VERSION="${TEST_VERSION}-1-alpine" + ARG_TEST_VERSION="${TEST_VERSION}-${DOCKER_AGENT_VERSION_SUFFIX}-alpine" fi docker build \