3459 Commits

Author SHA1 Message Date
91b00281e8 Merge pull request #2689 from cevich/new_images
Cirrus: Update VM Cache images
2019-03-18 09:47:55 -07:00
3716235e53 Merge pull request #2687 from rhatdan/inspect
Fix cut and paste errors in podman-pod-inspect
2019-03-18 09:31:38 -07:00
4b3161b687 Merge pull request #2679 from baude/issue2677
podman logs on created container should exit
2019-03-18 09:22:07 -07:00
51f223ec1c Cirrus: Update VM Cache images
Undo short-term slirp4netns workaround (#2660)

Signed-off-by: Chris Evich <cevich@redhat.com>
2019-03-18 11:25:38 -04:00
46f18764f2 podman logs on created container should exit
when running podman logs on a created container (which has no logs),
podman should return gracefully (like docker) with a 0 return code. if
multiple containers are provided and one is only in the created state
(and no follow is used), we still display the logs for the other ids.

fixes issue #2677

Signed-off-by: baude <bbaude@redhat.com>
2019-03-18 08:58:48 -05:00
ea54a1c2f5 Merge pull request #2670 from giuseppe/runtime-write-rootless-conf-before-reload
rootless: write the custom config file before reload
2019-03-18 06:35:39 -07:00
310155b4ee Merge pull request #2685 from kunalkushwaha/ps-man-page-fix-2664
output of port grouping in ps command added as example
2019-03-18 06:15:01 -07:00
cd5f4786ce Merge pull request #2684 from giuseppe/fix-crash-pod-inspect
pod: fix segfault when there are no arguments to inspect
2019-03-18 06:14:53 -07:00
776040e987 Fix cut and paste errors in podman-pod-inspect
Help information and errors should refer to pod inspection, not container and
image inspection.

Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
2019-03-18 08:59:47 -04:00
122d00f67f Merge pull request #2683 from giuseppe/fix-pod-top
rootless: fix pod top
2019-03-18 05:00:15 -07:00
46b74a8ff8 rootless: fix pod top
we need to join the namespace of the target pod.

Closes: https://github.com/containers/libpod/issues/2682

Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
2019-03-18 11:40:22 +01:00
7fee7d833c pod: fix segfault when there are no arguments to inspect
Closes: https://github.com/containers/libpod/issues/2681

Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
2019-03-18 09:37:43 +01:00
1549a7666b output of port grouping in ps command added as example
Signed-off-by: Kunal Kushwaha <kushwaha_kunal_v7@lab.ntt.co.jp>
2019-03-18 10:05:34 +09:00
232b46a374 utils: split generation and writing of storage.conf
split the generation for the default storage.conf and when we write it
if not existing for a rootless user.

This is necessary because during the startup we might be overriding
the default configuration through --storage-driver and --storage-opt,
that would not be written down to the storage.conf file we generated.

Closes: https://github.com/containers/libpod/issues/2659

Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
2019-03-17 10:45:51 +01:00
7f9fdbeafe Merge pull request #2676 from cevich/fix_fail_irc
Cirrus: Fix post-merge failure notice
2019-03-16 12:59:32 -07:00
4b771162ce Merge pull request #2657 from edsantiago/image_tree_usage
podman image tree: fix usage message
2019-03-16 11:34:32 -07:00
2e2a173567 Cirrus: Fix post-merge failure notice
Likely caused by rebase typos after removing test-commit.  This fixes
notifications to actually get sent.  Also show env. vars after setting
up the environment - helps debugging.

Signed-off-by: Chris Evich <cevich@redhat.com>
2019-03-16 12:14:43 -04:00
ea0b36bcbb utils: avoid too long tmp directory
or we will easily pass the 108 chars limits for unix paths.

Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
2019-03-16 15:17:33 +01:00
8a570b2dd2 podman image tree: fix usage message
Minor fix to Use message: add IMAGE argument. (I'm a stickler
for this because my zsh completion is self-generating, from
the --help messages).

Also, sort 'tree' before 'trust' in man page.

Signed-off-by: Ed Santiago <santiago@redhat.com>
2019-03-16 08:09:35 -06:00
97fb495718 Merge pull request #2620 from baude/multilogs
display logs for multiple containers at the same time
2019-03-16 04:21:32 -07:00
3384bd87c8 Merge pull request #2672 from TomSweeneyRedHat/dev/tsweeney/clistoreconf
Add CLI storage conf example to run manpage
2019-03-16 04:12:38 -07:00
688c1b33b5 Merge pull request #2650 from cevich/notify_post_merge_fail_two
Cirrus: Notify on IRC if post-merge testing fails
2019-03-16 04:12:31 -07:00
37467beaf9 Merge pull request #2664 from kunalkushwaha/ps-port-fix
port grouping in ps command output
2019-03-16 04:03:38 -07:00
0015f403b5 Merge pull request #2658 from mheon/sctp
Add support for SCTP port forwarding
2019-03-16 04:03:31 -07:00
2c727eef83 Merge pull request #2675 from giuseppe/rootless-use-readable-path-for-conmon
rootless: change default path for conmon.pid
2019-03-16 03:45:30 -07:00
0e76921048 Cirrus: Notify on IRC if post-merge testing fails
Until recently it was very difficult to execute any scripts if part of a
task failed.  A new feature in Cirrus-CI makes this easy.  Use it to
post a notice on IRC when any task fails.

Also: Add quotes around yaml-string values for consistency and
syntax-highlighting correctness.

Signed-off-by: Chris Evich <cevich@redhat.com>
2019-03-15 21:21:50 -04:00
6c6a865436 rootless: change default path for conmon.pid
We cannot use the RunDir for writing the conmon.pid file as we might
not be able to read it before we join a namespace, since it is owned
by the root in the container which can be a different uid when using
uidmap.  To avoid completely the issue, we will just write it to the
static dir which is always readable by the unprivileged user.

Closes: https://github.com/containers/libpod/issues/2673

Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
2019-03-15 22:53:23 +01:00
3754f58499 Merge pull request #2643 from rhatdan/volumes
Make sure buildin volumes have the same ownership and permissions as …
2019-03-15 14:52:45 -07:00
26a89b61b3 Add CLI storage conf example to run manpage
Signed-off-by: TomSweeneyRedHat <tsweeney@redhat.com>

Add an example to the run man page to illustrate how
you can configure storage from the CLI.  This addresses
a request from issue #2662.

Signed-off-by: TomSweeneyRedHat <tsweeney@redhat.com>
2019-03-15 15:03:47 -04:00
a0c35c394b Integration test tweaks
Wait for more than 1 second on podman info to complete.  Also, add
clarification to why slirp fails.

Signed-off-by: baude <bbaude@redhat.com>
2019-03-15 13:41:01 -05:00
5e86acd591 display logs for multiple containers at the same time
add the ability for users to specify more than one container at a time
while using podman logs.  If more than one container is being displayed,
podman will also prepend a shortened container id of the container on
the log line.

also, enabled the podman-remote logs command during the refactoring of
the above ability.

fixes issue #2219

Signed-off-by: baude <bbaude@redhat.com>
2019-03-15 13:41:01 -05:00
6e4c32967e Merge pull request #2595 from jwhonce/bug/1677908
Add --replace flag to "podman container runlabel"
2019-03-15 10:52:57 -07:00
7efefde3bc rootless: write the custom config file before reload
so that when we do a rootlessReload we inherit the correct settings
from the command line.

Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
2019-03-15 17:05:06 +01:00
101e6f6b74 Add support for SCTP port forwarding
SCTP is already present and enabled in the CNI plugins, so all we
need to do to add support is not error on attempting to bind
ports to reserve them.

I investigated adding this binding for SCTP, but support for SCTP
in Go is honestly a mess - there's no widely-supported library
for doing it that will do what we need.

For now, warn that port reservation for SCTP is not supported and
forward the ports.

Signed-off-by: Matthew Heon <mheon@redhat.com>
2019-03-15 10:51:33 -04:00
9d81be9614 Make sure buildin volumes have the same ownership and permissions as image
When creating a new image volume to be mounted into a container, we need to
make sure the new volume matches the Ownership and permissions of the path
that it will be mounted on.

For example if a volume inside of a containre image is owned by the database
UID, we want the volume to be mounted onto the image to be owned by the
database UID.

Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
2019-03-15 10:44:44 -04:00
8aed32acea Merge pull request #2655 from giuseppe/tmp-user
rootless: use /tmp/libpod-rundir-$EUID for fallback
2019-03-15 07:28:42 -07:00
a73814cc67 Merge pull request #2646 from giuseppe/fix-build-order
build: fix build DIR -t TAG
2019-03-15 07:01:37 -07:00
e16cdf711f Merge pull request #2637 from edsantiago/zsh_completion
zsh completion
2019-03-15 07:01:28 -07:00
ccf991f530 Merge pull request #2633 from edsantiago/default_default
Usage messages: deduplicate '(default true)' et al
2019-03-15 06:22:46 -07:00
37dcc0a305 Merge pull request #2617 from giuseppe/fix-with-config
runtime: fill the runtime config with sane defaults
2019-03-15 05:29:13 -07:00
f4c41961e3 Merge pull request #2656 from giuseppe/fix-rootfs-segfault
container: check containerInfo.Config before accessing it
2019-03-15 04:52:33 -07:00
dd8edd639f rootless: do not override user settings
if the settings are available in the user config file, do not override
them with the global configuration.

Closes: https://github.com/containers/libpod/issues/2614

Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
2019-03-15 10:39:40 +01:00
14cfc63631 runtime: refactor NewRuntime and NewRuntimeFromConfig
we had two functions NewRuntimeFromConfig and NewRuntime that differed
only for the config file they use.

Move comon logic to newRuntimeFromConfig and let it lookup the
configuration file to use when one is not specified.

Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
2019-03-15 10:39:39 +01:00
549e81ff3b events: use os.SEEK_END instead of its value
Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
2019-03-15 10:39:38 +01:00
508e08410b container: check containerInfo.Config before accessing it
check that containerInfo.Config is not nil before trying to access
it.

Closes: https://github.com/containers/libpod/issues/2654

Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
2019-03-15 10:39:33 +01:00
e6a4bac09e rootless: use Geteuid instead of Getuid
Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
2019-03-15 10:39:23 +01:00
592a2fd544 rootless: use /tmp/libpod-rundir-$EUID for fallback
when the fallback is in place, the first user creating /tmp/user/$EUID
prevents other users for creating other directories since /tmp/user is
created with mode 0700.

Since there is no way for an unprivileged user to initialize the
/tmp/user directory correctly (we would need it to be owned by root
with the sticky bit set), let's just use /tmp/libpod-rundir-$EUID.

Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
2019-03-15 10:39:23 +01:00
fc65d71df2 build: fix build DIR -t TAG
accept also the order "build DIR -t TAG"

Closes: https://github.com/containers/libpod/issues/2636

Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
2019-03-15 10:39:17 +01:00
39859850ae Merge pull request #2645 from mheon/fix_some_flakes
Fix a few flakes
2019-03-15 02:04:01 -07:00
6b46e7c6f7 Merge pull request #2660 from giuseppe/upgrade-slirp4netns
cirrus: upgrade slirp4netns
2019-03-15 01:40:55 -07:00