Commit Graph

12 Commits

Author SHA1 Message Date
Carlos Eduardo Arango Gutierrez be1f3f6caa fix gofmt on file config_test.go
apply `gofmt -s -w config_test.go`

Signed-off-by: Carlos Eduardo Arango Gutierrez <carangog@redhat.com>
2020-02-17 18:13:03 -05:00
Daniel J Walsh 4fa425fe38 Add Default function to read containers config
This function should be called to return a default config to be used
by callers.

Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
2020-02-10 08:21:07 -05:00
Daniel J Walsh 95fb926363 Stop validating networkconfig by default
This is causing issues in rootless and remote mode.  We should not be creating
directories on the fly.
Also stop exporting functions that are not used by Buildah and Podman.

Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
2020-01-29 06:10:15 -05:00
Daniel J Walsh 789d9a515f Run code through codespell
Fix spelling mistakes found using codespell.

Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
2020-01-08 08:56:50 -05:00
Daniel J Walsh 3e1c3932bf Add new Capability function to parse Capabiltiies
The Capability check handles merging of Default capabiltiies along
with user specified add and drop capabilities.

Fork docker/docker/oci/caps file to prevent a huge vendor

Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
2020-01-07 17:57:04 -05:00
Daniel J Walsh 2603f5de14 Fix handling of SELinux labeling
Also re-add DefaultMountsFile since we need a holding place to be
used in libpod.

Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
2020-01-04 05:45:17 -05:00
Daniel J Walsh 74d7f91c66 Update/Fix man page and fix several bugs in definition.
Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
2020-01-03 13:57:01 -05:00
Daniel J Walsh 67213c41a3 Remove merge code and optional handling
Fix handling of toml files

No longer need merge, since we can specify a default conf for each toml file.
The toml code will retain the previous defaults and only use the newly specified
values.

This greatly simplifies the code.

Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
2019-12-11 08:26:52 -05:00
Qi Wang 894913abdf add libpod.conf to containers.conf
Add configurations from libpod.conf to containers.conf.Use merge code from libpod to read and merge configurations from file.

Add unshare_linux for build linux: HomeDir should buildah not only for linux. so add unshare_linux for linux and unshare.go for other

convert bool to optinalbool:Use OptionalBool for on-disk configurations so we can distinguish field is undefined  vs. user set to false.

Signed-off-by: Qi Wang <qiwan@redhat.com>
2019-12-06 15:55:47 -05:00
Qi Wang 023822b7b0 turn off the check of the hook directory
Signed-off-by: Qi Wang <qiwan@redhat.com>
2019-11-09 13:05:58 -05:00
Qi Wang 64705d1f72 Fix tests failure #11
tests failures should be fixed since #11 add hooksdir to default config.

Signed-off-by: Qi Wang <qiwan@redhat.com>
2019-11-04 10:28:56 -05:00
Qi Wang 9bb8e7e62b Add config package for containers.conf
This PR adds a package config for reading configurations from the containers.conf into the go struct.

Signed-off-by: Qi Wang <qiwan@redhat.com>
2019-10-07 13:38:17 -04:00