summaryrefslogtreecommitdiff
path: root/cmd/podman/pod_ps.go
diff options
context:
space:
mode:
authorhaircommander <pehunt@redhat.com>2018-08-17 10:36:51 -0400
committerAtomic Bot <atomic-devel@projectatomic.io>2018-08-23 18:16:28 +0000
commit2a7449362f2884d9ae6a783c0ce38979d882e2cf (patch)
tree6e7b8ab33505d210201e62faba6a50f98c0a4ea7 /cmd/podman/pod_ps.go
parent697b46430a8a7c2c7231078911dcec51f0c6fab5 (diff)
downloadpodman-2a7449362f2884d9ae6a783c0ce38979d882e2cf.tar.gz
podman-2a7449362f2884d9ae6a783c0ce38979d882e2cf.tar.bz2
podman-2a7449362f2884d9ae6a783c0ce38979d882e2cf.zip
Change pause container to infra container
Signed-off-by: haircommander <pehunt@redhat.com> Closes: #1187 Approved by: mheon
Diffstat (limited to 'cmd/podman/pod_ps.go')
-rw-r--r--cmd/podman/pod_ps.go16
1 files changed, 8 insertions, 8 deletions
diff --git a/cmd/podman/pod_ps.go b/cmd/podman/pod_ps.go
index 20cda1276..58f404e7a 100644
--- a/cmd/podman/pod_ps.go
+++ b/cmd/podman/pod_ps.go
@@ -57,7 +57,7 @@ type podPsTemplateParams struct {
Status string
Cgroup string
ContainerInfo string
- PauseContainerID string
+ InfraContainerID string
SharedNamespaces string
}
@@ -74,7 +74,7 @@ type podPsJSONParams struct {
Status string `json:"status"`
CtrsInfo []podPsCtrInfo `json:"containerinfo,omitempty"`
Cgroup string `json:"cgroup,omitempty"`
- PauseContainerID string `json:"pausecontainerid,omitempty"`
+ InfraContainerID string `json:"infracontainerid,omitempty"`
SharedNamespaces []string `json:"sharednamespaces,omitempty"`
}
@@ -358,7 +358,7 @@ func genPodPsFormat(c *cli.Context) string {
} else {
format += "\t{{.NumberOfContainers}}"
}
- format += "\t{{.PauseContainerID}}"
+ format += "\t{{.InfraContainerID}}"
}
return format
}
@@ -418,7 +418,7 @@ func getPodTemplateOutput(psParams []podPsJSONParams, opts podPsOptions) ([]podP
for _, psParam := range psParams {
podID := psParam.ID
- pauseID := psParam.PauseContainerID
+ infraID := psParam.InfraContainerID
var ctrStr string
truncated := ""
@@ -428,7 +428,7 @@ func getPodTemplateOutput(psParams []podPsJSONParams, opts podPsOptions) ([]podP
psParam.CtrsInfo = psParam.CtrsInfo[:NUM_CTR_INFO]
truncated = "..."
}
- pauseID = shortID(pauseID)
+ infraID = shortID(infraID)
}
for _, ctrInfo := range psParam.CtrsInfo {
ctrStr += "[ "
@@ -456,7 +456,7 @@ func getPodTemplateOutput(psParams []podPsJSONParams, opts podPsOptions) ([]podP
NumberOfContainers: psParam.NumberOfContainers,
Cgroup: psParam.Cgroup,
ContainerInfo: ctrStr,
- PauseContainerID: pauseID,
+ InfraContainerID: infraID,
SharedNamespaces: strings.Join(psParam.SharedNamespaces, ","),
}
@@ -510,7 +510,7 @@ func getAndSortPodJSONParams(pods []*libpod.Pod, opts podPsOptions, runtime *lib
return nil, err
}
- pauseContainerID, err := pod.PauseContainerID()
+ infraContainerID, err := pod.InfraContainerID()
if err != nil {
return nil, err
}
@@ -547,7 +547,7 @@ func getAndSortPodJSONParams(pods []*libpod.Pod, opts podPsOptions, runtime *lib
NumberOfContainers: ctrNum,
CtrsInfo: ctrsInfo,
SharedNamespaces: getSharedNamespaces(pod),
- PauseContainerID: pauseContainerID,
+ InfraContainerID: infraContainerID,
}
psOutput = append(psOutput, params)