diff options
author | OpenShift Merge Robot <openshift-merge-robot@users.noreply.github.com> | 2021-06-23 15:51:29 -0400 |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-06-23 15:51:29 -0400 |
commit | 3f3feaa015af6e0831daf039f1cd5a0cba3de6c2 (patch) | |
tree | 0bc3c003a0546e89006159030f35031931a832fd /libpod/pod_api.go | |
parent | b0a3ac35785fca1a054d236937c86cce85631585 (diff) | |
parent | bbd085ad1e3cf9c5b543c907ad7014ccf8a5cb34 (diff) | |
download | podman-3f3feaa015af6e0831daf039f1cd5a0cba3de6c2.tar.gz podman-3f3feaa015af6e0831daf039f1cd5a0cba3de6c2.tar.bz2 podman-3f3feaa015af6e0831daf039f1cd5a0cba3de6c2.zip |
Merge pull request #10716 from cdoern/podFlags
Podman Pod Create --cpus and --cpuset-cpus flags
Diffstat (limited to 'libpod/pod_api.go')
-rw-r--r-- | libpod/pod_api.go | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/libpod/pod_api.go b/libpod/pod_api.go index 14fe8276c..d8f5d15f8 100644 --- a/libpod/pod_api.go +++ b/libpod/pod_api.go @@ -538,6 +538,9 @@ func (p *Pod) Inspect() (*define.InspectPodData, error) { infraConfig.StaticMAC = p.config.InfraContainer.StaticMAC.String() infraConfig.NoManageResolvConf = p.config.InfraContainer.UseImageResolvConf infraConfig.NoManageHosts = p.config.InfraContainer.UseImageHosts + infraConfig.CPUPeriod = p.CPUPeriod() + infraConfig.CPUQuota = p.CPUQuota() + infraConfig.CPUSetCPUs = p.ResourceLim().CPU.Cpus if len(p.config.InfraContainer.DNSServer) > 0 { infraConfig.DNSServer = make([]string, 0, len(p.config.InfraContainer.DNSServer)) @@ -581,6 +584,9 @@ func (p *Pod) Inspect() (*define.InspectPodData, error) { SharedNamespaces: sharesNS, NumContainers: uint(len(containers)), Containers: ctrs, + CPUSetCPUs: p.ResourceLim().CPU.Cpus, + CPUPeriod: p.CPUPeriod(), + CPUQuota: p.CPUQuota(), } return &inspectData, nil |