Commit graph

23873 commits

Author SHA1 Message Date
Peter Hunt
776eb64ab2 exec: fix pipes
In a largely anticlimatic solution to the saga of piped input from conmon, we come to this solution.

When we pass the Stdin stream to the exec.Command structure, it's immediately consumed and lost, instead of being consumed through CopyDetachable().

When we don't pass -i in, conmon is not told to create a masterfd_stdin, and won't pass anything to the container.

With both, we can do

echo hi | podman exec -til cat

and get the expected hi

Signed-off-by: Peter Hunt <pehunt@redhat.com>
2020-01-08 11:09:08 -05:00
OpenShift Merge Robot
c6ad42a176
Merge pull request #4816 from vrothberg/lint
Fix golint errors
2020-01-08 16:58:50 +01:00
Valentin Rothberg
bcf5753276 fix lint - pkg/varlinkapi/virtwriter
Signed-off-by: Valentin Rothberg <rothberg@redhat.com>
2020-01-08 15:44:30 +01:00
Valentin Rothberg
2311e5ff8a fix lint - pkg/util: func comment
Signed-off-by: Valentin Rothberg <rothberg@redhat.com>
2020-01-08 15:44:30 +01:00
Valentin Rothberg
1d1519b08b fix lint - pkg/spec
Signed-off-by: Valentin Rothberg <rothberg@redhat.com>
2020-01-08 15:44:30 +01:00
Valentin Rothberg
83764b84ec fix lint in pkg/rootless
Signed-off-by: Valentin Rothberg <rothberg@redhat.com>
2020-01-08 15:44:30 +01:00
Valentin Rothberg
88369acfca fix lint - pkg/network: comment exported types
Signed-off-by: Valentin Rothberg <rothberg@redhat.com>
2020-01-08 15:44:30 +01:00
Valentin Rothberg
18c702d053 fix lint - pkg/adapter: comment exported API
Signed-off-by: Valentin Rothberg <rothberg@redhat.com>
2020-01-08 15:44:30 +01:00
Valentin Rothberg
583ff5320f fix lint - ignore image.ImageDeleteResponse definition
Golint claims that image.Image stutters but renaming the type would be a
breaking change which isn't worth the consequences.

Signed-off-by: Valentin Rothberg <rothberg@redhat.com>
2020-01-08 15:44:30 +01:00
Valentin Rothberg
0b53ff2902 fix lint - drop else block
Signed-off-by: Valentin Rothberg <rothberg@redhat.com>
2020-01-08 15:44:21 +01:00
OpenShift Merge Robot
27caffbb24
Merge pull request #4712 from openSUSE/untag-command
Add `untag` sub-command
2020-01-08 15:05:06 +01:00
Valentin Rothberg
baba52c6b5 fix lint: add comment for NameRegex and error
Signed-off-by: Valentin Rothberg <rothberg@redhat.com>
2020-01-08 13:55:14 +01:00
Valentin Rothberg
8ae672632b fix lint: correct func identifier in comment
Signed-off-by: Valentin Rothberg <rothberg@redhat.com>
2020-01-08 13:52:52 +01:00
Valentin Rothberg
aaec8b2408 fix lint: "guarantess" is a misspelling of "guarantees"
Signed-off-by: Valentin Rothberg <rothberg@redhat.com>
2020-01-08 13:51:13 +01:00
Daniel J Walsh
0b9dd1a1a0
Merge pull request #4810 from TomSweeneyRedHat/dev/tsweeney/updateinspectcommands
Update demo for the inspect command
2020-01-08 07:47:17 -05:00
OpenShift Merge Robot
a8a766853e
Merge pull request #4795 from ssbarnea/master
packaging: validate installed rpms
2020-01-08 13:44:24 +01:00
OpenShift Merge Robot
b33c774c15
Merge pull request #4592 from AkihiroSuda/rootlesskit-port-forwarder
rootless: use RootlessKit port forwarder
2020-01-08 13:16:22 +01:00
Akihiro Suda
da7595a69f rootless: use RootlessKit port forwarder
RootlessKit port forwarder has a lot of advantages over the slirp4netns port forwarder:

* Very high throughput.
  Benchmark result on Travis: socat: 5.2 Gbps, slirp4netns: 8.3 Gbps, RootlessKit: 27.3 Gbps
  (https://travis-ci.org/rootless-containers/rootlesskit/builds/597056377)

* Connections from the host are treated as 127.0.0.1 rather than 10.0.2.2 in the namespace.
  No UDP issue (#4586)

* No tcp_rmem issue (#4537)

* Probably works with IPv6. Even if not, it is trivial to support IPv6.  (#4311)

* Easily extensible for future support of SCTP

* Easily extensible for future support of `lxc-user-nic` SUID network

RootlessKit port forwarder has been already adopted as the default port forwarder by Rootless Docker/Moby,
and no issue has been reported AFAIK.

As the port forwarder is imported as a Go package, no `rootlesskit` binary is required for Podman.

Fix #4586
May-fix #4559
Fix #4537
May-fix #4311

See https://github.com/rootless-containers/rootlesskit/blob/v0.7.0/pkg/port/builtin/builtin.go

Signed-off-by: Akihiro Suda <akihiro.suda.cz@hco.ntt.co.jp>
2020-01-08 19:35:17 +09:00
Sascha Grunert
40b74e02b7
Add untag sub-command
Podman now supports untagging images via the `untag` sub-command for the
root and `image` commands. Testing and documentation has been added as
well.

Signed-off-by: Sascha Grunert <sgrunert@suse.com>
2020-01-08 10:06:10 +01:00
TomSweeneyRedHat
9ea34f8ffa Update demo for the inspect command
Updates the inspect command demo with an up to date
variant and adds a link to script that ran it.

Signed-off-by: TomSweeneyRedHat <tsweeney@redhat.com>
2020-01-07 19:42:54 -05:00
Daniel J Walsh
d52a4dc2d4
Fix podman-remote info to show registry data
Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
2020-01-07 19:38:46 -05:00
OpenShift Merge Robot
c41fd09a8d
Merge pull request #4781 from haircommander/seccomp-profile-root
play kube: make seccomp handling better conform to k8s
2020-01-07 22:13:03 +01:00
Sorin Sbarnea
da0319fecd packaging: validate installed rpms
Previously we builded RPMs that contained an outdated conmon which was
not compatible. From now on `make-install` will also call
`podman version` and `podman info` in order to perform a minimal
sanity check of the installation.

Fixes: #4665
Signed-off-by: Sorin Sbarnea <ssbarnea@redhat.com>
2020-01-07 20:06:27 +00:00
OpenShift Merge Robot
bd3d8f4e28
Merge pull request #4788 from vrothberg/stale
github stale workflow: rephrase and bump close time
2020-01-07 18:57:54 +01:00
OpenShift Merge Robot
f85b3a01f0
Merge pull request #4774 from QiWang19/cp_src_path
fix bug copy from container directory
2020-01-07 16:10:05 +01:00
Valentin Rothberg
8094ee89ba github stale workflow: rephrase and bump close time
Rephrase the stale message to be friendlier and bump the closing time to
365 days.  The docs of the stale workflow do not indicate whether we can
not close, so a limit of 365 days seems fair.

Signed-off-by: Valentin Rothberg <rothberg@redhat.com>
2020-01-07 11:04:37 +01:00
Daniel J Walsh
b061bb276d
Don't show PASS on success for gitvalidate
Make test logs less verbose so that failures are easier to spot.

Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
2020-01-06 17:18:18 -05:00
OpenShift Merge Robot
e362220971
Merge pull request #4800 from mheon/bump-1.7.0
Bump to v1.7.0
2020-01-06 22:54:11 +01:00
Matthew Heon
8e4a489e1b Bump gitvalidation epoch
Signed-off-by: Matthew Heon <mheon@redhat.com>
2020-01-06 15:16:38 -05:00
Matthew Heon
08849db4b0 Bump to v1.7.1-dev
Signed-off-by: Matthew Heon <mheon@redhat.com>
2020-01-06 15:16:38 -05:00
Matthew Heon
b7ce1157b0 Bump to v1.7.0
Signed-off-by: Matthew Heon <mheon@redhat.com>
2020-01-06 15:16:35 -05:00
OpenShift Merge Robot
2d8f1c8fda
Merge pull request #4762 from NevilleC/nc-issue4367
Generate binaries only if there are changes in src code.
2020-01-06 19:27:03 +01:00
OpenShift Merge Robot
2e0157a2d5
Merge pull request #4797 from edsantiago/policy_json_manpage
(minor) fix broken links to container-policy.json.5
2020-01-06 17:24:40 +01:00
Ed Santiago
6808ab34ea (minor) fix broken links to container-policy.json.5
Two man pages had incorrect references to a nonexistent
policy.conf(5) or policy-conf(5) [dot vs dash]. Fix them.

Also checked for other broken references via:

   $ for i in registries.conf storage.conf policy.json ; do grep -R $i.5 docs/source | grep -v containers-$i;done

(No further results found. That's not a guarantee that there
aren't other broken links though).

Signed-off-by: Ed Santiago <santiago@redhat.com>
2020-01-06 08:34:56 -07:00
Neville Cain
16b793a45a Generate binaries only if they are changes in src code.
Changes I am making:

1. The target `.gopathok` was listed in `.PHONY` which
looks wrong as it regenerates `.gopathok` every time we
 re-run it, which was a part of the issue. I removed it
 to avoid that. If `.gopathok` is present', makefile
should not need to rerun it.

2. Ensure the binaries are created only if they don't
exist by adding `bin/podman`
and `bin/podman-remote`.

3. Add a `SOURCES = $(shell find . -name "*.go")` and put
it as a dependency of the podman binaries target. It allows us
to re-generate the binaries only when there is a change in the
source files. The downside is it increases the running time of
the command that generates them (20 seconds on my virtual machine
running Centos 7). If this is a problem, we could introduce a
hidden file that would list all the files to track, that
would need to be updated only when a dev is introducing new files.

4. Fixed the make package-install as it does not work with yum.
I updated the build_rpm.sh to ensure it works on centos 7
and centos 8 with no pre-required installation.

Closes #4367

Signed-off-by: Neville Cain <neville.cain@qonto.eu>
2020-01-04 23:54:57 +01:00
Peter Hunt
b6792b61de play kube: make seccomp handling better conform to k8s
Add flag --seccomp-profile-root in play kube to allow users to specify where to look for seccomp profiles
update tests

Signed-off-by: Peter Hunt <pehunt@redhat.com>
2020-01-03 13:27:17 -05:00
OpenShift Merge Robot
9758a975e6
Merge pull request #4780 from rhatdan/man
Fix presentation of man page tables
2020-01-03 18:39:08 +01:00
Daniel J Walsh
185373bfeb
Fix presentation of man page tables
Currently the use of "*" in tables is causing go-md2man
to screw up the format of the man page.

This PR removes the "*" since it is not really necessary.

Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
2020-01-03 10:12:14 -05:00
OpenShift Merge Robot
50b4446376
Merge pull request #4777 from mheon/bump-1.7.0-rc2
Bump to v1.7.0-RC2
2020-01-02 21:48:03 +01:00
Matthew Heon
13bff7719e Bump gitvalidation epoch
Signed-off-by: Matthew Heon <matthew.heon@pm.me>
2020-01-02 15:00:43 -05:00
Matthew Heon
5f08f2988a Bump to v1.7.0-dev
Signed-off-by: Matthew Heon <matthew.heon@pm.me>
2020-01-02 15:00:43 -05:00
Matthew Heon
9090c476f7 Bump to v1.7.0-rc2
Signed-off-by: Matthew Heon <matthew.heon@pm.me>
2020-01-02 15:00:37 -05:00
OpenShift Merge Robot
1faa5bb6cd
Merge pull request #4776 from mheon/release_notes_v1.7.0_rc2
Update release notes with further changes from 1.7.0
2020-01-02 20:43:04 +01:00
Matthew Heon
fcca557104 Update release notes with further changes from 1.7.0
Signed-off-by: Matthew Heon <matthew.heon@pm.me>
2020-01-02 13:38:10 -05:00
Qi Wang
b6e1689ff2 fix bug copy from container directory
Keep the original input source path with "/." so podman can copy the content of the directory when copying from container to host.

Signed-off-by: Qi Wang <qiwan@redhat.com>
2020-01-02 00:53:02 -05:00
OpenShift Merge Robot
6a370cbbc7
Merge pull request #4757 from baude/networkrefactor
refactor network commands
2019-12-31 12:54:06 +01:00
baude
93350b9e9f refactor network commands
move core of network commands from pkg/adapter to pkg/network to assist
with api development and remote podman commands.

Signed-off-by: baude <bbaude@redhat.com>
2019-12-29 11:18:49 -06:00
OpenShift Merge Robot
9e03aa14b6
Merge pull request #4748 from NevilleC/nc-podname
[Issue #4703] Add the pod name when we use `podman ps -p`
2019-12-29 12:16:43 +01:00
OpenShift Merge Robot
fa551fd16d
Merge pull request #4756 from edsantiago/fix_kill_test_hang_safely
Fix race condition in kill test leading to hang
2019-12-29 12:03:57 +01:00
OpenShift Merge Robot
6897a1f5c2
Merge pull request #4754 from NevilleC/nc-improvemakeuninstall
Ensure 'make uninstall' removes bin and conf files.
2019-12-28 20:39:58 +01:00