17984 Commits

Author SHA1 Message Date
c0f983db87 Don't set hostPort when generating a service
When generating a kube yaml with kube generate, do not
set the hostPort in the pod spec if the service flag is
set and we are generating a service kind too.

Signed-off-by: Urvashi Mohnani <umohnani@redhat.com>
2023-02-14 11:00:28 -05:00
1e06c1a47a Merge pull request #17379 from umohnani8/ulimit
Add ulimit annotation to kube gen & play
2023-02-13 21:59:49 -05:00
26ed4f3447 Merge pull request #17488 from containers/dependabot/go_modules/test/tools/golang.org/x/tools-0.6.0
build(deps): bump golang.org/x/tools from 0.5.0 to 0.6.0 in /test/tools
2023-02-13 16:21:45 -05:00
4debbd108b Merge pull request #17487 from vrothberg/quadlet-stop
quadlet: add ExecStop
2023-02-13 13:45:40 -05:00
72addc46c3 Merge pull request #17424 from salevdns/patch-2
[CI:DOCS] Clarify nomap constrains
2023-02-13 13:11:59 -05:00
2df33a5036 Merge pull request #17486 from edsantiago/xref_manpage_link_names
[CI:DOCS] man page xref: validate displayed man page names
2023-02-13 13:09:25 -05:00
aab06f5724 Merge pull request #17489 from vrothberg/fix-16091
install sigproxy before start/attach
2023-02-13 13:06:50 -05:00
35d16ea027 Add ulimit annotation to kube gen & play
Add a podman ulimit annotation to kube generate and play.
If a container has a container with ulimits set, kube gen
will add those as an annotation to the generated yaml.
If kube play encounters the ulimit annotation, it will set
ulimits for the container being played.

Signed-off-by: Urvashi Mohnani <umohnani@redhat.com>
2023-02-13 11:38:24 -05:00
34d412e13d man page xref: validate displayed man page names
command tables are chock full of duplication, hence they break.
Look for inconsistencies between the displayed man page name
and the actual man page name:

    |  foo    | [podman-foo(1)](podman-cmd-foo.1.md) | ...
                        ^^^

Inspired by #17474.

We can't actually check the subcommand name (the plain "foo")
because there are many existing subcommands whose name does
not match the man page: rmi vs image-rm, list vs podman-ps.

Signed-off-by: Ed Santiago <santiago@redhat.com>
2023-02-13 07:54:57 -07:00
86da741d89 Merge pull request #17474 from eriksjolund/run_typos
run "typos --write-changes"
2023-02-13 09:51:05 -05:00
7c54d14232 quadlet: add ExecStop
Remove the container in ExecStop to make sure that Quadlet's adheres to
Podman's customizable stop signal/timeout.  Certain programs ignore
SIGTERM which renders the services generated by Quadlet less user
friendly compared to the ones from podman-generate-systemd.

Previously, `systemctl stop` would just hang until systemd's stop
timeout is hit.  Since `podman rm` also removes the CID file, the
additional `rm` can be removed.  Note that `podman rm` will return
immediately if the specified CID file isn't present.

I am working on a short tutorial on Quadlet and hit the issue with a
simple container running `sleep`.  `sleep` ignores SIGTERM and stopping
the service would take forever even with `PodmanArgs=--stop-timeout=0`.

Signed-off-by: Valentin Rothberg <vrothberg@redhat.com>
2023-02-13 15:21:48 +01:00
d2ac85f7aa install sigproxy before start/attach
Install the signal proxy before attaching to/starting the container to
make sure there's no race-condition as revealed in the failing start/run
tests in #16901.  The tests had the valid expectation that signal
forwarding works once the container is running.

Further update the tests to account for the attach test where the
expectation is that signal forwarding works once Podman has attached to
container (or even before).

Fixes: #16901
Signed-off-by: Valentin Rothberg <vrothberg@redhat.com>
Signed-off-by: Ed Santiago <santiago@redhat.com>
2023-02-13 15:13:42 +01:00
191e4ce40c build(deps): bump golang.org/x/tools from 0.5.0 to 0.6.0 in /test/tools
Bumps [golang.org/x/tools](https://github.com/golang/tools) from 0.5.0 to 0.6.0.
- [Release notes](https://github.com/golang/tools/releases)
- [Commits](https://github.com/golang/tools/compare/v0.5.0...v0.6.0)

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

Signed-off-by: dependabot[bot] <support@github.com>
2023-02-13 13:07:08 +00:00
a5ca732256 Fix typos
Software version used
https://github.com/crate-ci/typos/releases/tag/v1.13.10

The binary was downloaded from
https://github.com/crate-ci/typos/releases/download/v1.13.10/typos-v1.13.10-x86_64-unknown-linux-musl.tar.gz

Command that was run:

typos --write-changes docs cmd cni contrib dependencies docs hack libpod pkg utils

False positives were manually removed.
A few marshaling/existant typos were manually fixed.

Signed-off-by: Erik Sjölund <erik.sjolund@gmail.com>
2023-02-11 18:23:24 +01:00
f099c1fc9a Merge pull request #17469 from vrothberg/fix-17345
kube play: set service container as main PID when possible
2023-02-10 09:09:47 -05:00
1541ce56cf kube play: set service container as main PID when possible
Commit 4fa307f14923 fixed a number of issues in the sdnotify proxies.
Whenever a container runs with a custom sdnotify policy, the proxies
need to keep running which in turn required Podman to run and wait for
the service container to stop.  Improve on that behavior and set the
service container as the main PID (instead of Podman) when no container
needs sdnotify.

Fixes: #17345
Signed-off-by: Valentin Rothberg <vrothberg@redhat.com>
2023-02-10 13:31:03 +01:00
15caef98f3 Merge pull request #17459 from eriksjolund/fix_spelling_typos_and_language
Fix typos. Improve language.
2023-02-09 20:07:34 -05:00
08e13867a9 Fix typos. Improve language.
Signed-off-by: Erik Sjölund <erik.sjolund@gmail.com>
2023-02-09 21:56:27 +01:00
f0d863e5cc Merge pull request #17443 from edsantiago/xref_format_baby_steps
[CI:DOCS] man-page checker: include --format (Go templates)
2023-02-09 14:23:34 -05:00
d5e1e278a3 Merge pull request #17221 from mtrmac/eof-range-requests
Vendor c/image after https://github.com/containers/image/pull/1816
2023-02-09 14:02:28 -05:00
9eaf965a21 Merge pull request #17449 from rhatdan/codespell
Run codespell on codebase
2023-02-09 13:59:35 -05:00
d8de65bb8b Merge pull request #17412 from umohnani8/alias
Add ctrName to network alias during kube play
2023-02-09 13:56:19 -05:00
a272dd4a84 Merge pull request #17451 from edsantiago/events_test_rhel8
events + container inspect test: RHEL fixes
2023-02-09 11:33:16 -05:00
9cba0474b5 events + container inspect test: RHEL fixes
Primarily, add skip_if_journald_unavailable because RHEL.

Secondarily, reverse a flipped actual/expect assertion
that made it difficult to understand the RHEL failure.

Signed-off-by: Ed Santiago <santiago@redhat.com>
2023-02-09 06:49:32 -07:00
5a9074dabb Add ctrName to network alias during kube play
We currently name the container being created during kube play
as ctrName-podName, but this is not how it is done in k8s.
Since we can't change this at the CLI level as it will be a breaking
change (it will be planned for podman 5.0), add only ctrName as an alias
to the network of the pod.

Signed-off-by: Urvashi Mohnani <umohnani@redhat.com>
2023-02-09 08:25:13 -05:00
5865159766 Run codespell on codebase
Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
2023-02-09 08:02:43 -05:00
09e853b14d Merge pull request #17409 from EvaristeGalois11/fix-doc-podman-commit
[CI:DOCS] Fix contradicting documentation podman commit --pause
2023-02-09 07:54:49 -05:00
7f2b4234c7 Merge pull request #17440 from rhatdan/man
[CI:DOCS] Cleanup some man pages to display options with line breaks
2023-02-09 04:38:42 -05:00
fb54be2e17 [CI:DOCS] Clarify nomap constrains
Signed-off-by: salevdns <24809481+salevdns@users.noreply.github.com>
2023-02-09 10:35:43 +01:00
4334135491 [CI:DOCS] man-page checker: include --format (Go templates)
Very belated successor to #14046.

I don't know why this is so important to me. Probably because we're
doing a halfhearted sloppy job of documenting, and new options get
added, and not documented, and that's just wrong.

I've given up on documenting internal structs. This iteration
has a $Format_Exceptions table defined at the top of the xref
script, enumerating a hardcoded defined set of podman commands
and fields that should remain undocumented.

This iteration also forgives completely-undocumented formats.
If podman-foo has a --format, but podman-foo.1.md does not
list *any* valid fields, the script warns but does not fail.
This at least is better than documenting a random mix of fields.

This version of the xref script is much slower: 10s vs 4. I
think we can live with that in a CI-only script.

Signed-off-by: Ed Santiago <santiago@redhat.com>
2023-02-08 15:33:45 -07:00
e308ba0215 Vendor c/image after https://github.com/containers/image/pull/1816
Also includes unreleased https://github.com/openshift/imagebuilder/pull/246 to work
with the updated docker/docker dependency.

And updates some references to newly deprecated docker/docker symbols.

[NO NEW TESTS NEEDED]

Signed-off-by: Miloslav Trmač <mitr@redhat.com>
2023-02-08 22:37:38 +01:00
d1fd399455 Merge pull request #17438 from rhatdan/quadlet
[CI:DOCS] Add tables to podman-systemd.unit man page
2023-02-08 15:54:28 -05:00
34e76a46ab Merge pull request #17423 from ygalblum/quadlet_container_secret
Quadlet: Add support for the Secret key in Container group
2023-02-08 15:45:41 -05:00
83f2f840e4 Merge pull request #17437 from Luap99/issue-title
[CI:DOCS] github: remove prefix from bugs/features
2023-02-08 15:19:46 -05:00
ec4ab08c8b [CI:DOCS] Cleanup some man pages to display options with line breaks
Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
2023-02-08 14:46:44 -05:00
5ed2174097 [CI:DOCS] Add tables to podman-systemd.unit man page
Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
2023-02-08 14:19:32 -05:00
3de409ad6a github: remove prefix from bugs/features
We already label the issue anyway and this results in reports without
an actual title so remove it. This leaves more space for an actual
useful title.

ref: https://github.com/containers/podman/discussions/17431

Signed-off-by: Paul Holzinger <pholzing@redhat.com>
2023-02-08 18:20:12 +01:00
84c4281c8d Merge pull request #17427 from vrothberg/owners
[CI:DOCS] OWNERS: add @ygalblum and @alexlarsson
2023-02-08 09:40:45 -05:00
3ce53ba2c3 Merge pull request #17425 from containers/dependabot/go_modules/github.com/vbauerster/mpb/v8-8.1.6
build(deps): bump github.com/vbauerster/mpb/v8 from 8.1.4 to 8.1.6
2023-02-08 09:37:53 -05:00
bd40dbc553 Merge pull request #17420 from vrothberg/fix-kube-start
kube play: do not teardown unconditionally on error
2023-02-08 09:29:26 -05:00
82af4dd531 Merge pull request #17380 from sbrivio-rh/pasta
tests: pasta: Mitigation for socat connect() getting EINTR and two other fixes
2023-02-08 09:24:17 -05:00
c5bfacdf9d Merge pull request #17027 from n8henrie/issue_17026
Resolve symlink path for qemu directory if possible
2023-02-08 09:16:31 -05:00
d6dd17fdfe Quadlet: Add support for the Secret key in Container group
Add E2E tests
Add system test
Add to man page

Signed-off-by: Ygal Blum <ygal.blum@gmail.com>
2023-02-08 16:12:08 +02:00
c5f83f2280 Merge pull request #17426 from containers/dependabot/go_modules/golang.org/x/term-0.5.0
build(deps): bump golang.org/x/term from 0.4.0 to 0.5.0
2023-02-08 08:57:29 -05:00
b29aa1603e Merge pull request #17417 from rhatdan/rootfs
Sort quadlet keys to make it easier to read
2023-02-08 08:54:57 -05:00
08d28bfc28 [CI:DOCS] OWNERS: add @ygalblum and @alexlarsson
Both are Quadlet maintainers and active contributors.
With great power, comes great responsibility.

Signed-off-by: Valentin Rothberg <vrothberg@redhat.com>
2023-02-08 13:29:58 +01:00
b829588a32 Merge pull request #17421 from sstosh/e2e-fix-remote
e2e: fix some tests on remote
2023-02-08 07:29:47 -05:00
47df0ca254 build(deps): bump golang.org/x/term from 0.4.0 to 0.5.0
Bumps [golang.org/x/term](https://github.com/golang/term) from 0.4.0 to 0.5.0.
- [Release notes](https://github.com/golang/term/releases)
- [Commits](https://github.com/golang/term/compare/v0.4.0...v0.5.0)

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

Signed-off-by: dependabot[bot] <support@github.com>
2023-02-08 12:04:35 +00:00
ded44be160 build(deps): bump github.com/vbauerster/mpb/v8 from 8.1.4 to 8.1.6
Bumps [github.com/vbauerster/mpb/v8](https://github.com/vbauerster/mpb) from 8.1.4 to 8.1.6.
- [Release notes](https://github.com/vbauerster/mpb/releases)
- [Commits](https://github.com/vbauerster/mpb/compare/v8.1.4...v8.1.6)

---
updated-dependencies:
- dependency-name: github.com/vbauerster/mpb/v8
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2023-02-08 12:04:11 +00:00
4368c587b0 Merge pull request #17342 from mtrmac/mpb
Update to github.com/vbauerster/mpb/v8
2023-02-08 05:52:46 -05:00