class documentation
class SecretCollection(Collection): (source)
Secrets on the Docker server.
Method | create |
Undocumented |
Method | get |
Get a secret. |
Method | list |
List secrets. Similar to the ``docker secret ls`` command. |
Inherited from Collection
:
Method | __call__ |
Undocumented |
Method | __init__ |
Undocumented |
Method | prepare |
Create a model from a set of attributes. |
Class Variable | model |
Undocumented |
Instance Variable | client |
Undocumented |
overrides
docker.models.resource.Collection.get
Get a secret. Args: secret_id (str): Secret ID. Returns: (:py:class:`Secret`): The secret. Raises: :py:class:`docker.errors.NotFound` If the secret does not exist. :py:class:`docker.errors.APIError` If the server returns an error.
overrides
docker.models.resource.Collection.list
List secrets. Similar to the ``docker secret ls`` command. Args: filters (dict): Server-side list filtering options. Returns: (list of :py:class:`Secret`): The secrets. Raises: :py:class:`docker.errors.APIError` If the server returns an error.