diff options
author | Doug Rabson <dfr@rabson.org> | 2022-08-26 08:33:18 +0100 |
---|---|---|
committer | Doug Rabson <dfr@rabson.org> | 2022-08-29 13:06:15 +0100 |
commit | 0166feef2a0205967eb95867a7d953f9171b27b7 (patch) | |
tree | b4869e6da0f59f37f9a480f629e37e157beaef66 | |
parent | ac7f4ebb6a1fd3afbaea5e5ede9da0e341c4cdfe (diff) | |
download | podman-0166feef2a0205967eb95867a7d953f9171b27b7.tar.gz podman-0166feef2a0205967eb95867a7d953f9171b27b7.tar.bz2 podman-0166feef2a0205967eb95867a7d953f9171b27b7.zip |
specgen/generate: Move security.go to security_linux.go and add stubs
The security features (selinux, apparmor, capabilities) are linux
specific.
[NO NEW TESTS NEEDED]
Signed-off-by: Doug Rabson <dfr@rabson.org>
-rw-r--r-- | pkg/specgen/generate/security_linux.go (renamed from pkg/specgen/generate/security.go) | 0 | ||||
-rw-r--r-- | pkg/specgen/generate/security_unsupported.go | 24 |
2 files changed, 24 insertions, 0 deletions
diff --git a/pkg/specgen/generate/security.go b/pkg/specgen/generate/security_linux.go index aacefcbac..aacefcbac 100644 --- a/pkg/specgen/generate/security.go +++ b/pkg/specgen/generate/security_linux.go diff --git a/pkg/specgen/generate/security_unsupported.go b/pkg/specgen/generate/security_unsupported.go new file mode 100644 index 000000000..84a1cdab8 --- /dev/null +++ b/pkg/specgen/generate/security_unsupported.go @@ -0,0 +1,24 @@ +//go:build !linux +// +build !linux + +package generate + +import ( + "errors" + + "github.com/containers/common/libimage" + "github.com/containers/common/pkg/config" + "github.com/containers/podman/v4/libpod" + "github.com/containers/podman/v4/pkg/specgen" + "github.com/opencontainers/runtime-tools/generate" +) + +// setLabelOpts sets the label options of the SecurityConfig according to the +// input. +func setLabelOpts(s *specgen.SpecGenerator, runtime *libpod.Runtime, pidConfig specgen.Namespace, ipcConfig specgen.Namespace) error { + return errors.New("unsupported setLabelOpts") +} + +func securityConfigureGenerator(s *specgen.SpecGenerator, g *generate.Generator, newImage *libimage.Image, rtc *config.Config) error { + return errors.New("unsupported securityConfigureGenerator") +} |