Commit graph

14669 commits

Author SHA1 Message Date
OpenShift Merge Robot 3c75c4a54c
Merge pull request #13704 from baude/refactor2
Machine refactor part 2
2022-03-30 16:23:20 -04:00
OpenShift Merge Robot fbbf5e88fd
Merge pull request #13646 from Luap99/slirp4netns-portrange
fix slirp4netns port forwarding with ranges
2022-03-30 13:25:20 -04:00
OpenShift Merge Robot 688213ba19
Merge pull request #13716 from giuseppe/enable-all-controllers-service
systemd: enable all cgroups when running as a service
2022-03-30 12:09:38 -04:00
OpenShift Merge Robot 0cb93e2285
Merge pull request #13712 from Luap99/netns-scope-systemd
rootless netns: move process to scope only with systemd
2022-03-30 10:23:19 -04:00
Brent Baude a06df4fc1a Machine refactor part 2
This PR further implements a more structured approach to handling the
files needed by machine.  More files are now made as MachineFile which
can then have a symlink (using a shorter path) to them.  Also added Set
and Get methods for many of the files.

The next part of the refactor will implement the use of symlinks on
MacOS.

Signed-off-by: Brent Baude <bbaude@redhat.com>

[NO NEW TESTS NEEDED]

Signed-off-by: Brent Baude <bbaude@redhat.com>
2022-03-30 09:22:40 -05:00
Giuseppe Scrivano 81632722ea
systemd: enable all cgroups when running as a service
enable cgroup delegation when running as a systemd service so all the
available controllers are correctly detected.

Closes: https://github.com/containers/podman/issues/13710

Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
2022-03-30 15:49:06 +02:00
OpenShift Merge Robot ff8834f023
Merge pull request #13705 from jwmatthews/issue13690
Add 'Os' to be queried via 'version' output
2022-03-30 07:51:04 -04:00
Paul Holzinger 1f1cf7bd40
rootless netns: move process to scope only with systemd
When you run podman on a non systemd system we should not try to move the
process under a new systemd scope.

[NO NEW TESTS NEEDED]

Ref #13703

Signed-off-by: Paul Holzinger <pholzing@redhat.com>
2022-03-30 13:02:41 +02:00
OpenShift Merge Robot d0d805ba1b
Merge pull request #13478 from cevich/build_push
Cirrus: Build multi-arch images + manifests
2022-03-29 21:05:23 -04:00
John Matthews 1ffcc4a888 Add 'Os' to be queried via 'version' output
Signed-off-by: John Matthews <jwmatthews@gmail.com>
2022-03-29 18:10:59 -04:00
OpenShift Merge Robot c319edaaf8
Merge pull request #13693 from edsantiago/show_size
size-check: display binary size and growth
2022-03-29 14:48:02 -04:00
Paul Holzinger eedaaf33cd
fix slirp4netns port forwarding with ranges
The slirp4netns port forwarder was not updated to make use of the new
port format. This results in a problem when port ranges are used since
it does not read the range field from the port.

Update the logic to iterate through all ports with the range and
protocols. Also added a system test for port ranges with slirp4netns,
rootlesskit and the bridge network mode.

Fixes #13643

Signed-off-by: Paul Holzinger <pholzing@redhat.com>
2022-03-29 19:18:40 +02:00
OpenShift Merge Robot 3990f9c51e
Merge pull request #13692 from Luap99/upgrade-test
upgrade tests: fix networking problems
2022-03-29 18:32:03 +02:00
Ed Santiago c602084a5c size-check: display binary size and growth
This won't actually be seen except by someone who takes the
time to clickety-click into Cirrus - but that's better than
not showing it at all.

Signed-off-by: Ed Santiago <santiago@redhat.com>
2022-03-29 08:56:19 -06:00
Paul Holzinger 61c518627d
upgrade tests: fix networking problems
With podman4 we support netavark, however old versions will still use
cni. Since netavark and cni can conflict we should not mix them.
Remove the network setup from the inital podman command and create the
directories manually to prevent such conflicts.

Also the update to 4.0 changes the network db structure. While it is
compatible from 3.X to 4.0 it will fail the other way around. In this
test it will happen because the cleanup process still uses the old
podman while the network connect/disconnect test already changed the db
format. Therefore the cleanup process cannot see any networks and will
not tear it down. The following start will fail because the ip address
is already assigned.

Fixes #13679

Signed-off-by: Paul Holzinger <pholzing@redhat.com>
2022-03-29 16:42:50 +02:00
OpenShift Merge Robot 0eff4b70d0
Merge pull request #13686 from vrothberg/nxadm
replace hpcloud/tail with nxadm/tail
2022-03-29 16:41:47 +02:00
OpenShift Merge Robot 83d0729146
Merge pull request #13619 from rhatdan/systemd
Set systemd mode if entrypoint begins with /bin/sh -c
2022-03-29 14:45:46 +02:00
Valentin Rothberg 21502987b2 replace hpcloud/tail with nxadm/tail
The hpcloud is not maintained anymore.  nxadm is already part of the
dependency chain, so it won't add work for downstream packages.

While testing upcoming changes to the events-file backend, I noticed
that nxadm is shipping required fixes.

[NO NEW TESTS NEEDED]

Signed-off-by: Valentin Rothberg <vrothberg@redhat.com>
2022-03-29 13:35:37 +02:00
OpenShift Merge Robot 784ec5d251
Merge pull request #13681 from baude/qmpmonitorfix
Migrate machine configs
2022-03-29 13:13:46 +02:00
OpenShift Merge Robot a2d7fb0c66
Merge pull request #13682 from patrycja-guzik/docu2
[CI:DOCS]  Unify examples section across several man pages
2022-03-29 08:33:45 +02:00
Chris Evich f6963cea13
Cirrus: Build multi-arch images + manifests
Github-actions for large/complex tasks is hard to read and maintain.
Reimplement the multi-arch image build workflow into a set of bash
scripts that use all native contrainer-org tooling.  This requires
a special VM image setup with emulation to build foreign architectures.
It also requires renaming the `helloimage` directory, because the build
script uses the directory name in the image FQIN.

Signed-off-by: Chris Evich <cevich@redhat.com>
2022-03-28 16:56:28 -04:00
OpenShift Merge Robot 914e9b3f70
Merge pull request #13564 from naveensrinivasan/naveen/feat/pin-actions
[CI:DOCS] Pin actions to a full length commit SHA
2022-03-28 22:44:12 +02:00
Daniel J Walsh cdf74f2082
Set systemd mode if entrypoint begins with /bin/sh -c
Fixes: https://github.com/containers/podman/issues/13324

Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
2022-03-28 16:30:47 -04:00
Patrycja Guzik a8e6c639e2 Unify examples section across several man pages
This commit adjusts example sections across several man pages
to the format seen in other pages.

Signed-off-by: Patrycja Guzik <patrycja.k.guzik@gmail.com>
2022-03-28 21:56:13 +02:00
Brent Baude 6e0e1cbddd Migrate machine configs
If podman detects a Machinev1 config, it will automatically migrate it
to the new format.

Signed-off-by: Brent Baude <bbaude@redhat.com>

[NO NEW TESTS NEEDED]
2022-03-28 14:54:19 -05:00
OpenShift Merge Robot c75030590c
Merge pull request #13565 from naveensrinivasan/naveen/feat/dependabot-update
Updated dependabot to GitHub actions
2022-03-28 21:41:54 +02:00
naveensrinivasan 1821eb3837 Pin actions to a full length commit SHA
- Pinned actions by SHA https://github.com/ossf/scorecard/blob/main/docs/checks.md#pinned-dependencies
- Included permissions for the action. https://github.com/ossf/scorecard/blob/main/docs/checks.md#token-permissions

>Pin actions to a full length commit SHA

>Pinning an action to a full length commit SHA is currently the only way to use an action as an immutable release. Pinning to a particular SHA helps mitigate the risk of a bad actor adding a backdoor to the action's repository, as they would need to generate a SHA-1 collision for a valid Git object payload.

https://docs.github.com/en/actions/security-guides/security-hardening-for-github-actions#using-third-party-actions

Also dependabot supports upgrades based on SHA.

Signed-off-by: naveensrinivasan <172697+naveensrinivasan@users.noreply.github.com>
2022-03-28 19:00:16 +00:00
OpenShift Merge Robot 9cfa9695a0
Merge pull request #13674 from baude/refactor1
Machine refactor - part 1
2022-03-28 18:14:23 +02:00
Brent Baude 2ac897aa0d Machine refactor - part 1
the way machine was written was very adjunct and as such is in dire need
of refactoring to better structures and structure methods where
appropriate.  the weekest part is specifically around all the files that
machine requires and how some are just dynamically built on the fly.

this pr defines a new machinefile type which allows us to work with the
file and also takes into account the use of symlinks which are going to
be needed on macos due to its relatively short file length restriction.

also, added unit tests for new methods as well as anywhere else I saw a
need.

Signed-off-by: Brent Baude <bbaude@redhat.com>
2022-03-28 09:12:08 -05:00
OpenShift Merge Robot b76d717bbf
Merge pull request #13640 from Luap99/slirp4netns-fail
network setup: fail if slirp4netns is not installed
2022-03-28 15:51:51 +02:00
OpenShift Merge Robot 54f808e4dd
Merge pull request #13651 from jwmatthews/fix13650
Fixes errors from 'manifest push' being dropped in remote case
2022-03-28 15:37:50 +02:00
OpenShift Merge Robot ffe87c0bdf
Merge pull request #13677 from flouthoc/rename-event
libpod, event: generate a valid event on container `rename` operation
2022-03-28 15:15:51 +02:00
OpenShift Merge Robot e1699d8591
Merge pull request #13668 from rhatdan/walk
Switch all calls to filepath.Walk to filepath.WalkDir
2022-03-28 15:14:19 +02:00
OpenShift Merge Robot aeae598049
Merge pull request #13592 from containers/dependabot/go_modules/google.golang.org/protobuf-1.28.0
build(deps): bump google.golang.org/protobuf from 1.27.1 to 1.28.0
2022-03-28 15:09:51 +02:00
Daniel J Walsh 7df6849f16
Merge pull request #13648 from adamaze/main
[CI:DOCS] clarifying "loginctl enable-linger" section in doc
2022-03-28 09:08:00 -04:00
Paul Holzinger 38bd4010cf
network setup: fail if slirp4netns is not installed
I do not see why we should only log an error. If slirp4netns is
requested but not installed we should error.

[NO NEW TESTS NEEDED]

Signed-off-by: Paul Holzinger <pholzing@redhat.com>
2022-03-28 12:49:55 +02:00
Aditya R 82ed99b6af
event: generate a valid event on container rename operation
Following commit ensures that podman generates a valid event on `podman
container rename` where event specifies that it is a rename event and
container name swtichted to the latest name.

Signed-off-by: Aditya R <arajan@redhat.com>
2022-03-28 15:07:02 +05:30
OpenShift Merge Robot 0ebf0bc560
Merge pull request #13611 from rvandernoort/vendor_filters
Vendor c/common for filters
2022-03-28 00:49:28 +02:00
John Matthews 7989880509 Fixes errors from 'manifest push' being dropped in remote case
Signed-off-by: John Matthews <jwmatthews@gmail.com>
2022-03-27 07:33:13 -04:00
Daniel J Walsh d106b294b4
Switch all calls to filepath.Walk to filepath.WalkDir
WalkDir should be faster the Walk, since we often do
not need to stat files.

[NO NEW TESTS NEEDED] Existing tests should find errors.

Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
2022-03-27 07:18:25 -04:00
OpenShift Merge Robot 463c0b9f2d
Merge pull request #13607 from rvandernoort/filter_docs
[CI:DOCS]: Update docs for image filters
2022-03-27 13:17:31 +02:00
OpenShift Merge Robot 56b2937f87
Merge pull request #13653 from jmontleon/fix-manifest-push-header
Resolves #13629 Add RegistryAuthHeader to manifest push
2022-03-27 13:13:42 +02:00
OpenShift Merge Robot ddfa087d00
Merge pull request #13660 from rhatdan/error
Remove error stutter
2022-03-27 13:11:31 +02:00
Daniel J Walsh 28504f5dd4
Merge pull request #13639 from containers/dependabot/go_modules/github.com/docker/docker-20.10.14incompatible
build(deps): bump github.com/docker/docker from 20.10.13+incompatible to 20.10.14+incompatible
2022-03-27 07:10:09 -04:00
rvandernoort 446c35efdf Vendor common
Added patch provided by rhatdan to add support for shareable

[NO NEW TESTS NEEDED]

Signed-off-by: rvandernoort <s.r.vandernoort@student.tudelft.nl>
2022-03-27 13:01:52 +02:00
rvandernoort ab41037c87 Update filter docs with missing entries and add negation option.
[NO NEW TESTS NEEDED]

Signed-off-by: rvandernoort <s.r.vandernoort@student.tudelft.nl>
2022-03-27 12:59:22 +02:00
jason 3cc1739373 Resolves #13629 Add RegistryAuthHeader to manifest push
Signed-off-by: Jason Montleon <jmontleo@redhat.com>
2022-03-26 16:39:11 -04:00
OpenShift Merge Robot 730f1db4da
Merge pull request #13659 from rhatdan/codespell
Run codespell to cleanup typos
2022-03-26 10:24:44 +01:00
Daniel J Walsh 7680211ede
Remove error stutter
When podman gets an error it prints out "Error: " before
printing the error string.  If the error message starts with
error, we end up with

Error: error ...

This PR Removes all of these stutters.

logrus.Error() also prints out that this is an error, so no need for the
error stutter.

[NO NEW TESTS NEEDED]

Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
2022-03-25 21:47:04 -04:00
dependabot[bot] 76614c4613
build(deps): bump google.golang.org/protobuf from 1.27.1 to 1.28.0
Bumps [google.golang.org/protobuf](https://github.com/protocolbuffers/protobuf-go) from 1.27.1 to 1.28.0.
- [Release notes](https://github.com/protocolbuffers/protobuf-go/releases)
- [Changelog](https://github.com/protocolbuffers/protobuf-go/blob/master/release.bash)
- [Commits](https://github.com/protocolbuffers/protobuf-go/compare/v1.27.1...v1.28.0)

---
updated-dependencies:
- dependency-name: google.golang.org/protobuf
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2022-03-25 20:00:23 +00:00