Commit Graph
442 Commits
Author SHA1 Message Date
Sebastiaan van Stijn c435f9da96 gha: temporarily disable CentOS 9
Looks like their package repositories are having a bad day, or changes
were made (again);

    # Executing docker install script, commit: 60327925bf2a9c6f81084661b0c05edc8263a3c9
    + sh -c 'yum install -y -q yum-utils'
    Error: Failed to download metadata for repo 'baseos': Cannot download repomd.xml: Cannot download repodata/repomd.xml: All mirrors were tried

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2023-04-05 02:55:59 +02:00
Sebastiaan van Stijn 9ebb4c54d6 Merge pull request #350 from thaJeztah/rootless_24.0.0-beta.1
rootless: update test version to 24.0.0-beta.1
2023-04-01 10:55:18 +02:00
Sebastiaan van Stijn 6f87454862 rootless: update test version to 24.0.0-beta.1
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2023-04-01 02:33:04 +02:00
Sebastiaan van Stijn 98a5ca00c4 Merge pull request #349 from thaJeztah/no_scan
remove redundant install for scan-cli-plugin
2023-03-31 12:26:06 +02:00
Sebastiaan van Stijn 7637810ffb remove redundant install for scan-cli-plugin
This explict install was added because docker 20.10 did not have an explicit
dependency on the plugin. The current release of the Docker CLI (23.0) already
has a "Recommends:" dependency on the plugin, and 0095742fb5
removed the "--no-install-recommends", so fresh installs of Docker 23.0 will
already install this plugin through that dependency.

Removing the explicit install, because the scan-cli-plugin has been deprecated,
and will no longer receive updates, so we don't want it to be installed for the
upcoming 24.0 release when using this script. see;
https://github.com/docker/scan-cli-plugin/blob/b69ac460a6c23243b858326f0e26f6bd202ca781/internal/deprecation.go#L13-L15

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2023-03-31 09:50:47 +02:00
Sebastiaan van Stijn 93bb55b16a Merge pull request #348 from thaJeztah/update_gha
gha: update distros and version to install
2023-03-29 13:36:48 +02:00
Sebastiaan van Stijn f53d3783c7 Merge pull request #347 from thaJeztah/rootless_23.0.2
update rootless-install to 23.0.2
2023-03-29 13:34:02 +02:00
Sebastiaan van Stijn f529a2b4c2 Makefile: update default test image to ubuntu 22.04
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2023-03-28 19:00:15 +02:00
Sebastiaan van Stijn 4e1b4d2418 gha: update distros and version to install
- updating the "version" to install to 20.10 (previous version)
- remove ubuntu 18.04, as it's EOL soon
- add last 2 LTS versions of Ubuntu
- add centos:9 (stream)

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2023-03-28 18:59:14 +02:00
Sebastiaan van Stijn 781a0f41d0 gha: update actions/checkout@v3
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2023-03-28 18:37:51 +02:00
Sebastiaan van Stijn 92a08e1bb9 update rootless-install to 23.0.2
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2023-03-28 18:36:16 +02:00
Sebastiaan van Stijn 1faa633ff7 Merge pull request #345 from thaJeztah/add_bookworm
Fix installation on debian testing (bookworm) (carry 327)
2023-03-27 13:59:40 +02:00
Sebastiaan van Stijn 0f84e6afbc Merge pull request #346 from thaJeztah/update_deprecated_distros
print deprecation warning for Fedora 35 and before
2023-03-27 13:59:02 +02:00
Orgad Shaneh d6a9169a9a Fix installation on debian testing (bookworm)
We published packages now for Debian 12 (bookworm) for testing, so we can
update this to use the correct version;
https://download.docker.com/linux/debian/dists/bookworm/pool/stable/amd64/

Co-Authored-by: Orgad Shaneh <orgads@gmail.com>
Signed-off-by: Orgad Shaneh <orgads@gmail.com>
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2023-03-27 12:54:54 +02:00
Sebastiaan van Stijn 53d51b8ffe print deprecation warning for Fedora 35 and before
Fedora 35 reached EOL on December 13, 2022, and we're no longer
building new packages for it;;

https://docs.fedoraproject.org/en-US/releases/eol/

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2023-03-27 12:51:43 +02:00
Sebastiaan van Stijn 3f7bc2c236 Merge pull request #344 from thaJeztah/rootless_23.0.1
update rootless-install to 23.0.1
2023-03-25 18:29:40 +01:00
Sebastiaan van Stijn c3392ff625 update rootless-install to 23.0.1
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2023-03-25 16:30:19 +01:00
Sebastiaan van Stijn 6647403454 Merge pull request #336 from thaJeztah/simplify_conditionals
deb: simplify version-conditional installs
2023-02-03 10:57:58 +01:00
Sebastiaan van Stijn f7f1ab8d58 deb: simplify version-conditional installs
Now that 0095742fb5 removed the "--no-install-recommends"
option for all packages, we no longer need to special-case installation of the rootless-extras
package.

This patch moves the package together with other conditional packages for 20.10 and up. The
order of these conditionals was updated to match the equivalent steps of the RPM packages.

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2023-02-03 10:49:23 +01:00
Sebastiaan van Stijn 42b0cfaf0c Merge pull request #338 from thaJeztah/sles_remove_rootless_pkg_version
SLES: remove unused rootless_pkg_version
2023-02-03 10:48:49 +01:00
Sebastiaan van Stijn b1a0c98b21 Merge pull request #337 from thaJeztah/rootless_23.0.0
update rootless-install to 23.0.0
2023-02-03 10:47:49 +01:00
Sebastiaan van Stijn d1340df1b7 Merge pull request #335 from thaJeztah/install_recommends
deb: remove --no-install-recommends
2023-02-03 10:46:46 +01:00
Sebastiaan van Stijn 989df6a284 SLES: remove unused rootless_pkg_version
This variable was introduced in 63fb2060c9, but
was later refactored in ab03892649 aligned the
installation steps for SLES with the other distros (using the version of the
"docker-ce" package itself, as those versions always match).

This patch removes the unused rootless_pkg_version variable, and the code to
resolve that version.

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2023-02-03 10:26:52 +01:00
Sebastiaan van Stijn 3e34cf16a9 update rootless-install to 23.0.0
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2023-02-03 10:23:28 +01:00
Sebastiaan van Stijn 0095742fb5 deb: remove --no-install-recommends
The installation for deb packages used a --no-install-recommends to skip "recommended"
packages. This flag was added in ab5553e302 to work around
an issue on Ubuntu 17.10 (which had aufs-tools as recommended dependency), causing the
kernel to be updated.

While "recommended" packages _can_ be omitted during installation, they are
a "strong" recommendation, and should really be installed by default:

> Recommends
>
> This declares a strong, but not absolute, dependency.
> The Recommends field should list packages that would be found together
> with this one in all but unusual installations.

Including the `--no-install-recommends` option could result in `apparmor_parser`
binary (part of the `apparmor` package) to be missing, which would cause
the daemon failing to start on systems with AppArmor support enabled:

    Error response from daemon: AppArmor enabled on system but the docker-default profile could not be loaded: running `apparmor_parser apparmor_parser --version` failed with output:
    error: exec: "apparmor_parser": executable file not found in $PATH
    Error: failed to start containers: somecontainer

This patch removes the `--no-install-recommends` so that the recommended
packages are installed.

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2023-02-03 09:59:44 +01:00
Sebastiaan van Stijn c044d7d311 Merge pull request #334 from crazy-max/fix-buildx
fix buildx install
2023-02-02 21:12:15 +01:00
CrazyMax 1cb5c544e2 fix buildx install
Signed-off-by: CrazyMax <crazy-max@users.noreply.github.com>
2023-02-02 21:04:55 +01:00
Sebastiaan van Stijn 1d97565eca Merge pull request #330 from thaJeztah/fix_version_matching
fix matching of package versions on debian, ubuntu, and raspbian
2023-01-12 00:21:20 +01:00
Sebastiaan van Stijn 62046868dc Merge pull request #331 from thaJeztah/bump_rootless_install
rootless: update versions to 20.10.22 (stable) and 23.0.0-rc.1 (testing)
2023-01-12 00:20:28 +01:00
Sebastiaan van Stijn 5429d31315 rootless: update test version to 23.0.0-rc.1
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2023-01-11 23:46:52 +01:00
Sebastiaan van Stijn 996a1f9a9f rootless: update stable version to 20.10.22
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2023-01-11 23:46:21 +01:00
Sebastiaan van Stijn d32be0ab1d fix matching of package versions on debian, ubuntu, and raspbian
The version-format of the packages changed in the docker-ce-packaging repo;
https://github.com/docker/docker-ce-packaging/commit/39772a761dfdf810cc23a1ec6084ea3100e6abf0

Which caused the script to fail when specifying a version:

    INFO: Searching repository for VERSION '23.0.0-rc.2'
    INFO: apt-cache madison 'docker-ce' | grep '23.0.0.*rc.2.*-0~debian' | head -1 | awk '{$1=$1};1' | cut -d' ' -f 3

    ERROR: '23.0.0-rc.2' not found amongst apt-cache madison results

Looking at that search, it seemed like it was overly strict;

- matching the distro (debian, ubuntu, or raspbian), which should not be needed,
  assuming the package repository has been set up correctly (which the script
  does in earlier steps).
- matching the "0" prefix, which was intended to be used a package-revision (so
  to allow for packaging-only releases). That part definitely shouldn't be done,
  as it would not match later revisions (1, 2, 3)

This patch simplifies the matching, and only searches for the package name, and
the version specified, which should satisfy the requirement;

    apt-cache madison 'docker-ce' | grep '23.0.0.*rc.2' | head -1 | awk '{$1=$1};1' | cut -d' ' -f 3
    5:23.0.0~rc.2-1~ubuntu.22.04~jammy

    apt-cache madison 'docker-ce-cli' | grep '23.0.0.*rc.2' | head -1 | awk '{$1=$1};1' | cut -d' ' -f 3
    5:23.0.0~rc.2-1~ubuntu.22.04~jammy

With this patch applied, the installation succeeds:

    cat install.sh | DOWNLOAD_URL=https://download-stage.docker.com CHANNEL=test VERSION=23.0.0-rc.2 REPO_FILE=docker-ce-staging.repo sh
    ...
    INFO: Searching repository for VERSION '23.0.0-rc.2'
    INFO: apt-cache madison 'docker-ce' | grep '23.0.0.*rc.2' | head -1 | awk '{$1=$1};1' | cut -d' ' -f 3
    INFO: apt-cache madison 'docker-ce-cli' | grep '23.0.0.*rc.2' | head -1 | awk '{$1=$1};1' | cut -d' ' -f 3
    + sh -c DEBIAN_FRONTEND=noninteractive apt-get install -y -qq --no-install-recommends docker-ce=5:23.0.0~rc.2-1~ubuntu.22.04~jammy docker-ce-cli=5:23.0.0~rc.2-1~ubuntu.22.04~jammy containerd.io docker-compose-plugin docker-scan-plugin docker-buildx-plugin >/dev/null

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2023-01-11 23:41:58 +01:00
Sebastiaan van Stijn 00ffef53ad Merge pull request #319 from thaJeztah/rootless_20.10.21
update rootless-install to 20.10.21
2022-10-25 17:52:50 -04:00
Sebastiaan van Stijn 54e3d6325a update rootless-install to 20.10.21
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2022-10-25 17:30:20 -04:00
Sebastiaan van Stijn af4386b65c Merge pull request #317 from thaJeztah/rootless_20.10.20
update rootless-install to 20.10.20
2022-10-19 10:32:09 +02:00
Sebastiaan van Stijn c8a23ecfa9 update rootless-install to 20.10.20
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2022-10-19 10:05:49 +02:00
Sebastiaan van Stijn 487d349baf Merge pull request #316 from thaJeztah/rootless_20.10.19
update rootless-install to 20.10.19
2022-10-18 14:38:08 +02:00
Sebastiaan van Stijn 4112fb6983 update rootless-install to 20.10.19
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2022-10-18 14:35:27 +02:00
Sebastiaan van Stijn 5ac4196e77 Merge pull request #312 from AkihiroSuda/rootless-20.10.18
update rootless-install to 20.10.18
2022-09-21 13:44:08 +02:00
Akihiro Suda 835c5bec9a update rootless-install to 20.10.18
Signed-off-by: Akihiro Suda <akihiro.suda.cz@hco.ntt.co.jp>
2022-09-10 22:46:58 +09:00
Sebastiaan van Stijn 4f282167c4 Merge pull request #310 from thaJeztah/remove_checks
fix "REPO_FILE" checks always running, also with "dry run" enabled
2022-08-29 16:23:27 +02:00
Sebastiaan van Stijn 0c9037543e fix "REPO_FILE" checks always running, also with "dry run" enabled
These checks were originally added in 3217c543b4,
which added a `REPO_FILE` variable. While it's with good intent to do a check
if the URL is valid, there are some issues with these checks;

The checks depend on `curl`, but are executed _before_ `pre_reqs` are installed,
so will produce an error if `curl` is not found;

    ./install.sh
    # Executing docker install script, commit:
    ./install.sh: line 469: curl: command not found
    Error: Unable to curl repository file https://download.docker.com/linux/fedora/docker-ce.repo, is it valid?

The checks are currently always performed, also if `DRY_RUN=1` is enabled;

    DRY_RUN=1 REPO_FILE=no-such.repo ./install.sh
    # Executing docker install script, commit:
    Error: Unable to curl repository file https://download.docker.com/linux/fedora/no-such.repo, is it valid?

This patch removes the checks to address the above, and to simplify the script.
Running the script will still fail if an invalid URL is used for the `.repo` file,
which fails the script after the `pre_reqs` are installed;

With this patch:

When running the script with `DRY_RUN=1`:

    DRY_RUN=1 ./install.sh
    # Executing docker install script, commit:
    dnf install -y -q dnf-plugins-core
    dnf config-manager --add-repo https://download.docker.com/linux/fedora/docker-ce.repo
    dnf makecache
    dnf install -y -q docker-ce docker-ce-cli containerd.io docker-scan-plugin docker-compose-plugin docker-ce-rootless-extras

When running the script with `DRY_RUN=1` and an invalid repo, the script
completes successfully, but will show the commands it will run, including
the invalid URL:

    DRY_RUN=1 REPO_FILE=no-such.repo ./install.sh
    # Executing docker install script, commit:
    dnf install -y -q dnf-plugins-core
    dnf config-manager --add-repo https://download.docker.com/linux/fedora/no-such.repo
    dnf makecache
    dnf install -y -q docker-ce docker-ce-cli containerd.io docker-scan-plugin docker-compose-plugin docker-ce-rootless-extras

When running the script with an invalid repo URL, it will fail early (after
installing `pre_reqs`:

    REPO_FILE=no-such.repo ./install.sh

    # Executing docker install script, commit:
    + sh -c 'dnf install -y -q dnf-plugins-core'
    ...

    + sh -c 'dnf config-manager --add-repo https://download.docker.com/linux/fedora/no-such.repo'
      Adding repo from: https://download.docker.com/linux/fedora/no-such.repo
      Status code: 404 for https://download.docker.com/linux/fedora/no-such.repo (IP: 65.9.86.56)
      Error: Configuration of repo failed

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2022-08-29 14:52:08 +02:00
Sebastiaan van Stijn 170a1cd88f Merge pull request #306 from linux-on-ibm-z/sles-fix
Adds SLES 15-SP4 support
2022-08-29 13:44:18 +02:00
Prabhav Thali 4d8fdb9633 Adds SLES 15-SP4 support
Signed-off-by: Prabhav Thali <Prabhav.Thali1@ibm.com>
2022-08-29 16:55:22 +05:30
Sebastiaan van Stijn ea9a00694b Merge pull request #309 from thaJeztah/shellcheck_ignore
shellcheck: ignore SC2317
2022-08-26 00:46:00 +02:00
Sebastiaan van Stijn 0f72df0a14 shellcheck: ignore SC2317
This check gives a lot of false positives; ignoring it;

```
In build/install.sh line 106:
	set +x
        ^----^ SC2317 (info): Command appears to be unreachable. Check usage (or ignore if invoked indirectly).

In build/install.sh line 108:
	yy_a="$(echo "$1" | cut -d'.' -f1)"
        ^-- SC2317 (info): Command appears to be unreachable. Check usage (or ignore if invoked indirectly).
                ^-----------------------^ SC2317 (info): Command appears to be unreachable. Check usage (or ignore if invoked indirectly).

In build/install.sh line 109:
	yy_b="$(echo "$2" | cut -d'.' -f1)"
        ^-- SC2317 (info): Command appears to be unreachable. Check usage (or ignore if invoked indirectly).
                ^-----------------------^ SC2317 (info): Command appears to be unreachable. Check usage (or ignore if invoked indirectly).

In build/install.sh line 110:
	if [ "$yy_a" -lt "$yy_b" ]; then
        ^-- SC2317 (info): Command appears to be unreachable. Check usage (or ignore if invoked indirectly).
           ^---------------------^ SC2317 (info): Command appears to be unreachable. Check usage (or ignore if invoked indirectly).

In build/install.sh line 111:
		return 1
                ^------^ SC2317 (info): Command appears to be unreachable. Check usage (or ignore if invoked indirectly).

In build/install.sh line 113:
	if [ "$yy_a" -gt "$yy_b" ]; then
        ^-- SC2317 (info): Command appears to be unreachable. Check usage (or ignore if invoked indirectly).
           ^---------------------^ SC2317 (info): Command appears to be unreachable. Check usage (or ignore if invoked indirectly).

In build/install.sh line 114:
		return 0
                ^------^ SC2317 (info): Command appears to be unreachable. Check usage (or ignore if invoked indirectly).

In build/install.sh line 116:
	mm_a="$(echo "$1" | cut -d'.' -f2)"
        ^-- SC2317 (info): Command appears to be unreachable. Check usage (or ignore if invoked indirectly).
                ^-----------------------^ SC2317 (info): Command appears to be unreachable. Check usage (or ignore if invoked indirectly).

In build/install.sh line 117:
	mm_b="$(echo "$2" | cut -d'.' -f2)"
        ^-- SC2317 (info): Command appears to be unreachable. Check usage (or ignore if invoked indirectly).
                ^-----------------------^ SC2317 (info): Command appears to be unreachable. Check usage (or ignore if invoked indirectly).

In build/install.sh line 118:
	if [ "${mm_a#0}" -lt "${mm_b#0}" ]; then
        ^-- SC2317 (info): Command appears to be unreachable. Check usage (or ignore if invoked indirectly).
           ^-----------------------------^ SC2317 (info): Command appears to be unreachable. Check usage (or ignore if invoked indirectly).

In build/install.sh line 119:
		return 1
                ^------^ SC2317 (info): Command appears to be unreachable. Check usage (or ignore if invoked indirectly).

In build/install.sh line 122:
	return 0
        ^------^ SC2317 (info): Command appears to be unreachable. Check usage (or ignore if invoked indirectly).

In build/install.sh line 659:
	exit 1
        ^----^ SC2317 (info): Command appears to be unreachable. Check usage (or ignore if invoked indirectly).

For more information:
  https://www.shellcheck.net/wiki/SC2317 -- Command appears to be unreachable...
make: *** [Makefile:20: shellcheck] Error 1
```

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2022-08-25 22:13:47 +02:00
Sebastiaan van Stijn b2e29ef7a9 Merge pull request #295 from thaJeztah/add_buildx_package
install docker-buildx-plugin on >= 22.06 (test channel only currently)
2022-06-07 11:51:18 +02:00
Sebastiaan van Stijn df6b6926dc install docker-buildx-plugin on >= 22.06 (test channel only currently)
The buildx plugin has moved to a separate package for the 22.06 release.
We're currently doing test-builds on staging, so only try to install
this when using both the "test" channel and the staging domain.

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2022-06-07 03:39:16 +02:00
Sebastiaan van Stijn ed679a8000 Merge pull request #297 from thaJeztah/update_rootless2
update rootless-install to 20.10.17
2022-06-07 03:38:02 +02:00
Sebastiaan van Stijn 307042a58d update rootless-install to 20.10.17
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2022-06-07 03:33:16 +02:00