From ed30ae4a8aacf87cb9be3cfed2e43499cb4d8649 Mon Sep 17 00:00:00 2001 From: Jakub Guzik Date: Mon, 9 Aug 2021 23:57:26 +0200 Subject: Add until filter to podman pod ps This commit adds additional until filter to podman pod ps (ls/list). Additionally, it also adds descriptions for podman pod ps filters available via http api. Signed-off-by: Jakub Guzik --- pkg/api/server/register_pods.go | 13 ++++++++++++- 1 file changed, 12 insertions(+), 1 deletion(-) (limited to 'pkg/api') diff --git a/pkg/api/server/register_pods.go b/pkg/api/server/register_pods.go index 3bcc50ba4..58234005e 100644 --- a/pkg/api/server/register_pods.go +++ b/pkg/api/server/register_pods.go @@ -17,7 +17,18 @@ func (s *APIServer) registerPodsHandlers(r *mux.Router) error { // - in: query // name: filters // type: string - // description: needs description and plumbing for filters + // description: | + // JSON encoded value of the filters (a map[string][]string) to process on the pods list. Available filters: + // - `id=` Matches all of pod id. + // - `label=` or `label=:` Matches pods based on the presence of a label alone or a label and a value. + // - `name=` Matches all of pod name. + // - `until=` List pods created before this timestamp. The `` can be Unix timestamps, date formatted timestamps, or Go duration strings (e.g. `10m`, `1h30m`) computed relative to the daemon machine’s time. + // - `status=` Pod's status: `stopped`, `running`, `paused`, `exited`, `dead`, `created`, `degraded`. + // - `network=` Name or full ID of network. + // - `ctr-names=` Container name within the pod. + // - `ctr-ids=` Container ID within the pod. + // - `ctr-status=` Container status within the pod. + // - `ctr-number=` Number of containers in the pod. // responses: // 200: // $ref: "#/responses/ListPodsResponse" -- cgit v1.2.3-54-g00ecf