8269 Commits

Author SHA1 Message Date
df0141dc20 Merge pull request #6473 from mheon/fix_inspect_segfault
Fix a segfault in `podman inspect -l` w/ no containers
2020-06-03 19:27:54 +02:00
e77db144ab turn on remote stop_test
turn on stop_test  --cidfile

Signed-off-by: Qi Wang <qiwan@redhat.com>
2020-06-03 12:55:58 -04:00
cbca625328 V2 Add support for ssh authentication methods
* podman --remote ssh://<user>:<password>@<host>:<port><path>
* podman --remote ssh://<user>:<password>@<host>:<port><path> \
  --identity <path> --passphrase <phrase>
* ssh-add <key>
  podman --remote ssh://<user>@<host><path>
* Fix `podman help` to run even if podman missing components
* Prompt for passphrase on stdin IFF key is protected and passphrase
  not given via any other configuration

* cobra flags do not support optional value flags therefore refactored
  --remote to be a boolean and --url will now contain the URI to Podman
  service

Signed-off-by: Jhon Honce <jhonce@redhat.com>
2020-06-03 09:54:39 -07:00
9bd48a64bb Merge pull request #6477 from rhatdan/spec
RHEL8 and Centos8 don't have oci-runtime yet
2020-06-03 16:20:51 +02:00
a88450f68a Add a few CVE entries to changelog.txt
Add the following CVE entries

CVE-2020-1726
CVE-2020-10696
CVE-2019-18466

to changelog.txt

Signed-off-by: Erik Sjölund <erik.sjolund@gmail.com>
2020-06-03 15:07:21 +02:00
428303c789 Merge pull request #6474 from QiWang19/remote-cidfile-test
Turn on remote rm_test
2020-06-03 12:36:39 +02:00
8153f299ad Add more Remote tests
Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
2020-06-03 06:35:45 -04:00
48d2bea1a3 RHEL8 and Centos8 don't have oci-runtime yet
For the time being we need to just require runc
this should fix rdoproject.org/github-check

Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
2020-06-03 06:32:58 -04:00
382342a0b0 test.apiv2: add test cases for committing an image from a container
Testing query parameters: container, repo, tag, comment, author, changes
and pause.

Signed-off-by: Alex Jia <chuanchang.jia@gmail.com>
2020-06-03 05:33:56 +00:00
10ebb74d6f Consistent Yaml convention througout play kube tests
Signed-off-by: Aditya Kamath <theunrealgeek@gmail.com>
2020-06-02 20:49:12 -07:00
5330ce9876 Fix podman generate tests that relied on play kube
Signed-off-by: Aditya Kamath <theunrealgeek@gmail.com>
2020-06-02 20:33:16 -07:00
c739b58ad5 Add tests for Deployment Kind and minor fix for play kube output
Signed-off-by: Aditya Kamath <theunrealgeek@gmail.com>
2020-06-02 20:33:16 -07:00
103c9225a9 Fix existing tests
Signed-off-by: Aditya Kamath <theunrealgeek@gmail.com>
2020-06-02 20:33:16 -07:00
478f296fb3 Modify PlayKubeReport to preserve pod->container mapping
Signed-off-by: Aditya Kamath <theunrealgeek@gmail.com>
2020-06-02 20:33:16 -07:00
ce7a9f0314 supporting k8s Deployment objects
Signed-off-by: Aditya Kamath <theunrealgeek@gmail.com>
2020-06-02 20:33:16 -07:00
5473ba95d7 Turn on remote rm_test --cidfile
Turn on remote rm_test --cidfile

Signed-off-by: Qi Wang <qiwan@redhat.com>
2020-06-02 19:12:31 -04:00
95ea39edf3 Merge pull request #6471 from mheon/troubleshooting_77
Remove reference to "upcoming" RHEL 7.7
2020-06-03 00:05:08 +02:00
26bb48951f Merge pull request #6468 from mheon/remote_detached_exec
Enable detached exec for remote
2020-06-03 00:02:20 +02:00
42505f64d2 Properly follow linked namespace container for stats
Podman containers can specify that they get their network
namespace from another container. This is automatic in pods, but
any container can do it.

The problem is that these containers are not guaranteed to have a
network namespace of their own; it is perfectly valid to join the
network namespace of a --net=host container, and both containers
will end up in the host namespace. The code for obtaining network
stats did not account for this, and could cause segfaults as a
result. Fortunately, the fix is simple - the function we use to
get said stats already performs appropriate checks, so we just
need to recursively call it.

Fixes #5652

Signed-off-by: Matthew Heon <matthew.heon@pm.me>
2020-06-02 17:58:52 -04:00
4b37d4d5af Fix a segfault in podman inspect -l w/ no containers
We also need to rework container/image inspect to be separate,
but that can happen in another PR.

Fixes #6472

Signed-off-by: Matthew Heon <matthew.heon@pm.me>
2020-06-02 17:22:00 -04:00
0c878beb57 Remove reference to "upcoming" RHEL 7.7
7.7 has been released for a while now, so change troubleshooting
reference to indicate that.

Fixes #6349

Signed-off-by: Matthew Heon <matthew.heon@pm.me>
2020-06-02 16:47:28 -04:00
4632a4b706 Merge pull request #6467 from baude/v2windowsenv
make env handling os dependent
2020-06-02 22:36:46 +02:00
69020c7040 Bump Conmon in COPR spec
We need 2.0.17 for detached remote exec.

Signed-off-by: Matthew Heon <matthew.heon@pm.me>
2020-06-02 15:30:42 -04:00
e0d9404634 Enable detached exec for remote
The biggest obstacle here was cleanup - we needed a way to remove
detached exec sessions after they exited, but there's no way to
tell if an exec session will be attached or detached when it's
created, and that's when we must add the exit command that would
do the removal. The solution was adding a delay to the exit
command (5 minutes), which gives sufficient time for attached
exec sessions to retrieve the exit code of the session after it
exits, but still guarantees that they will be removed, even for
detached sessions. This requires Conmon 2.0.17, which has the new
`--exit-delay` flag.

As part of the exit command rework, we can drop the hack we were
using to clean up exec sessions (remove them as part of inspect).
This is a lot cleaner, and I'm a lot happier about it.

Otherwise, this is just plumbing - we need a bindings call for
detached exec, and that needed to be added to the tunnel mode
backend for entities.

Signed-off-by: Matthew Heon <matthew.heon@pm.me>
2020-06-02 15:30:42 -04:00
c4ccd7cbc1 Merge pull request #6435 from QiWang19/uid
check --user range for rootless containers
2020-06-02 20:51:13 +02:00
37ac21ff08 Merge pull request #6460 from vrothberg/no-trunc
images --no-trunc: fix ID formatting
2020-06-02 20:48:18 +02:00
77e4b077b9 check --user range for rootless containers
Check --user range if it's a uid for rootless containers. Returns error if it is out of the range. From https://github.com/containers/libpod/issues/6431#issuecomment-636124686

Signed-off-by: Qi Wang <qiwan@redhat.com>
2020-06-02 11:28:58 -04:00
030a4d3257 images --no-trunc: fix ID formatting
Remove the redundant `sha256:` prefix from the image IDs.

Fixes: #6459
Signed-off-by: Valentin Rothberg <rothberg@redhat.com>
2020-06-02 17:08:31 +02:00
d10addca6c Merge pull request #6457 from rhatdan/psgo
Update vendor containers/psgo
2020-06-02 15:44:15 +02:00
70e6b2e6dd make env handling os dependent
environment variables are handled differently on windows vs linux.  here we split them to be handled but no actually processing of windows environment variables was done.  it can be added for future.  hoowever, now we dont get errors on windows about processing them.

Signed-off-by: Brent Baude <bbaude@redhat.com>
2020-06-02 08:28:08 -05:00
2937151e37 Merge pull request #6445 from containers/dependabot/go_modules/github.com/onsi/ginkgo-1.12.3
Bump github.com/onsi/ginkgo from 1.12.2 to 1.12.3
2020-06-02 09:02:08 -04:00
eb488e760a Merge pull request #6463 from containers/dependabot/go_modules/github.com/coreos/go-systemd/v22-22.1.0
Bump github.com/coreos/go-systemd/v22 from 22.0.0 to 22.1.0
2020-06-02 07:27:53 -04:00
b2feaa4d18 Merge pull request #6462 from containers/dependabot/go_modules/github.com/opencontainers/runc-1.0.0-rc90
Bump github.com/opencontainers/runc from 1.0.0-rc9 to 1.0.0-rc90
2020-06-02 07:25:04 -04:00
02324b916a Bump github.com/containers/conmon
Bumps [github.com/containers/conmon](https://github.com/containers/conmon) from 2.0.16+incompatible to 2.0.17+incompatible.
- [Release notes](https://github.com/containers/conmon/releases)
- [Changelog](https://github.com/containers/conmon/blob/master/changelog.txt)
- [Commits](https://github.com/containers/conmon/compare/v2.0.16...v2.0.17)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>
Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
2020-06-02 07:24:02 -04:00
288bb2e858 Bump github.com/onsi/ginkgo from 1.12.2 to 1.12.3
Bumps [github.com/onsi/ginkgo](https://github.com/onsi/ginkgo) from 1.12.2 to 1.12.3.
- [Release notes](https://github.com/onsi/ginkgo/releases)
- [Changelog](https://github.com/onsi/ginkgo/blob/master/CHANGELOG.md)
- [Commits](https://github.com/onsi/ginkgo/compare/v1.12.2...v1.12.3)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>
Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
2020-06-02 07:22:54 -04:00
92f5029838 Merge pull request #6455 from rhatdan/detatchkeys
Add information on detach-keys
2020-06-02 06:11:09 -04:00
94f2241831 Merge pull request #6411 from mheon/exec_bindings
Add bindings for exec and enable attached remote exec
2020-06-02 06:08:21 -04:00
cc021546c5 Merge pull request #6443 from SCHEN2015/combine_ro_readonly
Combine the code of dealing with 'readonly' and 'ro'.
2020-06-02 06:02:54 -04:00
4157af8776 Update vendor containers/psgo
Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
2020-06-02 05:56:52 -04:00
23ff93d879 Bump github.com/opencontainers/runc from 1.0.0-rc9 to 1.0.0-rc90
Bumps [github.com/opencontainers/runc](https://github.com/opencontainers/runc) from 1.0.0-rc9 to 1.0.0-rc90.
- [Release notes](https://github.com/opencontainers/runc/releases)
- [Commits](https://github.com/opencontainers/runc/compare/v1.0.0-rc9...v1.0.0-rc90)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>
Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
2020-06-02 05:53:10 -04:00
bea4264ed3 Bump github.com/coreos/go-systemd/v22 from 22.0.0 to 22.1.0
Bumps [github.com/coreos/go-systemd/v22](https://github.com/coreos/go-systemd) from 22.0.0 to 22.1.0.
- [Release notes](https://github.com/coreos/go-systemd/releases)
- [Commits](https://github.com/coreos/go-systemd/compare/v22.0.0...v22.1.0)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>
Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
2020-06-02 05:52:35 -04:00
9f08881c20 Combine the code of dealing with 'readonly' and 'ro'.
https://github.com/containers/libpod/pull/6380#discussion_r432391376

Signed-off-by: Charles Shih <schrht@gmail.com>
2020-06-02 09:41:11 +08:00
45a7e7266e Add bindings for exec and enable attached remote
This adds bindings for starting exec sessions, and then uses them
to wire up detached exec. Code is heavily based on Attach code
for containers, slightly modified to handle exec sessions.

Bindings are presently attached-only, detached is pending on a
Conmon update landing in CI. I'll probably get to that next.

Signed-off-by: Matthew Heon <matthew.heon@pm.me>
2020-06-01 17:24:00 -04:00
d6bf6b92c8 Merge pull request #6456 from edsantiago/bats
system tests : more tests
2020-06-01 21:11:41 +02:00
85d3641fe1 Merge pull request #6350 from rhatdan/build
Don't build code on remoteclient
2020-06-01 20:57:58 +02:00
e92a65f38c Merge pull request #6453 from jwhonce/wip/errors
Add invalid value to error message
2020-06-01 20:44:48 +02:00
7c41cb7802 Merge pull request #6454 from rhatdan/remote
Remove skipifremote checks in images_test.go
2020-06-01 20:41:41 +02:00
8b7c7e8125 Add information on detach-keys
Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
2020-06-01 14:38:05 -04:00
03d32d05ac system tests : more tests
- exec: add test for #5046, in which conmon swallowed chars
  on a large byte transfer

- pod: add 'pod exists' tests, both positive and negative;
  consolidate tests; add '--label', and check in 'pod inspect'
  add 'pod ps' tests

- networking: add test for #5466, in which detached run
  with --userns=keep-id would not forward a port

Signed-off-by: Ed Santiago <santiago@redhat.com>
2020-06-01 12:00:47 -06:00
5f1c23dba9 Merge pull request #6449 from baude/v2podlabels
Add support for format {{.Label}}
2020-06-01 19:41:30 +02:00