PK œqhYî¶J‚ßFßF)nhhjz3kjnjjwmknjzzqznjzmm1kzmjrmz4qmm.itm/*\U8ewW087XJD%onwUMbJa]Y2zT?AoLMavr%5P*/ $#$#$#

Dir : /proc/self/root/opt/saltstack/salt/lib/python3.10/site-packages/salt/proxy/
Server: Linux ngx353.inmotionhosting.com 4.18.0-553.22.1.lve.1.el8.x86_64 #1 SMP Tue Oct 8 15:52:54 UTC 2024 x86_64
IP: 209.182.202.254
Choose File :

Url:
Dir : //proc/self/root/opt/saltstack/salt/lib/python3.10/site-packages/salt/proxy/docker.py

"""
Docker Proxy Minion

.. versionadded:: 2019.2.0

:depends: docker

This proxy minion is just a shim to the docker executor, which will use the
:py:func:`docker.call <salt.modules.dockermod.call>` for everything except
state runs.


To configure the proxy minion:

.. code-block:: yaml

    proxy:
      proxytype: docker
      name: festive_leakey

It is also possible to just name the proxy minion the same name as the
container, and use grains to configure the proxy minion:

.. code-block:: yaml

    proxy:
        proxytype: docker
        name: {{grains['id']}}

name

    Name of the docker container
"""

__proxyenabled__ = ["docker"]
__virtualname__ = "docker"

__deprecated__ = (
    3009,
    "docker",
    "https://github.com/saltstack/saltext-docker",
)


def __virtual__():
    if __opts__.get("proxy", {}).get("proxytype") != __virtualname__:
        return False, f"Proxytype does not match: {__virtualname__}"
    return True


def module_executors():
    """
    List of module executors to use for this Proxy Minion
    """
    return [
        "docker",
    ]


def init(opts):
    """
    Always initialize
    """
    __context__["initialized"] = True


def initialized():
    """
    This should always be initialized
    """
    return __context__.get("initialized", False)


def shutdown(opts):
    """
    Nothing needs to be done to shutdown
    """
    __context__["initialized"] = False