14063 Commits

Author SHA1 Message Date
ca62a39985 Merge pull request #12950 from edsantiago/systemd_250
System tests: fix for new systemd on rawhide
2022-01-20 15:01:29 -05:00
47df14af52 System tests: fix for new systemd on rawhide
systemd 250 on f36 has changed the output format of a message
our tests rely on. This breaks bodhi gating tests. Fix test
so it accepts a continually-growing set of systemd outputs.

Signed-off-by: Ed Santiago <santiago@redhat.com>
2022-01-20 11:28:41 -07:00
00a12a0b83 Merge pull request #12871 from jwhonce/issues/12866
Engine.Remote from containers.conf
2022-01-20 13:17:31 -05:00
76ba0df602 Merge pull request #12945 from vrothberg/vendor-psgo
vendor c/psgo@v1.7.2
2022-01-20 12:29:32 -05:00
e22b9889d6 vendor c/psgo@v1.7.2
Signed-off-by: Valentin Rothberg <rothberg@redhat.com>
2022-01-20 16:56:20 +01:00
1f85244abe Engine.Remote from containers.conf
Heuristic to initialize TunnelMode/remote podman:
- Podman built with remote tag
- Podman running on darwin or windows GOOS
- CONTAINER_HOST or CONTAINER_CONNECTION set in environment
- --remote flag given on command line
- From containers.conf, Engine.Remote == true and GOOS == linux

Otherwise, podman will run in ABIMode/linked against libpod library.

Fixes #12866

Signed-off-by: Jhon Honce <jhonce@redhat.com>
2022-01-20 08:51:34 -07:00
206e57e5b0 Merge pull request #12928 from n1hility/win-env
Implement env parsing on Windows
2022-01-20 09:33:30 -05:00
1d6e154a73 Merge pull request #12939 from flouthoc/vendor-common
vendor: bump `c/common` for netavark and other pkgs as well.
2022-01-20 04:53:27 -05:00
2c492be00a vendor: bump c/common and other vendors
This commit bumps majorly c/common so netavark features could be synced
with podman.

But there are some other vendor bumps as well

[NO NEW TESTS NEEDED]
[NO TESTS NEEDED]

Signed-off-by: Aditya R <arajan@redhat.com>
2022-01-20 12:40:11 +05:30
f46478c1e9 Merge pull request #12931 from giuseppe/fix-crash-with-bazel-linux-sandbox
rootless: report correctly the error
2022-01-20 00:57:26 -05:00
7fc8bf4a42 Merge pull request #12887 from esendjer/main
Add custom defined dependencies to podman generate systemd
2022-01-19 20:29:01 -05:00
6b59b10248 Merge pull request #12916 from n1hility/winproxy
Implement API forwarding for podman machine on Windows
2022-01-19 17:41:03 -05:00
d2c892c729 Merge pull request #12914 from rhatdan/commit
Handle changes in docker compat mode
2022-01-19 17:19:00 -05:00
7046e78040 rootless: report correctly the error
`err` is nil at this point, so errors.Wrapf() would return nil
ignoring the remaining arguments.  This would prevent SetupRootless()
to fail causing podman to run without capabilities but believing so,
and it would end up in a crash when accessing the local store.

Closes: https://github.com/containers/podman/discussions/12923

[NO NEW TESTS NEEDED] it requires running in the environment created
by bazel linux-sandbox.

Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
2022-01-19 21:14:33 +01:00
2d0b5ebb5b Implement API forwarding for podman machine on Windows
Signed-off-by: Jason T. Greene <jason.greene@redhat.com>
2022-01-19 13:03:49 -06:00
5e2fcf813d Merge pull request #12925 from edsantiago/apiv2_logs
APIv2 tests: followup to recent log test
2022-01-19 13:05:05 -05:00
4693fc6db1 Implement env parsing on Windows
Fixes #12056
Also, enables existing parsing logic for all Unix derived OSs

Signed-off-by: Jason T. Greene <jason.greene@redhat.com>
2022-01-19 12:05:04 -06:00
c674d3cc75 Handle changes in docker compat mode
Fixes: https://github.com/containers/podman/issues/12830

Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
2022-01-19 13:03:58 -05:00
b9a2d8698a Handlers for generate systemd with custom dependencies
This commit includes:
* Handlers for generate systemd unit
  with manually defined dependencies such as:
  Wants=, After= and Requires=

* The new unit and e2e tests for checking generated systemd units
  for container and pod with custom dependencies

* Documented descriptions for custom dependencies options

Signed-off-by: Eugene (Evgenii) Shubin <esendjer@gmail.com>
2022-01-19 21:46:16 +05:00
abcd292396 APIv2 tests: followup to recent log test
Followup to #12919, which merged while I was writing
review feedback. This actually confirms log output.
This required a minor change to the 't' helper: stripping
NUL chars from the http result.

And, while I'm at it, a bunch of cleanup for running rootless:
- set $CONTAINERS_HELPER_BINARY_DIR, so we can find rootlessport
- add a few conditionals for different expectations

Signed-off-by: Ed Santiago <santiago@redhat.com>
2022-01-19 09:13:22 -07:00
1c81b67341 Merge pull request #12921 from containers/dependabot/go_modules/github.com/opencontainers/runc-1.1.0
Bump github.com/opencontainers/runc from 1.0.3 to 1.1.0
2022-01-19 10:01:02 -05:00
8301a7cd82 Merge pull request #12862 from matejvasek/fix-info-ep
Add IndexConfigs info to compat /info endpoint
2022-01-19 09:29:05 -05:00
b63e716ffc Merge pull request #12915 from kolyshkin/patch-1
[CI:DOCS] SECURITY.md: fix the project name
2022-01-19 08:59:00 -05:00
fa27734b76 Merge pull request #12919 from vrothberg/fix-12904
apiv2 test: add regression test for #12904
2022-01-19 08:55:03 -05:00
4b384e08a9 Add IndexConfigs to compat /info endpoint
Signed-off-by: Matej Vasek <mvasek@redhat.com>
2022-01-19 13:46:32 +01:00
a0165a64b9 Bump github.com/opencontainers/runc from 1.0.3 to 1.1.0
Bumps [github.com/opencontainers/runc](https://github.com/opencontainers/runc) from 1.0.3 to 1.1.0.
- [Release notes](https://github.com/opencontainers/runc/releases)
- [Changelog](https://github.com/opencontainers/runc/blob/master/CHANGELOG.md)
- [Commits](https://github.com/opencontainers/runc/compare/v1.0.3...v1.1.0)

---
updated-dependencies:
- dependency-name: github.com/opencontainers/runc
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2022-01-19 12:09:54 +00:00
af6a43fa49 apiv2 test: add regression test for #12904
Add a regression test for issue #12904 to make sure that attaching with
logs=true to the compact endpoint does not blow up.  Note that I did not
find a way to test the output (i.e., '123'); logs are sent in a binary
format and I did not find a way to compare the control characters.

Signed-off-by: Valentin Rothberg <rothberg@redhat.com>
2022-01-19 09:33:34 +01:00
4d1c327edf SECURITY.md: fix the project name
Signed-off-by: Kir Kolyshkin <kolyshkin@gmail.com>
2022-01-18 17:06:42 -08:00
094b11cbcb Merge pull request #12908 from Luap99/network-conf-dir
rename --cni-config-dir to --network-config-dir
2022-01-18 15:42:06 -05:00
c0e0723463 rename --cni-config-dir to --network-config-dir
Since this option will also be used for netavark we should rename it to
something more generic. It is important that --cni-config-dir still
works otherwise we could break existing container cleanup commands.

Signed-off-by: Paul Holzinger <pholzing@redhat.com>
2022-01-18 19:28:25 +01:00
62212dbf49 Merge pull request #12909 from vrothberg/fix-12904
compat attach: fix write on closed channel
2022-01-18 13:20:10 -05:00
094665ac0c Merge pull request #12894 from Luap99/deps
upgrade all dependencies
2022-01-18 12:08:08 -05:00
7e30531f20 compat attach: fix write on closed channel
Waiting on an initialized sync.WaitGroup returns immediately.
Hence, move the goroutine to wait and close *after* reading
the logs.

Fixes: #12904
Signed-off-by: Valentin Rothberg <rothberg@redhat.com>
2022-01-18 16:32:38 +01:00
0bbf8fa140 Merge pull request #12797 from edsantiago/test_image_scp_sudo
Tests for podman image scp (the sudo form)
2022-01-18 10:30:08 -05:00
774271c38a upgrade all dependencies
The dependabot does not update dependencies when they do not use a tag.
This patch upgrades all untagged depenencies if possible.

You can upgrade all dependencies with `go get -u ./... && make vendor`
in theory however this failed since the k8s changes do not compile on
go v1.16 so I only updated the other dependencies.

Signed-off-by: Paul Holzinger <pholzing@redhat.com>
2022-01-18 16:27:00 +01:00
55ad6188b0 Merge pull request #12900 from containers/dependabot/go_modules/github.com/opencontainers/runc-1.1.0
Bump github.com/opencontainers/runc from 1.0.3 to 1.1.0
2022-01-18 10:04:10 -05:00
59b1cdf9bb Merge pull request #12905 from cevich/re-enable_osx
[CI:DOCS] Restore OSX cross-build task
2022-01-18 09:44:09 -05:00
38fbc8af18 Revert "Cirrus: Temporarily disable OSX Cross task"
This reverts commit 860463d97eb3a006f2c608165d9e657be86080ec.

Signed-off-by: Chris Evich <cevich@redhat.com>
2022-01-18 09:12:09 -05:00
29d7ab3f82 Merge pull request #12897 from vrothberg/bump-module
bump go module to version 4
2022-01-18 08:40:06 -05:00
4adf457ff3 Bump github.com/opencontainers/runc from 1.0.3 to 1.1.0
Bumps [github.com/opencontainers/runc](https://github.com/opencontainers/runc) from 1.0.3 to 1.1.0.
- [Release notes](https://github.com/opencontainers/runc/releases)
- [Changelog](https://github.com/opencontainers/runc/blob/master/CHANGELOG.md)
- [Commits](https://github.com/opencontainers/runc/compare/v1.0.3...v1.1.0)

---
updated-dependencies:
- dependency-name: github.com/opencontainers/runc
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2022-01-18 12:08:58 +00:00
bd09b7aa79 bump go module to version 4
Automated for .go files via gomove [1]:
`gomove github.com/containers/podman/v3 github.com/containers/podman/v4`

Remaining files via vgrep [2]:
`vgrep github.com/containers/podman/v3`

[1] https://github.com/KSubedi/gomove
[2] https://github.com/vrothberg/vgrep

Signed-off-by: Valentin Rothberg <rothberg@redhat.com>
2022-01-18 12:47:07 +01:00
d6b0720b9c Merge pull request #12684 from mheon/remap_states
Revamp Libpod state strings for Docker compat
2022-01-18 06:22:05 -05:00
d0eb24bae0 Merge pull request #12870 from rhatdan/userns1
Use PODMAN_USERNS environment variable when running as a service
2022-01-18 06:08:06 -05:00
02502e2c14 Merge pull request #12891 from lsm5/copr-fix-2
[NO NEW TESTS NEEDED] add builddeps to copr template
2022-01-17 21:36:07 -05:00
f23e8ca672 [NO NEW TESTS NEEDED] add builddeps to copr template
Signed-off-by: Lokesh Mandvekar <lsm5@fedoraproject.org>
2022-01-17 17:06:40 -05:00
471a4356bf CI: rootless user: also create in some root tests
viz, rootful system tests. The rootless account will be
used by image-scp tests.

Unfortunately, having ssh available means the system-connection
tests will start running, which is very bad because they will
fail, because system connection doesn't actually work (long story).
Add a few more checks to prevent this test from running.

Signed-off-by: Ed Santiago <santiago@redhat.com>
2022-01-17 14:40:30 -07:00
c8124b88ae [WIP] Tests for podman image scp (the sudo form)
Start inching our way back to having tests for the sudo form
of podman image scp. Basically, copy an image to another user
and then back, using a pseudorandom name. Confirm that the
image makes it to the remote end, and that when we copy it
back, the original image digest is preserved.

When scp'ing as root, we identify the destination rootless
user account via the $PODMAN_ROOTLESS_USER envariable. Setting
this and creating the account is left as an exercise for the
CI framework (be it github, or Fedora/CentOS/RHEL gating, or
other).

Also: amend hack/bats to set and relay $PODMAN_ROOTLESS_USER,
so developers can test locally.

Also: remove what I'm 99% sure is a debugging printf.

Signed-off-by: Ed Santiago <santiago@redhat.com>
2022-01-17 14:40:30 -07:00
b59c30f729 Merge pull request #12893 from cevich/tmp_dis_osx
[CI:DOCS] Cirrus: Temporarily disable OSX Cross task
2022-01-17 16:40:11 -05:00
d7492f1514 Merge pull request #12892 from Luap99/common
update c/common to latest
2022-01-17 15:27:43 -05:00
141de86862 Revamp Libpod state strings for Docker compat
Improve our compatibility with Docker by better handling the
state strings that we print in `podman ps`. Docker capitalizes
all states in `ps` (we do not) - fix this in our PS code. Also,
stop normalizing ContainerStateConfigured to the "Created" state,
and instead make it always be Created, with the existing Created
state becoming Initialized.

I didn't rename the actual states because I'm somewhat reticent
to make such a large change a day before we leave for break. It's
somewhat confusing that ContainerStateConfigured now returns
Created, but internally and externally we're still consistent.

[NO NEW TESTS NEEDED] existing tests should catch anything that
broke.

I also consider this a breaking change. I will flag appropriately
on Github.

Fixes RHBZ#2010432 and RHBZ#2032561

Signed-off-by: Matthew Heon <mheon@redhat.com>
2022-01-17 13:56:07 -05:00