docker config
ConfigCLI
create
create(name, file, labels={}, template_driver=None)
Create a config from a file
See the docker docs for more information about swarm configs.
PARAMETER | DESCRIPTION |
---|---|
name |
The config name.
TYPE:
|
file |
Tbe file to be used as config.
TYPE:
|
labels |
The labels to add to the config
TYPE:
|
template_driver |
The template driver
TYPE:
|
Returns
A `python_on_whales.Config` object.
inspect
inspect(x)
Returns a python_on_whales.Config
object based on its name or id.
Argument
x: An id or name or a list of ids/names.
Returns
A `python_on_whales.Config` if a string was passed as argument. A
`List[python_on_whales.Config]` if a list of strings was passed as argument.
list
list(filters={})
List all config available in the swarm.
PARAMETER | DESCRIPTION |
---|---|
filters |
If you want to filter the results based on a given condition.
For example,
TYPE:
|
Returns
A `List[python_on_whales.Config]`.
remove
remove(x)
Remove one or more configs.
PARAMETER | DESCRIPTION |
---|---|
x |
One or a list of configs. Valid values are the id of the config or
a
TYPE:
|