summaryrefslogtreecommitdiff
path: root/pkg/domain
diff options
context:
space:
mode:
authortheunrealgeek <theunrealgeek@gmail.com>2020-05-25 00:11:58 -0700
committertheunrealgeek <theunrealgeek@gmail.com>2020-06-02 20:33:16 -0700
commit103c9225a991f771fc171260aade1125ef1ccf49 (patch)
tree1397b8fecfe95ed9ff3abdc7d56fbfa7a7e27a5b /pkg/domain
parent478f296fb345ce9edc707aa4bcd588f8ffd55bb8 (diff)
downloadpodman-103c9225a991f771fc171260aade1125ef1ccf49.tar.gz
podman-103c9225a991f771fc171260aade1125ef1ccf49.tar.bz2
podman-103c9225a991f771fc171260aade1125ef1ccf49.zip
Fix existing tests
Signed-off-by: Aditya Kamath <theunrealgeek@gmail.com>
Diffstat (limited to 'pkg/domain')
-rw-r--r--pkg/domain/infra/abi/play.go6
1 files changed, 4 insertions, 2 deletions
diff --git a/pkg/domain/infra/abi/play.go b/pkg/domain/infra/abi/play.go
index ce18930b7..98b278271 100644
--- a/pkg/domain/infra/abi/play.go
+++ b/pkg/domain/infra/abi/play.go
@@ -424,7 +424,6 @@ func kubeContainerToCreateConfig(ctx context.Context, containerYAML v1.Container
containerConfig.Image = containerYAML.Image
containerConfig.ImageID = newImage.ID()
- containerConfig.Name = containerYAML.Name
// podName should be non-empty for Deployment objects to be able to create
// multiple pods having containers with unique names
@@ -446,7 +445,10 @@ func kubeContainerToCreateConfig(ctx context.Context, containerYAML v1.Container
setupSecurityContext(&securityConfig, &userConfig, containerYAML)
- securityConfig.SeccompProfilePath = seccompPaths.findForContainer(containerConfig.Name)
+ // Since we prefix the container name with pod name to work-around the uniqueness requirement,
+ // seccom stuff should reference the actual container name from the YAML
+ // but apply to the containers with the prefixed name
+ securityConfig.SeccompProfilePath = seccompPaths.findForContainer(containerYAML.Name)
containerConfig.Command = []string{}
if imageData != nil && imageData.Config != nil {