%PDF- %PDF-
Direktori : /usr/lib/python2.7/site-packages/salt/runners/ |
Current File : //usr/lib/python2.7/site-packages/salt/runners/sdb.pyo |
� ���^c @@ si d Z d d l m Z m Z m Z d d l Z i d d 6Z d � Z d � Z d � Z d d d � Z d S( uD Runner for setting and querying data via the sdb API on the master i ( t absolute_importt print_functiont unicode_literalsNu setu set_c C@ s t j j j | t t � S( u Get a value from a db, using a uri in the form of sdb://<profile>/<key>. If the uri provided does not start with sdb://, then it will be returned as-is. CLI Example: .. code-block:: bash salt-run sdb.get sdb://mymemcached/foo ( t saltt utilst sdbt sdb_gett __opts__t __utils__( t uri( ( s4 /usr/lib/python2.7/site-packages/salt/runners/sdb.pyt get s c C@ s t j j j | | t t � S( u' Set a value in a db, using a uri in the form of ``sdb://<profile>/<key>``. If the uri provided does not start with ``sdb://`` or the value is not successfully set, return ``False``. CLI Example: .. code-block:: bash salt-run sdb.set sdb://mymemcached/foo bar ( R R R t sdb_setR R ( R t value( ( s4 /usr/lib/python2.7/site-packages/salt/runners/sdb.pyt set_ s c C@ s t j j j | t t � S( u/ Delete a value from a db, using a uri in the form of ``sdb://<profile>/<key>``. If the uri provided does not start with ``sdb://`` or the value is not successfully deleted, return ``False``. CLI Example: .. code-block:: bash salt-run sdb.delete sdb://mymemcached/foo ( R R R t sdb_deleteR R ( R ( ( s4 /usr/lib/python2.7/site-packages/salt/runners/sdb.pyt delete- s i u2 abcdefghijklmnopqrstuvwxyz0123456789!@#$%^&*(-_=+)c C@ s t j j j | t | | t � S( u� Perform a one-time generation of a hash and write it to sdb. If that value has already been set return the value instead. This is useful for generating passwords or keys that are specific to multiple minions that need to be stored somewhere centrally. CLI Example: .. code-block:: bash salt-run sdb.get_or_set_hash 'SECRET_KEY' 50 .. warning:: This function could return strings which may contain characters which are reserved as directives by the YAML parser, such as strings beginning with ``%``. To avoid issues when using the output of this function in an SLS file containing YAML+Jinja, surround the call with single quotes. ( R R R t sdb_get_or_set_hashR R ( R t lengtht chars( ( s4 /usr/lib/python2.7/site-packages/salt/runners/sdb.pyt get_or_set_hash<