%PDF- %PDF-
Mini Shell

Mini Shell

Direktori : /lib/python2.7/site-packages/salt/modules/
Upload File :
Create Path :
Current File : //lib/python2.7/site-packages/salt/modules/ssh_service.pyo

�
���^c@@s�dZddlmZmZmZddlZddlZddlZddlZ	ej
e�Zidd6Z
dZd�Zd�Zd	�Zdd
�Zdd�Zdd�Zdd
�Zdd�Zdd�ZdS(uW
Provide the service module for the proxy-minion SSH sample
.. versionadded:: 2015.8.2
i(tabsolute_importtunicode_literalstprint_functionNulistulist_uservicecC@sSy.tjjj�r-tdddkr-tSWntk
rHtdfSXtdfS(u6
    Only work on systems that are a proxy minion
    uproxyu	proxytypeu
ssh_sampleuOThe ssh_service execution module failed to load. Check the proxy key in pillar.uZThe ssh_service execution module failed to load: only works on an ssh_sample proxy minion.(tsalttutilstplatformtis_proxyt__opts__t__virtualname__tKeyErrortFalse(((s</usr/lib/python2.7/site-packages/salt/modules/ssh_service.pyt__virtual__s
cC@sd}t|�S(u
    Return a list of all available services

    CLI Example:

    .. code-block:: bash

        salt '*' service.get_all
    ussh_sample.service_list(t	__proxy__(tproxy_fn((s</usr/lib/python2.7/site-packages/salt/modules/ssh_service.pytget_all/s
cC@st�S(u}
    Return a list of all available services.

    CLI Example:

    .. code-block:: bash

        salt '*' service.list
    (R(((s</usr/lib/python2.7/site-packages/salt/modules/ssh_service.pytlist_=s
cC@sd}t||�S(u�
    Start the specified service on the ssh_sample

    CLI Example:

    .. code-block:: bash

        salt '*' service.start <service name>
    ussh_sample.service_start(R(tnametsigR
((s</usr/lib/python2.7/site-packages/salt/modules/ssh_service.pytstartJscC@sd}t||�S(u�
    Stop the specified service on the rest_sample

    CLI Example:

    .. code-block:: bash

        salt '*' service.stop <service name>
    ussh_sample.service_stop(R(RRR
((s</usr/lib/python2.7/site-packages/salt/modules/ssh_service.pytstopYs
cC@sd}t||�S(u�
    Restart the specified service with rest_sample
    CLI Example:

    .. code-block:: bash

        salt '*' service.restart <service name>
    ussh_sample.service_restart(R(RRR
((s</usr/lib/python2.7/site-packages/salt/modules/ssh_service.pytrestartgs
cC@s�d}ttjd|��}|r<tjt�|�}n	|g}i}xE|D]=}t||�}|ddkr�t||<qRt||<qRW|r�|S||S(u<
    Return the status for a service via ssh_sample.
    If the name contains globbing, a dict mapping service name to True/False
    values is returned.

    .. versionchanged:: 2018.3.0
        The service name can now be a glob (e.g. ``salt*``)

    Args:
        name (str): The name of the service to check
        sig (str): Not implemented

    Returns:
        bool: True if running, False otherwise
        dict: Maps service name to True if running, False otherwise

    CLI Example:

    .. code-block:: bash

        salt '*' service.status <service name>
    ussh_sample.service_statusu\*|\?|\[.+\]ucommenturunning(	tbooltretsearchtfnmatchtfilterRRtTrueR
(RRR
tcontains_globbingtservicestresultstservicetresp((s</usr/lib/python2.7/site-packages/salt/modules/ssh_service.pytstatusus	

cC@st|�j|t�S(u1
    Return whether this service is running.
    (R tgetR
(RR((s</usr/lib/python2.7/site-packages/salt/modules/ssh_service.pytrunning�scC@s
|dkS(u=
    Only the 'redbull' service is 'enabled' in the test
    uredbull((RR((s</usr/lib/python2.7/site-packages/salt/modules/ssh_service.pytenabled�s(t__doc__t
__future__RRRtloggingRRtsalt.utils.platformRt	getLoggert__name__tlogt__func_alias__RRRRtNoneRRRR R"R#(((s</usr/lib/python2.7/site-packages/salt/modules/ssh_service.pyt<module>s$
			
*

Zerion Mini Shell 1.0