Commit Graph

968 Commits

Author SHA1 Message Date
OpenShift Merge Robot ca6ae5ca98
Merge pull request #16678 from edsantiago/simplify_passthrough_env
CI setup: simplify environment passthrough code
2022-12-03 07:26:34 -05:00
OpenShift Merge Robot 3f80a68fd3
Merge pull request #16667 from cfergeau/artifacts
Make released binary names more consistent
2022-12-03 07:20:08 -05:00
Ed Santiago bdd5f82458 CI setup: simplify environment passthrough code
The passthrough_env function was unnecessarily complicated,
hence fragile. Clean it up, and add regression tests.

For future reference: CI broke horribly because of this.
Rootless tests all failed with missing CI_DESIRED_NETWORK.
Root cause was that CIRRUS_CHANGE_TITLE had a trailing
space which, because of shell indirection, passthrough_env()
wrote as trailing backslash (not backslash-space) in the
/etc/ci_environment file, which then caused the next line
in the file to get glommed onto CIRRUS_CHANGE_TITLE.

Signed-off-by: Ed Santiago <santiago@redhat.com>
2022-12-01 16:19:22 -07:00
Christophe Fergeau 54ef7f98d9 macos: pkg: Use -arm64 suffix instead of -aarch64
All files released in
https://github.com/containers/podman/releases/tag/v4.3.1 use -arm64 for
the arch name except podman-installer-macos-aarch64.pkg

Related: https://github.com/containers/podman/issues/16612
Signed-off-by: Christophe Fergeau <cfergeau@redhat.com>
2022-11-29 11:18:21 +01:00
Christophe Fergeau fe548dd0b0 linux: Add -linux suffix to podman-remote-static binaries
This is more consistent with the name of the other released files, and
makes identification of the binaries easier among the Windows/macOS
ones.

Related: https://github.com/containers/podman/issues/16612
Signed-off-by: Christophe Fergeau <cfergeau@redhat.com>
2022-11-29 11:18:20 +01:00
Christophe Fergeau d223950078 linux: Build amd64 and arm64 podman-remote-static binaries
Looking at https://github.com/containers/podman/releases/tag/v4.3.1,
it's not explicit which arch the podman-remote-static binary is built
for, so this commit adds an -$(goarch) suffix to it. It builds both
arm64 and amd64 binaries as I need both for crc.

Signed-off-by: Christophe Fergeau <cfergeau@redhat.com>
2022-11-29 11:18:18 +01:00
Jason T. Greene d2ac99d65c Allow manual override of install location
Also reuse install location for previous installs if present

Example Usage: .\podman-4.3.2-setup.exe InstallFolder=C:\Other\Loc

Signed-off-by: Jason T. Greene <jason.greene@redhat.com>
2022-11-28 15:46:35 -06:00
Ed Santiago 34020b353a CI: Package versions: run in the 'main' step
...not as a separate post-main step. Reasons:

 1) If main test times out, Cirrus won't run subsequent steps
 2) It really belongs in the main log anyway, because when
    looking at test results, you want to have instant access
    to versions, you don't want to have to clickety-click
    ten steps.

Signed-off-by: Ed Santiago <santiago@redhat.com>
2022-11-16 06:52:07 -07:00
Anjan Nath f0dba82bb3 pkginstaller: bump Qemu to version 7.1.0
this updates the Makefile qemu version to make use new qemu released at
https://github.com/containers/podman-machine-qemu/releases/tag/v7.1.0-1

[NO NEW TESTS NEEDED]

Signed-off-by: Anjan Nath <kaludios@gmail.com>
2022-11-14 11:59:06 +05:30
OpenShift Merge Robot 911dc94d23
Merge pull request #16478 from edsantiago/docs_version_check
[CI:DOCS] New tool, docs/version-check
2022-11-10 19:48:09 +00:00
OpenShift Merge Robot 4a4d35d5f4
Merge pull request #16414 from cevich/fix_cirrus_cron_jobs
[CI:BUILD] Fix cirrus cirrus-cron GHA workflow scripts, add checks, and tests
2022-11-10 17:16:38 +00:00
Ed Santiago db439dd23e New tool, docs/version-check
Intended to be run from nightly Cirrus cron job.

 1) Queries github for highest-sorting (not necessarily "latest") tag
 2) Checks that the Windows MSI exists, fails if not
 3) Cross-checks markdown files to ensure they have up-to-date links

When run interactively, it will auto-update the .md files
to show and link to the latest version. This makes it easy
for anyone to then submit an update PR.

And, it turns out that MSI is obsolete, the new thing is EXE.
Update the tutorials to reflect that.

Signed-off-by: Ed Santiago <santiago@redhat.com>
2022-11-10 08:54:56 -07:00
Valentin Rothberg 4408072108 contrib/cirrus/check_go_changes.sh: ignore test/tools/vendor
To avoid false positives if dependencies get bumped in test/tools.

Signed-off-by: Valentin Rothberg <vrothberg@redhat.com>
2022-11-10 10:39:27 +01:00
Chris Evich 0334d8d611
Cirrus: Add tests for GHA scripts
Also, fix the rerun_cirrus_cron workflow.  Thanks @ygalblum for spotting
the error.

Signed-off-by: Chris Evich <cevich@redhat.com>
2022-11-07 11:47:30 -05:00
Chris Evich d17b7d852a
Cirrus: Shellcheck github-action scripts
Signed-off-by: Chris Evich <cevich@redhat.com>
2022-11-07 11:46:34 -05:00
Chris Evich 2ee40287e0
Cirrus: shellcheck support for github-action scripts
This should help catch some obvious gaffs and/or style/lint type
problems.  Maybe.

Signed-off-by: Chris Evich <cevich@redhat.com>
2022-11-07 11:46:34 -05:00
Daniel J Walsh efbad590d7
Run codespell on code
Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
2022-11-04 10:57:41 -04:00
Chris Evich f3195c930b
Cirrus: Never skip running Windows Cross task
All the other Windows tasks depend on access to a podman-remote build
from the Alt. Arch. `Windows Cross` task.  Re-arrange the test-skipping
call to never skip here only.

Signed-off-by: Chris Evich <cevich@redhat.com>
2022-11-03 16:17:24 -04:00
Ed Santiago d7e70c7489 CI: set and verify DESIRED_NETWORK (netavark, cni)
We have CI tests running in netavark mode when CNI is desired.
Add a new .cirrus.yml envariable, CI_DESIRED_NETWORK, which
we then force-check in e2e and system tests. Simple copy/paste
of #14912 (the RUNTIME check) with manual s/RUNTIME/NETWORK/
and other minor changes.

Signed-off-by: Ed Santiago <santiago@redhat.com>
2022-11-03 04:40:42 -06:00
Chris Evich 8530724555
Cirrus: Guarantee CNI testing w/o nv/av present
Comments added to code for clarity.

Signed-off-by: Chris Evich <cevich@redhat.com>
2022-11-02 13:42:06 -04:00
Chris Evich ecd1927b4c
Cirrus: Update to F37beta
Signed-off-by: Chris Evich <cevich@redhat.com>
2022-11-02 13:38:28 -04:00
Jason T. Greene 884350d999 Add Windows Smoke Testing
Signed-off-by: Jason T. Greene <jason.greene@redhat.com>
2022-11-02 00:52:09 -05:00
Ed Santiago f0f12658de Test runners: nuke podman from $PATH before tests
We've had some oopsies in system tests:

    podman foo bar
    run podman foo bar

...all of which should be run_podman with underscore. Those
have been passing because /usr/bin/podman is the fallback
from $PATH. In those (few) cases, we haven't actually been
testing the podman we should be testing.

Solution: nuke /usr/bin/podman and podman-remote before
invoking system and unit tests. As an extra level of
paranoia, check for other podmans in $PATH - if any
exist, bail out with a fatal error.

Also: in a few cases where runner.sh invokes podman for
containerized something-something, run bin/podman instead
of podman from $PATH.

Also: fix existing dependencies on /usr/bin/podman

Signed-off-by: Ed Santiago <santiago@redhat.com>
2022-10-26 19:07:20 -06:00
Ed Santiago 4966f509bd logcollector: include aardvark-dns
(minor correction to package name)

Signed-off-by: Ed Santiago <santiago@redhat.com>
2022-10-24 06:16:33 -06:00
Urvashi Mohnani 30e66d6003 Set up minikube for k8s testing
Install and set up minikube so that we can
create a k8s cluster for testing.

Signed-off-by: Urvashi Mohnani <umohnani@redhat.com>
2022-10-18 10:51:27 -04:00
Joakim Nohlgård 02bb7c2cf3 Podman image: Set default_sysctls to empty for rootless containers
Avoids the error "Error: error preparing container xyz... for attach:
crun: open /proc/sys/net/ipv4/ping_group_range: Read-only file system:
OCI runtime error" when using `podman run --net bridge` inside rootful
Podman running without --security-opt unmask=ALL (or 'unmask=/proc/*')

Signed-off-by: Joakim Nohlgård <joakim@nohlgard.se>
2022-10-18 09:27:20 +02:00
Chris Evich bb2b47dc70
Add swagger install + allow version updates in CI
Support swagger testing and optional runtime updates similar to
the current golangci-lint tool.  This allows developers to update the
version of swagger at runtime if needed.  Otherwise new CI VM images
will pick up the prescribed version at image build-time via
`make install.tools`.

Signed-off-by: Chris Evich <cevich@redhat.com>
2022-10-14 08:18:52 -04:00
Chris Evich 62bc8e3a18
Cirrus: Fix tag & branch go checks failing
When running on a branch or tag, `req_env_vars()` will call `exit(1)`
because `$CIRRUS_PR` is empty (as expected).  The original intention was
to simply skip language checks on non-PRs.  Fix the condition to match.

Signed-off-by: Chris Evich <cevich@redhat.com>
2022-10-03 12:23:46 -04:00
OpenShift Merge Robot 226977fafb
Merge pull request #16001 from cevich/image_readme
[CI:DOCS] Add quay-description update reminder
2022-09-30 15:28:15 +02:00
Chris Evich 66747351f0
[CI:DOCS] Add quay-description update reminder
Signed-off-by: Chris Evich <cevich@redhat.com>
2022-09-29 14:32:01 -04:00
Chris Evich 0660f5b7a4
Cirrus: Combine build and code consistency tasks
It's conceivable for CI to spend a lot of time testing code which
otherwise should be rejected due to quality problems.  Previously this
was validated in a dedicated task, however a failure would still fail
the CI run.  Simplify the number of CI tasks by combining the consistency
check at the tail-end of the build task.

Signed-off-by: Chris Evich <cevich@redhat.com>
2022-09-29 13:06:01 -04:00
Chris Evich 6c8a11b746
Cirrus: Combine pre-test checks into build task
Previously, two tasks always ran first, prior to anything else.  One to
verify network and external-service connectivity.  Another to verify
certain important `.cirrus.yml` standards are met.  However, as the
total number of tasks continues to grow, the need to keep these basic
checks as dedicated prerequisites is of decreasing value/importance.
Fold these two checks into a new `pretesting_script` component of the
Fedora `build` task, on both `x86_64` and `aarch64`.

Signed-off-by: Chris Evich <cevich@redhat.com>
2022-09-29 12:59:48 -04:00
OpenShift Merge Robot b7eee0b2ce
Merge pull request #15917 from cevich/check_new_go_code
[CI:BUILD] Check new go code
2022-09-29 01:12:03 +02:00
Ed Santiago 0fb95f95d2 CI: only make install.tools when needed
Reintroduce .install.foo targets into Makefile, and invoke
only the bare-minimum ones needed for each individual CI
step in setup_environment.sh.

Also add a retry to the golangci-lint curl, in hopes of
dealing with network flakes. And remove the -f (fail)
because it produces unhelpful logs.

Reason: saw about 25% CI flakes yesterday due to the golangci-lint
fetch, something about a timeout, and this was especially frustrating
because none of the steps actually needed lint. Quick reminder:
avoid network fetches unless absolutely necessary.

Fixes: #15892

Signed-off-by: Ed Santiago <santiago@redhat.com>
2022-09-27 05:52:34 -06:00
Chris Evich 527fc409e5
Cirrus: Add golang code consistency check script
Depends on #15893

Fixes: #15913

Signed-off-by: Chris Evich <cevich@redhat.com>
2022-09-26 11:57:20 -04:00
OpenShift Merge Robot cf6136ffa5
Merge pull request #15813 from praveenkumar/podman-remote-container-file
[CI:BUILD] Contrib: Add containerfile to create podman-remote binary image
2022-09-26 16:32:30 +02:00
Praveen Kumar 8c627dfb57 Contrib: Add containerfile to create podman-remote binary image
Try to partial address #14664

Signed-off-by: Praveen Kumar <kumarpraveen.nitdgp@gmail.com>
2022-09-26 10:34:13 +05:30
Chris Evich 69ac1e36c4
Cirrus: Catch use of deprecated io/ioutil package
At the time of this commit, there's no easier way to detect this using
`golangci-lint` or the go tool (that I could find).  A future update
to the `go list` command may support detection, for now use a CI script.

Signed-off-by: Chris Evich <cevich@redhat.com>
2022-09-23 10:53:42 -04:00
Anjan Nath 23195646dc pkginstaller: use path_helper to add podman and helpers to path
path_helper(8) appends the contents of /etc/paths.d/podman-pkg to the
PATH env

[NO NEW TESTS NEEDED]

Signed-off-by: Anjan Nath <kaludios@gmail.com>
2022-09-19 12:08:01 +05:30
Jason T. Greene 744878a71c Add win-installer build/verify workflows to CI
Signed-off-by: Jason T. Greene <jason.greene@redhat.com>
2022-09-06 16:17:31 -05:00
Jason T. Greene ecb9f99b88 Add new windows installer and build
Signed-off-by: Jason T. Greene <jason.greene@redhat.com>
2022-09-06 16:12:09 -05:00
Ed Santiago 5faf4eff10 Cirrus: pick UIDs/GIDs starting at 1500, not 1000
Reason: looks like UIDs 1001, 1003, 1006 are already taken
in the CI VMs.

Fixes: #15573

Signed-off-by: Ed Santiago <santiago@redhat.com>
2022-08-31 13:47:05 -06:00
OpenShift Merge Robot 36cf6f572a
Merge pull request #15489 from ashley-cui/makepkg
[CI:DOCS] Automatically set podman version in pkginstaller
2022-08-25 16:58:17 -04:00
Ashley Cui b27bfbc71e [CI:DOCS] Automatically set podman version in pkginstaller
Allow the pkginstaller makefile target to take advantage of Podman's version binary, alleviating the need to manually set Podman's version (and inevitably forgetting to do so). This means the pkginstaller Makefile will automatically detect what version of Podman we're packaging.

Signed-off-by: Ashley Cui <acui@redhat.com>
2022-08-25 16:07:18 -04:00
SeongChan Lee 0e6a421ca6 Use tmpfiles.d specifiers instead of fixed path
Rootless Docker daemon exposes its API socket on
`$XDG_RUNTIME_DIR/docker.sock`. On tmpfiles.d, `%t` is same as
`$XDG_RUNTIME_DIR` in `--user` mode, and `/run` otherwise.
We can reuse the same config file for both mode with this change.

Signed-off-by: SeongChan Lee <foriequal@gmail.com>
2022-08-24 15:45:50 +09:00
Lokesh Mandvekar 2a6daa1e31
Cirrus: add podman_machine_aarch64
Run machine tests on every PR as label-driven machine test
triggering is currently hard to predict and debug.

Co-authored-by: Ed Santiago <santiago@redhat.com>
Co-authored-by: Miloslav Trmač <mitr@redhat.com>
Signed-off-by: Lokesh Mandvekar <lsm5@fedoraproject.org>
2022-08-17 09:11:06 -04:00
Chris Evich a6af67ca90
Cirrus: Update podman-machine comment
Replace TODO comment with helpful hint for future maintainers.

Signed-off-by: Chris Evich <cevich@redhat.com>
2022-08-15 15:48:45 -04:00
Andrew Gunnerson d7f6d355b0
podman-kube@.service.in: Remove Restart=never option with typo
systemd expects the value of the option to be `no` instead, but this is
already the default behavior. This fixes the following warning when
running `systemctl status` on the unit:

    Failed to parse service restart specifier, ignoring: never

Signed-off-by: Andrew Gunnerson <chillermillerlong@hotmail.com>
2022-08-13 18:13:03 -04:00
William Entriken f26a5246e3
Fix updated link to install instructions
Signed-off-by: William Entriken <github.com@phor.net>
2022-08-11 20:34:59 -04:00
OpenShift Merge Robot 097cc6eb6d
Merge pull request #15225 from unknowndevQwQ/update_logo
[CI:DOCS]: update the podman logo
2022-08-09 14:28:59 +00:00