engine: dynamic docker-ce version n (latest) and n-1

Signed-off-by: David Karlsson <35727626+dvdksn@users.noreply.github.com>
This commit is contained in:
David Karlsson 2024-12-10 09:51:14 +01:00
parent c24601654e
commit a1a44f462c
8 changed files with 22 additions and 21 deletions

View File

@ -119,8 +119,8 @@ $ sudo dnf config-manager --add-repo {{% param "download-url-base" %}}/docker-ce
```console
$ dnf list docker-ce --showduplicates | sort -r
docker-ce.x86_64 3:27.4.0-1.el9 docker-ce-stable
docker-ce.x86_64 3:27.3.1-1.el9 docker-ce-stable
docker-ce.x86_64 3:{{% param "docker_ce_version" %}}-1.el9 docker-ce-stable
docker-ce.x86_64 3:{{% param "docker_ce_version_prev" %}}-1.el9 docker-ce-stable
<...>
```
@ -129,7 +129,7 @@ $ sudo dnf config-manager --add-repo {{% param "download-url-base" %}}/docker-ce
Install a specific version by its fully qualified package name, which is
the package name (`docker-ce`) plus the version string (2nd column),
separated by a hyphen (`-`). For example, `docker-ce-3:27.4.0-1.el9`.
separated by a hyphen (`-`). For example, `docker-ce-3:{{% param "docker_ce_version" %}}-1.el9`.
Replace `<VERSION_STRING>` with the desired version and then run the following
command to install:

View File

@ -155,15 +155,15 @@ Docker from the repository.
# List the available versions:
$ apt-cache madison docker-ce | awk '{ print $3 }'
5:27.4.0-1~debian.12~bookworm
5:27.3.1-1~debian.12~bookworm
5:{{% param "docker_ce_version" %}}-1~debian.12~bookworm
5:{{% param "docker_ce_version_prev" %}}-1~debian.12~bookworm
...
```
Select the desired version and install:
```console
$ VERSION_STRING=5:27.4.0-1~debian.12~bookworm
$ VERSION_STRING=5:{{% param "docker_ce_version" %}}-1~debian.12~bookworm
$ sudo apt-get install docker-ce=$VERSION_STRING docker-ce-cli=$VERSION_STRING containerd.io docker-buildx-plugin docker-compose-plugin
```

View File

@ -116,8 +116,8 @@ $ sudo dnf-3 config-manager --add-repo {{% param "download-url-base" %}}/docker-
```console
$ dnf list docker-ce --showduplicates | sort -r
docker-ce.x86_64 3:27.4.0-1.fc41 docker-ce-stable
docker-ce.x86_64 3:27.3.1-1.fc41 docker-ce-stable
docker-ce.x86_64 3:{{% param "docker_ce_version" %}}-1.fc41 docker-ce-stable
docker-ce.x86_64 3:{{% param "docker_ce_version_prev" %}}-1.fc41 docker-ce-stable
<...>
```
@ -126,7 +126,7 @@ $ sudo dnf-3 config-manager --add-repo {{% param "download-url-base" %}}/docker-
Install a specific version by its fully qualified package name, which is
the package name (`docker-ce`) plus the version string (2nd column),
separated by a hyphen (`-`). For example, `docker-ce-3:27.4.0-1.fc41`.
separated by a hyphen (`-`). For example, `docker-ce-3:{{% param "docker_ce_version" %}}-1.fc41`.
Replace `<VERSION_STRING>` with the desired version and then run the following
command to install:

View File

@ -143,15 +143,15 @@ Docker from the repository.
# List the available versions:
$ apt-cache madison docker-ce | awk '{ print $3 }'
5:27.4.0-1~raspbian.12~bookworm
5:27.3.1-1~raspbian.12~bookworm
5:{{% param "docker_ce_version" %}}-1~raspbian.12~bookworm
5:{{% param "docker_ce_version_prev" %}}-1~raspbian.12~bookworm
...
```
Select the desired version and install:
```console
$ VERSION_STRING=5:27.4.0-1~raspbian.12~bookworm
$ VERSION_STRING=5:{{% param "docker_ce_version" %}}-1~raspbian.12~bookworm
$ sudo apt-get install docker-ce=$VERSION_STRING docker-ce-cli=$VERSION_STRING containerd.io docker-buildx-plugin docker-compose-plugin
```

View File

@ -119,8 +119,8 @@ $ sudo dnf config-manager --add-repo {{% param "download-url-base" %}}/docker-ce
```console
$ dnf list docker-ce --showduplicates | sort -r
docker-ce.x86_64 3:27.4.0-1.el9 docker-ce-stable
docker-ce.x86_64 3:27.3.1-1.el9 docker-ce-stable
docker-ce.x86_64 3:{{% param "docker_ce_version" %}}-1.el9 docker-ce-stable
docker-ce.x86_64 3:{{% param "docker_ce_version_prev" %}}-1.el9 docker-ce-stable
<...>
```
@ -129,7 +129,7 @@ $ sudo dnf config-manager --add-repo {{% param "download-url-base" %}}/docker-ce
Install a specific version by its fully qualified package name, which is
the package name (`docker-ce`) plus the version string (2nd column),
separated by a hyphen (`-`). For example, `docker-ce-3:27.4.0-1.el9`.
separated by a hyphen (`-`). For example, `docker-ce-3:{{% param "docker_ce_version" %}}-1.el9`.
Replace `<VERSION_STRING>` with the desired version and then run the following
command to install:

View File

@ -140,8 +140,8 @@ $ sudo zypper addrepo {{% param "download-url-base" %}}/docker-ce.repo
```console
$ sudo zypper search -s --match-exact docker-ce | sort -r
v | docker-ce | package | 3:27.4.0-1 | s390x | Docker CE Stable - s390x
v | docker-ce | package | 3:27.3.1-1 | s390x | Docker CE Stable - s390x
v | docker-ce | package | 3:{{% param "docker_ce_version" %}}-1 | s390x | Docker CE Stable - s390x
v | docker-ce | package | 3:{{% param "docker_ce_version_prev" %}}-1 | s390x | Docker CE Stable - s390x
```
The list returned depends on which repositories are enabled, and is specific
@ -149,7 +149,7 @@ $ sudo zypper addrepo {{% param "download-url-base" %}}/docker-ce.repo
Install a specific version by its fully qualified package name, which is
the package name (`docker-ce`) plus the version string (2nd column),
separated by a hyphen (`-`). For example, `docker-ce-3:27.4.0`.
separated by a hyphen (`-`). For example, `docker-ce-3:{{% param "docker_ce_version" %}}`.
Replace `<VERSION_STRING>` with the desired version and then run the following
command to install:

View File

@ -158,15 +158,15 @@ Docker from the repository.
# List the available versions:
$ apt-cache madison docker-ce | awk '{ print $3 }'
5:27.4.0-1~ubuntu.24.04~noble
5:27.3.1-1~ubuntu.24.04~noble
5:{{% param "docker_ce_version" %}}-1~ubuntu.24.04~noble
5:{{% param "docker_ce_version_prev" %}}-1~ubuntu.24.04~noble
...
```
Select the desired version and install:
```console
$ VERSION_STRING=5:27.4.0-1~ubuntu.24.04~noble
$ VERSION_STRING=5:{{% param "docker_ce_version" %}}-1~ubuntu.24.04~noble
$ sudo apt-get install docker-ce=$VERSION_STRING docker-ce-cli=$VERSION_STRING containerd.io docker-buildx-plugin docker-compose-plugin
```

View File

@ -108,6 +108,7 @@ params:
latest_engine_api_version: "1.47"
docker_ce_version: "27.4.0"
docker_ce_version_prev: "27.3.1"
compose_version: "v2.30.3"
compose_file_v3: "3.8"
compose_file_v2: "2.4"