Skip to content

Commit 834f1f6

Browse files
bauderh-atomic-bot
authored andcommitted
varlink info
The varlinfo info returns the same information as podman info but always includes the so-called debug information. Signed-off-by: baude <[email protected]> Closes: #745 Approved by: baude
1 parent f97de48 commit 834f1f6

File tree

4 files changed

+1142
-799
lines changed

4 files changed

+1142
-799
lines changed

API.md

Lines changed: 91 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -33,6 +33,8 @@ in the [API.md](https://github.com/projectatomic/libpod/blob/master/API.md) file
3333

3434
[func ImportImage(source: string, reference: string, message: string, changes: []string) string](#ImportImage)
3535

36+
[func Info() PodmanInfo](#Info)
37+
3638
[func InspectContainer(name: string) string](#InspectContainer)
3739

3840
[func InspectImage(name: string) string](#InspectImage)
@@ -94,10 +96,20 @@ in the [API.md](https://github.com/projectatomic/libpod/blob/master/API.md) file
9496

9597
[type ImageSearch](#ImageSearch)
9698

99+
[type InfoGraphStatus](#InfoGraphStatus)
100+
101+
[type InfoHost](#InfoHost)
102+
103+
[type InfoPodmanBinary](#InfoPodmanBinary)
104+
105+
[type InfoStore](#InfoStore)
106+
97107
[type ListContainerData](#ListContainerData)
98108

99109
[type NotImplemented](#NotImplemented)
100110

111+
[type PodmanInfo](#PodmanInfo)
112+
101113
[type StringResponse](#StringResponse)
102114

103115
[type Version](#Version)
@@ -225,6 +237,12 @@ history is in the form of an array of ImageHistory structures. If the image can
225237
method ImportImage(source: [string](https://godoc.org/builtin#string), reference: [string](https://godoc.org/builtin#string), message: [string](https://godoc.org/builtin#string), changes: [[]string](#[]string)) [string](https://godoc.org/builtin#string)</div>
226238
ImportImage imports an image from a source (like tarball) into local storage. The image can have additional
227239
descriptions added to it using the message and changes options. See also [ExportImage](ExportImage).
240+
### <a name="Info"></a>func Info
241+
<div style="background-color: #E8E8E8; padding: 15px; margin: 10px; border-radius: 10px;">
242+
243+
method Info() [PodmanInfo](#PodmanInfo)</div>
244+
Info returns a [PodmanInfo](#PodmanInfo) struct that describes podman and its host such as storage stats,
245+
build information of Podman, and system-wide registries.
228246
### <a name="InspectContainer"></a>func InspectContainer
229247
<div style="background-color: #E8E8E8; padding: 15px; margin: 10px; border-radius: 10px;">
230248

@@ -555,6 +573,66 @@ is_automated [bool](https://godoc.org/builtin#bool)
555573
name [string](https://godoc.org/builtin#string)
556574

557575
star_count [int](https://godoc.org/builtin#int)
576+
### <a name="InfoGraphStatus"></a>type InfoGraphStatus
577+
578+
InfoGraphStatus describes the detailed status of the graphc
579+
580+
backing_filesystem [string](https://godoc.org/builtin#string)
581+
582+
native_overlay_diff [string](https://godoc.org/builtin#string)
583+
584+
supports_d_type [string](https://godoc.org/builtin#string)
585+
### <a name="InfoHost"></a>type InfoHost
586+
587+
InfoHost describes the host stats portion of PodmanInfo
588+
589+
mem_free [int](https://godoc.org/builtin#int)
590+
591+
mem_total [int](https://godoc.org/builtin#int)
592+
593+
swap_free [int](https://godoc.org/builtin#int)
594+
595+
swap_total [int](https://godoc.org/builtin#int)
596+
597+
arch [string](https://godoc.org/builtin#string)
598+
599+
cpus [int](https://godoc.org/builtin#int)
600+
601+
hostname [string](https://godoc.org/builtin#string)
602+
603+
kernel [string](https://godoc.org/builtin#string)
604+
605+
os [string](https://godoc.org/builtin#string)
606+
607+
uptime [string](https://godoc.org/builtin#string)
608+
### <a name="InfoPodmanBinary"></a>type InfoPodmanBinary
609+
610+
InfoPodman provides details on the podman binary
611+
612+
compiler [string](https://godoc.org/builtin#string)
613+
614+
go_version [string](https://godoc.org/builtin#string)
615+
616+
podman_version [string](https://godoc.org/builtin#string)
617+
618+
git_commit [string](https://godoc.org/builtin#string)
619+
### <a name="InfoStore"></a>type InfoStore
620+
621+
InfoStore describes the host's storage informatoin
622+
623+
containers [int](https://godoc.org/builtin#int)
624+
625+
images [int](https://godoc.org/builtin#int)
626+
627+
graph_driver_name [string](https://godoc.org/builtin#string)
628+
629+
graph_driver_options [string](https://godoc.org/builtin#string)
630+
631+
graph_root [string](https://godoc.org/builtin#string)
632+
633+
graph_status [InfoGraphStatus](#InfoGraphStatus)
634+
635+
run_root [string](https://godoc.org/builtin#string)
558636
### <a name="ListContainerData"></a>type ListContainerData
559637

560638
ListContainer is the returned struct for an individual container
@@ -593,6 +671,19 @@ namespaces [ContainerNameSpace](#ContainerNameSpace)
593671

594672

595673
comment [string](https://godoc.org/builtin#string)
674+
### <a name="PodmanInfo"></a>type PodmanInfo
675+
676+
PodmanInfo describes the Podman host and build
677+
678+
host [InfoHost](#InfoHost)
679+
680+
registries [[]string](#[]string)
681+
682+
insecure_registries [[]string](#[]string)
683+
684+
store [InfoStore](#InfoStore)
685+
686+
podman [InfoPodmanBinary](#InfoPodmanBinary)
596687
### <a name="StringResponse"></a>type StringResponse
597688

598689

cmd/podman/varlink/io.projectatomic.podman.varlink

Lines changed: 52 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -124,6 +124,55 @@ type ContainerNameSpace (
124124
ipc: string
125125
)
126126

127+
# InfoHost describes the host stats portion of PodmanInfo
128+
type InfoHost (
129+
mem_free: int,
130+
mem_total: int,
131+
swap_free: int,
132+
swap_total: int,
133+
arch: string,
134+
cpus: int,
135+
hostname: string,
136+
kernel: string,
137+
os: string,
138+
uptime: string
139+
)
140+
141+
# InfoGraphStatus describes the detailed status of the graph
142+
type InfoGraphStatus (
143+
backing_filesystem: string,
144+
native_overlay_diff: string,
145+
supports_d_type: string
146+
)
147+
148+
# InfoStore describes the host's storage informatoin
149+
type InfoStore (
150+
containers: int,
151+
images: int,
152+
graph_driver_name: string,
153+
graph_driver_options: string,
154+
graph_root: string,
155+
graph_status: InfoGraphStatus,
156+
run_root: string
157+
)
158+
159+
# InfoPodman provides details on the podman binary
160+
type InfoPodmanBinary (
161+
compiler: string,
162+
go_version: string,
163+
podman_version: string,
164+
git_commit: string
165+
)
166+
167+
# PodmanInfo describes the Podman host and build
168+
type PodmanInfo (
169+
host: InfoHost,
170+
registries: []string,
171+
insecure_registries: []string,
172+
store: InfoStore,
173+
podman: InfoPodmanBinary
174+
)
175+
127176
# Ping provides a response for developers to ensure their varlink setup is working.
128177
# #### Example
129178
# ~~~
@@ -140,6 +189,9 @@ method Ping() -> (ping: StringResponse)
140189
# system.
141190
method GetVersion() -> (version: Version)
142191

192+
# GetInfo returns a [PodmanInfo](#PodmanInfo) struct that describes podman and its host such as storage stats,
193+
# build information of Podman, and system-wide registries.
194+
method GetInfo() -> (info: PodmanInfo)
143195

144196
# ListContainers returns a list of containers in no particular order. There are
145197
# returned as an array of ListContainerData structs. See also [GetContainer](#GetContainer).

0 commit comments

Comments
 (0)