Commit graph

12 commits

Author SHA1 Message Date
Debarshi Ray
8ef3dd997e .github/workflows: Bump Bats to 1.10.0 for CI on Ubuntu 22.04
https://github.com/containers/toolbox/pull/1352
2023-08-18 07:01:41 +02:00
Debarshi Ray
8c28dc2660 .github/workflows: Run the CI on Ubuntu 22.04
Now that Toolbx offers built-in support for Ubuntu containers [1],
adding an Ubuntu host to the upstream CI will help ensure that Toolbx
continues to work well on Ubuntu.  Ubuntu 22.04 is the latest long term
support (or LTS) release [2] from Ubuntu, and is the latest Ubuntu
version that GitHub provides runners for [3].

Ubuntu 22.04 only has Bats 1.2.1 [4], while Toolbx requires 1.7.0 [5];
and Shadow 4.8 [6], while Toolbx requires 4.9 because it needs
libsubid.so [7,8].  Hence, newer versions of these dependencies need to
be built to run the tests.  The build flags for Shadow were taken from
the Debian package [9].

A separate sub-directory inside $GITHUB_WORKSPACE [10] is used for
Toolbx itself to prevent codespell from getting triggered by spelling
mistakes in these dependencies themselves [11].

Unfortunately, the SHELL environment variable goes mysteriously missing
from the runtime environment of the GitHub Actions workflow [12].  This
breaks the 'create' and 'enter' commands, and therefore tests involving
them can't be run until this is resolved.  Meanwhile, running the CI on
Ubuntu with a subset of the tests, is still better than not running the
CI on Ubuntu at all.

[1] Commit a84a358b3b
    https://github.com/containers/toolbox/pull/483
    https://github.com/containers/toolbox/pull/1284

[2] https://wiki.ubuntu.com/Releases

[3] https://docs.github.com/en/actions/using-github-hosted-runners/about-github-hosted-runners

[4] https://packages.ubuntu.com/jammy/bats

[5] Commit e22a82fec8
    https://github.com/containers/toolbox/pull/1273

[6] https://packages.ubuntu.com/source/jammy/shadow
    https://packages.ubuntu.com/source/jammy-updates/shadow

[7] Shadow commit 0a7888b1fad613a0
    https://github.com/shadow-maint/shadow/commit/0a7888b1fad613a0
    https://github.com/shadow-maint/shadow/issues/154

[8] Commit ca8007c192
    https://github.com/containers/toolbox/issues/1074

[9] https://salsa.debian.org/debian/shadow/

[10] https://docs.github.com/en/actions/learn-github-actions/variables

[11] https://github.com/bats-core/bats-core/pull/743

[12] https://github.com/orgs/community/discussions/59413

https://github.com/containers/toolbox/pull/1319
2023-06-27 13:08:05 +02:00
Debarshi Ray
33815da389 .github/workflows: Build the Arch Linux image for pull requests
... when there are changes in the 'images/arch' directory or in the
GitHub workflow itself.

https://github.com/containers/toolbox/pull/1308
2023-06-09 13:32:28 +02:00
Debarshi Ray
a4e5861ae5 .github/workflows: Publish the Arch Linux image at quay.io/toolbx/...
Until now, the Arch Linux image was being published at
quay.io/toolbx-images/archlinux-toolbox:latest.  This renames the image
to arch-toolbox [1] to match the os-release(5) ID on Arch, and changes
the location to quay.io/toolbx/arch-toolbox:latest.

Build and push when there are changes in the 'images/arch' directory
or in the GitHub workflow itself, as well as at 00:00 every Monday.

[1] Commit 2568528cb7
    https://github.com/containers/toolbox/pull/861

https://github.com/containers/toolbox/pull/1308
2023-06-09 13:32:28 +02:00
Ievgen Popovych
8dcd5d7cb4 .github/workflows: Publish the Ubuntu images at quay.io/toolbx/...
Until now, the Ubuntu images (versions 16.04, 18.04, 20.04, 22.04 and
22.10) were published at quay.io/toolbx-images/ubuntu-toolbox:22.04,
etc..  This changes the location to quay.io/toolbx/ubuntu-toolbox:22.04
and builds an image for Ubuntu 23.04 that was added recently [1].

Build and push when there are changes in the `images/ubuntu` directory
or in the GitHub workflow itself, as well as every other week (7th and
21st days of a month to be precise).

The toolbox(1) code and the system tests will be switched to the new
location after the first round of images are available.

[1] Commit 3cfb6bf888
    https://github.com/containers/toolbox/pull/1292

https://github.com/containers/toolbox/pull/483

Signed-off-by: Ievgen Popovych <jmennius@gmail.com>
2023-06-08 14:52:31 +02:00
Debarshi Ray
825c7e8594 .github/workflows: Remove golangci-lint
The previous commit broke the golangci-lint test [1] because the GitHub
Action runs on Ubuntu 22.04, which only has Shadow 4.8 [2], whereas
libsubid.so was introduced in Shadow 4.9 [3].

However, that's not a big deal because 'go vet' was earlier added to the
set of tests run by 'meson test' [4], and 'go vet' is one of the linters
run by golangci-lint [5].  So, while it's not a proper replacement, it's
good enough.

[1] Commit ca8007c192
    https://github.com/containers/toolbox/pull/1180

[2] https://packages.ubuntu.com/source/jammy/shadow
    https://packages.ubuntu.com/source/jammy-updates/shadow

[3] Shadow commit 0a7888b1fad613a0
    https://github.com/shadow-maint/shadow/commit/0a7888b1fad613a0
    https://github.com/shadow-maint/shadow/issues/154

[4] Commit f695012faf
    https://github.com/containers/toolbox/pull/1186

[5] https://golangci-lint.run/usage/linters/
    https://golangci-lint.run/usage/linters/#govet

This reverts commit 7c86f30b77.

https://github.com/containers/toolbox/pull/1221
2023-01-29 11:32:03 +01:00
Ondřej Míchal
9bffbb7e13 Revert "ci: Build & Publish Fedora Toolbx images with GitHub Packages"
This revert is done based on discussion happening around the PR that
originally added the change[0].

This reverts commit 818748001c.

[0] https://github.com/containers/toolbox/pull/973

https://github.com/containers/toolbox/pull/1028
2022-03-20 21:11:32 +02:00
Ondřej Míchal
5d61a74b1a ci: Set full path to Containerfile
The action does not use provided context when looking for a
Containerfile[0].

[0] https://github.com/redhat-actions/buildah-build/issues/44

https://github.com/containers/toolbox/pull/981
2022-01-10 13:40:32 +02:00
Ondřej Míchal
05eef2aaa6 ci: Add manual trigger to image factory pipeline
https://github.com/containers/toolbox/pull/981
2022-01-10 13:40:32 +02:00
Ondřej Míchal
818748001c ci: Build & Publish Fedora Toolbx images with GitHub Packages
For the sake of greater control over the testing of images and for having an
infrustructure for hosting images that are not endorsed by the distirbutions.

The images are to be rebuilt every day at midnight.

https://github.com/containers/toolbox/pull/973
2022-01-09 18:16:47 +01:00
Ondřej Míchal
46ff946190 ci: Remove only-new-issues option from linter run
The option is mutually exclusive with the working-directory option that
we need to use due to Toolbx code residing in a subdirectory. The tool
itself does not work recursively.

Fallout from https://github.com/containers/toolbox/pull/974

https://github.com/containers/toolbox/pull/978
2022-01-09 17:01:40 +01:00
Ondřej Míchal
7c86f30b77 ci: Add golangci linter
Use machines to do (at least some) of the work humans had to do!

https://github.com/containers/toolbox/pull/974
2022-01-09 16:29:32 +01:00