Skip to content

Commit 63b1557

Browse files
patrycja-guzikrhatdan
authored andcommitted
Unify podman prune filter description: volumes, networks, system
follow up of containers#12976 Signed-off-by: Patrycja Guzik <[email protected]>
1 parent 09589fc commit 63b1557

File tree

3 files changed

+32
-19
lines changed

3 files changed

+32
-19
lines changed

docs/source/markdown/podman-network-prune.1.md

+12-9
Original file line numberDiff line numberDiff line change
@@ -18,17 +18,20 @@ Do not prompt for confirmation
1818

1919
#### **--filter**
2020

21-
Filter output based on conditions given.
22-
Multiple filters can be given with multiple uses of the --filter option.
23-
Filters with the same key work inclusive with the only exception being
24-
`label` which is exclusive. Filters with different keys always work exclusive.
21+
Provide filter values.
2522

26-
Valid filters are listed below:
23+
The *filters* argument format is of `key=value`. If there is more than one *filter*, then pass multiple OPTIONS: **--filter** *foo=bar* **--filter** *bif=baz*.
2724

28-
| **Filter** | **Description** |
29-
| ---------- | ------------------------------------------------------------------------------------- |
30-
| label | [Key] or [Key=Value] Label assigned to a network |
31-
| until | only remove networks created before given timestamp |
25+
Supported filters:
26+
27+
| Filter | Description |
28+
| :----------------: | --------------------------------------------------------------------------- |
29+
| *until* | Only remove networks created before given timestamp. |
30+
| *label* | Only remove networks, with (or without, in the case of label!=[...] is used) the specified labels. |
31+
32+
The `until` *filter* can be Unix timestamps, date formatted timestamps, or Go duration strings (e.g. 10m, 1h30m) computed relative to the machine’s time.
33+
34+
The `label` *filter* accepts two formats. One is the `label`=*key* or `label`=*key*=*value*, which removes networks with the specified labels. The other format is the `label!`=*key* or `label!`=*key*=*value*, which removes networks without the specified labels.
3235

3336
## EXAMPLE
3437
Prune networks

docs/source/markdown/podman-system-prune.1.md

+7-5
Original file line numberDiff line numberDiff line change
@@ -22,16 +22,18 @@ Recursively remove all unused pod, container, image and volume data (Maximum 50
2222

2323
Provide filter values.
2424

25-
The --filter flag format is of key=value. If there is more than one filter, then pass multiple flags (e.g., --filter "foo=bar" --filter "bif=baz")
25+
The *filters* argument format is of `key=value`. If there is more than one *filter*, then pass multiple OPTIONS: **--filter** *foo=bar* **--filter** *bif=baz*.
2626

2727
Supported filters:
2828

29-
- `until` (_timestamp_) - only remove containers and images created before given timestamp
30-
- `label` (label=_key_, label=_key=value_, label!=_key_, or label!=_key=value_) - only remove containers and images, with (or without, in case label!=... is used) the specified labels.
29+
| Filter | Description |
30+
| :----------------: | --------------------------------------------------------------------------- |
31+
| *until* | Only remove containers and images created before given timestamp. |
32+
| *label* | Only remove containers and images, with (or without, in the case of label!=[...] is used) the specified labels. |
3133

32-
The until filter can be Unix timestamps, date formatted timestamps, or Go duration strings (e.g. 10m, 1h30m) computed relative to the machine’s time.
34+
The `until` *filter* can be Unix timestamps, date formatted timestamps, or Go duration strings (e.g. 10m, 1h30m) computed relative to the machine’s time.
3335

34-
The label filter accepts two formats. One is the label=... (label=_key_ or label=_key=value_), which removes containers and images with the specified labels. The other format is the label!=... (label!=_key_ or label!=_key=value_), which removes containers and images without the specified labels.
36+
The `label` *filter* accepts two formats. One is the `label`=*key* or `label`=*key*=*value*, which removes containers and images with the specified labels. The other format is the `label!`=*key* or `label!`=*key*=*value*, which removes containers and images without the specified labels.
3537

3638
#### **--force**, **-f**
3739

docs/source/markdown/podman-volume-prune.1.md

+13-5
Original file line numberDiff line numberDiff line change
@@ -21,12 +21,20 @@ Do not prompt for confirmation.
2121

2222
#### **--filter**
2323

24-
Filter volumes to be pruned. Volumes can be filtered by the following attributes:
24+
Provide filter values.
2525

26-
| **Filter** | **Description** |
27-
| ---------- | ------------------------------------------------------------------------------------- |
28-
| label | [Key] or [Key=Value] Label assigned to a volume |
29-
| until | Only remove volumes created before given timestamp |
26+
The *filters* argument format is of `key=value`. If there is more than one *filter*, then pass multiple OPTIONS: **--filter** *foo=bar* **--filter** *bif=baz*.
27+
28+
Supported filters:
29+
30+
| Filter | Description |
31+
| :----------------: | --------------------------------------------------------------------------- |
32+
| *until* | Only remove volumes created before given timestamp. |
33+
| *label* | Only remove volumes, with (or without, in the case of label!=[...] is used) the specified labels. |
34+
35+
The `until` *filter* can be Unix timestamps, date formatted timestamps, or Go duration strings (e.g. 10m, 1h30m) computed relative to the machine’s time.
36+
37+
The `label` *filter* accepts two formats. One is the `label`=*key* or `label`=*key*=*value*, which removes volumes with the specified labels. The other format is the `label!`=*key* or `label!`=*key*=*value*, which removes volumes without the specified labels.
3038

3139
#### **--help**
3240

0 commit comments

Comments
 (0)