summaryrefslogtreecommitdiff
path: root/pkg
diff options
context:
space:
mode:
authoropenshift-ci[bot] <75433959+openshift-ci[bot]@users.noreply.github.com>2021-08-06 12:11:32 +0000
committerGitHub <noreply@github.com>2021-08-06 12:11:32 +0000
commit0eb2a02620e28383d3e4458854411f277d1e30f7 (patch)
tree99aa742239301d68d067070bbc5bbb2fa5f76ce5 /pkg
parenta82ceafb73356d8e3ed825be2f0ad0a29b7c3761 (diff)
parent541e83ffe285cc67f4635d2dd1e7c89135140a13 (diff)
downloadpodman-0eb2a02620e28383d3e4458854411f277d1e30f7.tar.gz
podman-0eb2a02620e28383d3e4458854411f277d1e30f7.tar.bz2
podman-0eb2a02620e28383d3e4458854411f277d1e30f7.zip
Merge pull request #11141 from flouthoc/support-linux-execution-domain
personality: Add support for setting execution domain.
Diffstat (limited to 'pkg')
-rw-r--r--pkg/specgen/generate/oci.go3
-rw-r--r--pkg/specgen/specgen.go5
2 files changed, 8 insertions, 0 deletions
diff --git a/pkg/specgen/generate/oci.go b/pkg/specgen/generate/oci.go
index 6e310d8a6..1f3f9e832 100644
--- a/pkg/specgen/generate/oci.go
+++ b/pkg/specgen/generate/oci.go
@@ -285,6 +285,9 @@ func SpecGenToOCI(ctx context.Context, s *specgen.SpecGenerator, rt *libpod.Runt
}
g.AddMount(cgroupMnt)
}
+
+ g.Config.Linux.Personality = s.Personality
+
g.SetProcessCwd(s.WorkDir)
g.SetProcessArgs(finalCmd)
diff --git a/pkg/specgen/specgen.go b/pkg/specgen/specgen.go
index b4ac337b5..fc647227e 100644
--- a/pkg/specgen/specgen.go
+++ b/pkg/specgen/specgen.go
@@ -186,6 +186,11 @@ type ContainerBasicConfig struct {
// InitContainerType describes if this container is an init container
// and if so, what type: always or oneshot
InitContainerType string `json:"init_container_type"`
+ // Personality allows users to configure different execution domains.
+ // Execution domains tell Linux how to map signal numbers into signal actions.
+ // The execution domain system allows Linux to provide limited support
+ // for binaries compiled under other UNIX-like operating systems.
+ Personality *spec.LinuxPersonality `json:"personality,omitempty"`
}
// ContainerStorageConfig contains information on the storage configuration of a