HEX
Server: Apache
System: Linux server2.voipitup.com.au 4.18.0-553.109.1.lve.el8.x86_64 #1 SMP Thu Mar 5 20:23:46 UTC 2026 x86_64
User: posscale (1027)
PHP: 8.2.30
Disabled: exec,passthru,shell_exec,system
Upload Files
File: //opt/saltstack/salt/lib/python3.10/site-packages/salt/proxy/__pycache__/chronos.cpython-310.pyc
o

�N�gs�@sPdZddlZddlZdgZiZdZe�e�Z	dd�Z
dd�Zd	d
�Zdd�Z
dS)
a�
Chronos
========

Proxy minion for managing a Chronos cluster.

Dependencies
------------

- :mod:`chronos execution module (salt.modules.chronos) <salt.modules.chronos>`

Pillar
------

The chronos proxy configuration requires a 'base_url' property that points to
the chronos endpoint:

.. code-block:: yaml

    proxy:
      proxytype: chronos
      base_url: http://my-chronos-master.mydomain.com:4400

.. versionadded:: 2015.8.2
�NZchronosZbase_urlcCsdS)NT�rrr�F/opt/saltstack/salt/lib/python3.10/site-packages/salt/proxy/chronos.py�__virtual__%srcCs:t|dvr|dttt<nt�dt�t�dt�dS)z#
    Perform any needed setup.
    �proxyzmissing proxy property %sz
CONFIG: %sN)�CONFIG_BASE_URL�CONFIG�log�error�debug��optsrrr�init)sr
c
Csxztjjjtt�d�ddd�}t�d|�d|vrWdSWd	Sty;}zt�	dtt|�WYd}~d	Sd}~ww)
z(
    Is the chronos api responding?
    z/scheduler/jobs�jsonT)Zdecode_type�decodez&chronos.info returned successfully: %s�dictz*error pinging chronos with base_url %s: %sNF)
�salt�utils�http�queryrrrr
�	Exceptionr	)�response�exrrr�ping4s.�������rcCst�d�dS)z,
    For this proxy shutdown is a no-op
    z"chronos proxy shutdown() called...N)rr
rrrr�shutdownMsr)�__doc__�loggingZsalt.utils.httprZ__proxyenabled__rr�	getLogger�__file__rrr
rrrrrr�<module>s