Commit Graph

6 Commits

Author SHA1 Message Date
Paul Holzinger d7ccff3edb
Fix default CNI paths
We need to use the default from containers.conf and not hardcode them in
buildah. This fixes an issue with the cni network backend since it would
try to access /etc/cni/net.d/ even as rootless user. This regression was
introduced in commit f9cff07b81.

Also hide the cni flags as we do not expect users to change this. The
recommended way is to change them in containers.conf.

[NO NEW TESTS NEEDED]

Signed-off-by: Paul Holzinger <pholzing@redhat.com>
2022-01-10 15:49:43 +01:00
Daniel J Walsh 514a3f1a91
Shrink the vendoring size of pkc/cli
This PR removes the pkg/auth which brings in docker/docker
since it really is not needed, and was only there to help users
discover the settings of where the authfile was, when the environment
variables were set.  Would almost never be of any value.

Move imagebuildah.BuildOptions to define.BuildOptions

Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
2021-03-03 14:18:35 -05:00
Daniel J Walsh f4424ca9e8
Pick default OCI Runtime from containers.conf
Currently we have a weird situation where the user sets the default
runtime in his containers.conf for podman but Buildah is still falling
back to use runc because it was hard coded as the default for Buildah.

I would like to remove this default, but that would theoretically break
the API promise of Buildah.

This should fix https://github.com/containers/podman/issues/8893

Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
2021-01-22 07:31:23 -05:00
Daniel J Walsh 02f54e4b1e Allow ping command without NET_RAW Capabilities
Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>

Closes: #818
Approved by: nalind
2018-07-31 19:41:44 +00:00
Nalin Dahyabhai 2064b29f40 Run(): add options for adding and removing capabilities
Add RunOptions and BuildOptions flags for modifying the list of granted
capabilities from the default.

Default to granting the current (as of this writing) defaults from
runtime-tools, with CAP_NET_RAW removed:
* CAP_AUDIT_WRITE
* CAP_CHOWN
* CAP_DAC_OVERRIDE
* CAP_FOWNER
* CAP_FSETID
* CAP_KILL
* CAP_MKNOD
* CAP_NET_BIND_SERVICE
* CAP_SETFCAP
* CAP_SETGID
* CAP_SETPCAP
* CAP_SETUID
* CAP_SYS_CHROOT

Signed-off-by: Nalin Dahyabhai <nalin@redhat.com>

Closes: #799
Approved by: rhatdan
2018-06-18 21:07:08 +00:00
Nalin Dahyabhai 00fafcf9cb Use CNI to configure container networks
Use CNI to configure networks for containers for which we create new
network namespaces.

Signed-off-by: Nalin Dahyabhai <nalin@redhat.com>

Closes: #700
Approved by: rhatdan
2018-05-24 14:10:01 +00:00