Инструменты пользователя

Инструменты сайта


salt

Различия

Здесь показаны различия между двумя версиями данной страницы.

Ссылка на это сравнение

salt [2016/03/13 05:20] (текущий)
sander создано
Строка 1: Строка 1:
 +====== saltstack ======
  
 +<code bash>
 +salt '​*'​ sys.doc
 +</​code>​
 +
 +<code bash>
 +acl.delfacl:​
 +
 +    Remove specific FACL from the specified file(s)
 +
 +    CLI Examples:
 +
 +        salt '​*'​ acl.delfacl user myuser /​tmp/​house/​kitchen
 +        salt '​*'​ acl.delfacl default:​group mygroup /​tmp/​house/​kitchen
 +        salt '​*'​ acl.delfacl d:u myuser /​tmp/​house/​kitchen
 +        salt '​*'​ acl.delfacl g myuser /​tmp/​house/​kitchen /​tmp/​house/​livingroom
 +        salt '​*'​ acl.delfacl user myuser /​tmp/​house/​kitchen recursive=True
 +    ​
 +
 +acl.getfacl:​
 +
 +    Return (extremely verbose) map of FACLs on specified file(s)
 +
 +    CLI Examples:
 +
 +        salt '​*'​ acl.getfacl /​tmp/​house/​kitchen
 +        salt '​*'​ acl.getfacl /​tmp/​house/​kitchen /​tmp/​house/​livingroom
 +        salt '​*'​ acl.getfacl /​tmp/​house/​kitchen /​tmp/​house/​livingroom recursive=True
 +    ​
 +
 +acl.modfacl:​
 +
 +    Add or modify a FACL for the specified file(s)
 +
 +    CLI Examples:
 +
 +        salt '​*'​ acl.modfacl user myuser rwx /​tmp/​house/​kitchen
 +        salt '​*'​ acl.modfacl default:​group mygroup rx /​tmp/​house/​kitchen
 +        salt '​*'​ acl.modfacl d:u myuser 7 /​tmp/​house/​kitchen
 +        salt '​*'​ acl.modfacl g mygroup 0 /​tmp/​house/​kitchen /​tmp/​house/​livingroom
 +        salt '​*'​ acl.modfacl user myuser rwx /​tmp/​house/​kitchen recursive=True
 +    ​
 +
 +acl.version:​
 +
 +    Return facl version from getfacl --version
 +
 +    CLI Example:
 +
 +        salt '​*'​ acl.version
 +    ​
 +
 +acl.wipefacls:​
 +
 +    Remove all FACLs from the specified file(s)
 +
 +    CLI Examples:
 +
 +        salt '​*'​ acl.wipefacls /​tmp/​house/​kitchen
 +        salt '​*'​ acl.wipefacls /​tmp/​house/​kitchen /​tmp/​house/​livingroom
 +        salt '​*'​ acl.wipefacls /​tmp/​house/​kitchen /​tmp/​house/​livingroom recursive=True
 +    ​
 +
 +aliases.get_target:​
 +
 +    Return the target associated with an alias
 +
 +    CLI Example:
 +
 +        salt '​*'​ aliases.get_target alias
 +    ​
 +
 +aliases.has_target:​
 +
 +    Return true if the alias/​target is set
 +
 +    CLI Example:
 +
 +        salt '​*'​ aliases.has_target alias target
 +    ​
 +
 +aliases.list_aliases:​
 +
 +    Return the aliases found in the aliases file in this format::
 +
 +        {'​alias':​ '​target'​}
 +
 +    CLI Example:
 +
 +        salt '​*'​ aliases.list_aliases
 +    ​
 +
 +aliases.rm_alias:​
 +
 +    Remove an entry from the aliases file
 +
 +    CLI Example:
 +
 +        salt '​*'​ aliases.rm_alias alias
 +    ​
 +
 +aliases.set_target:​
 +
 +    Set the entry in the aliases file for the given alias, this will overwrite
 +    any previous entry for the given alias or create a new one if it does not
 +    exist.
 +
 +    CLI Example:
 +
 +        salt '​*'​ aliases.set_target alias target
 +    ​
 +
 +alternatives.auto:​
 +
 +    Trigger alternatives to set the path for <​name>​ as
 +    specified by priority.
 +
 +    CLI Example:
 +
 +        salt '​*'​ alternatives.auto name
 +    ​
 +
 +alternatives.check_exists:​
 +
 +    Check if the given path is an alternative for a name.
 +
 +    New in version 2015.8.4
 +
 +    CLI Example:
 +
 +        salt '​*'​ alternatives.check_exists name path
 +    ​
 +
 +alternatives.check_installed:​
 +
 +    Check if the current highest-priority match for a given alternatives link
 +    is set to the desired path
 +
 +    CLI Example:
 +
 +        salt '​*'​ alternatives.check_installed name path
 +    ​
 +
 +alternatives.display:​
 +
 +    Display alternatives settings for defined command name
 +
 +    CLI Example:
 +
 +        salt '​*'​ alternatives.display editor
 +    ​
 +
 +alternatives.install:​
 +
 +    Install symbolic links determining default commands
 +
 +    CLI Example:
 +
 +        salt '​*'​ alternatives.install editor /​usr/​bin/​editor /​usr/​bin/​emacs23 50
 +    ​
 +
 +alternatives.remove:​
 +
 +    Remove symbolic links determining the default commands.
 +
 +    CLI Example:
 +
 +        salt '​*'​ alternatives.remove name path
 +    ​
 +
 +alternatives.set:​
 +
 +    Manually set the alternative <​path>​ for <​name>​.
 +
 +    CLI Example:
 +
 +        salt '​*'​ alternatives.set name path
 +    ​
 +
 +alternatives.show_current:​
 +
 +    Display the current highest-priority alternative for a given alternatives
 +    link
 +
 +    CLI Example:
 +
 +        salt '​*'​ alternatives.show_current editor
 +    ​
 +
 +archive.cmd_unzip:​
 +
 +    New in version 2015.5.0
 +        In versions 2014.7.x and earlier, this function was known as
 +        ``archive.unzip``.
 +
 +    Uses the ``unzip`` command to unpack zip files. This command is part of the
 +    `Info-ZIP`_ suite of tools, and is typically packaged as simply ``unzip``.
 +
 +    .. _`Info-ZIP`:​ http://​www.info-zip.org/​
 +
 +    zip_file
 +        Path of zip file to be unpacked
 +
 +    dest
 +        The destination directory into which the file should be unpacked
 +
 +    excludes : None
 +        Comma-separated list of files not to unpack. Can also be passed in a
 +        Python list.
 +
 +    template : None
 +        Can be set to '​jinja'​ or another supported template engine to render
 +        the command arguments before execution:
 +
 +            salt '​*'​ archive.cmd_unzip template=jinja /​tmp/​zipfile.zip /​tmp/​{{grains.id}}/​ excludes=file_1,​file_2
 +
 +    options : None
 +        Additional command-line options to pass to the ``unzip`` binary.
 +
 +        Changed in version 2015.8.0
 +
 +            The mandatory `-` prefixing has been removed. ​ An options string
 +            beginning with a `--long-option`,​ would have uncharacteristically
 +            needed its first `-` removed under the former scheme.
 +
 +    runas : None
 +        Unpack the zip file as the specified user. Defaults to the user under
 +        which the minion is running.
 +
 +        New in version 2015.5.0
 +
 +    CLI Example:
 +
 +        salt '​*'​ archive.cmd_unzip /​tmp/​zipfile.zip /​home/​strongbad/​ excludes=file_1,​file_2
 +    ​
 +
 +archive.cmd_zip:​
 +
 +    New in version 2015.5.0
 +        In versions 2014.7.x and earlier, this function was known as
 +        ``archive.zip``.
 +
 +    Uses the ``zip`` command to create zip files. This command is part of the
 +    `Info-ZIP`_ suite of tools, and is typically packaged as simply ``zip``.
 +
 +    .. _`Info-ZIP`:​ http://​www.info-zip.org/​
 +
 +    zip_file
 +        Path of zip file to be created
 +
 +    sources
 +        Comma-separated list of sources to include in the zip file. Sources can
 +        also be passed in a Python list.
 +
 +    template : None
 +        Can be set to '​jinja'​ or another supported template engine to render
 +        the command arguments before execution:
 +
 +            salt '​*'​ archive.cmd_zip template=jinja /​tmp/​zipfile.zip /​tmp/​sourcefile1,/​tmp/​{{grains.id}}.txt
 +
 +    cwd : None
 +        Use this argument along with relative paths in ``sources`` to create
 +        zip files which do not contain the leading directories. If not
 +        specified, the zip file will be created as if the cwd was ``/``, and
 +        creating a zip file of ``/​foo/​bar/​baz.txt`` will contain the parent
 +        directories ``foo`` and ``bar``. To create a zip file containing just
 +        ``baz.txt``,​ the following command would be used:
 +
 +            salt '​*'​ archive.cmd_zip /​tmp/​baz.zip baz.txt cwd=/​foo/​bar
 +
 +        New in version 2014.7.1
 +
 +    runas : None
 +        Create the zip file as the specified user. Defaults to the user under
 +        which the minion is running.
 +
 +        New in version 2015.5.0
 +
 +
 +    CLI Example:
 +
 +        salt '​*'​ archive.cmd_zip /​tmp/​zipfile.zip /​tmp/​sourcefile1,/​tmp/​sourcefile2
 +    ​
 +
 +archive.gunzip:​
 +
 +    Uses the gunzip command to unpack gzip files
 +
 +    template : None
 +        Can be set to '​jinja'​ or another supported template engine to render
 +        the command arguments before execution:
 +
 +            salt '​*'​ archive.gunzip template=jinja /​tmp/​{{grains.id}}.txt.gz
 +
 +    CLI Example:
 +
 +        # Create /​tmp/​sourcefile.txt
 +        salt '​*'​ archive.gunzip /​tmp/​sourcefile.txt.gz
 +    ​
 +
 +archive.gzip:​
 +
 +    Uses the gzip command to create gzip files
 +
 +    template : None
 +        Can be set to '​jinja'​ or another supported template engine to render
 +        the command arguments before execution:
 +
 +            salt '​*'​ archive.gzip template=jinja /​tmp/​{{grains.id}}.txt
 +
 +    CLI Example:
 +
 +        # Create /​tmp/​sourcefile.txt.gz
 +        salt '​*'​ archive.gzip /​tmp/​sourcefile.txt
 +    ​
 +
 +archive.rar:​
 +
 +    Uses `rar for Linux`_ to create rar files
 +
 +    .. _`rar for Linux`: http://​www.rarlab.com/​
 +
 +    rarfile
 +        Path of rar file to be created
 +
 +    sources
 +        Comma-separated list of sources to include in the rar file. Sources can
 +        also be passed in a Python list.
 +
 +    cwd : None
 +        Run the rar command from the specified directory. Use this argument
 +        along with relative file paths to create rar files which do not
 +        contain the leading directories. If not specified, this will default
 +        to the home directory of the user under which the salt minion process
 +        is running.
 +
 +        New in version 2014.7.1
 +
 +    template : None
 +        Can be set to '​jinja'​ or another supported template engine to render
 +        the command arguments before execution:
 +
 +            salt '​*'​ archive.rar template=jinja /​tmp/​rarfile.rar '/​tmp/​sourcefile1,/​tmp/​{{grains.id}}.txt'​
 +
 +    CLI Example:
 +
 +        salt '​*'​ archive.rar /​tmp/​rarfile.rar /​tmp/​sourcefile1,/​tmp/​sourcefile2
 +    ​
 +
 +archive.tar:​
 +
 +    Note:
 +
 +        This function has changed for version 0.17.0. In prior versions, the
 +        ``cwd`` and ``template`` arguments must be specified, with the source
 +        directories/​files coming as a space-separated list at the end of the
 +        command. Beginning with 0.17.0, ``sources`` must be a comma-separated
 +        list, and the ``cwd`` and ``template`` arguments are optional.
 +
 +    Uses the tar command to pack, unpack, etc. tar files
 +
 +
 +    options
 +        Options to pass to the tar command
 +
 +        Changed in version 2015.8.0
 +
 +            The mandatory `-` prefixing has been removed. ​ An options string
 +            beginning with a `--long-option`,​ would have uncharacteristically
 +            needed its first `-` removed under the former scheme.
 +
 +            Also, tar will parse its options differently if short options are
 +            used with or without a preceding `-`, so it is better to not
 +            confuse the user into thinking they'​re using the non-`-` format,
 +            when really they are using the with-`-` format.
 +
 +    tarfile
 +        The filename of the tar archive to pack/unpack
 +
 +    sources
 +        Comma delimited list of files to **pack** into the tarfile. Can also be
 +        passed as a Python list.
 +
 +    dest
 +        The destination directory into which to **unpack** the tarfile
 +
 +    cwd : None
 +        The directory in which the tar command should be executed. If not
 +        specified, will default to the home directory of the user under which
 +        the salt minion process is running.
 +
 +    template : None
 +        Can be set to '​jinja'​ or another supported template engine to render
 +        the command arguments before execution:
 +
 +            salt '​*'​ archive.tar -cjvf /​tmp/​salt.tar.bz2 {{grains.saltpath}} template=jinja
 +
 +    CLI Examples:
 +
 +        # Create a tarfile
 +        salt '​*'​ archive.tar -cjvf /​tmp/​tarfile.tar.bz2 /​tmp/​file_1,/​tmp/​file_2
 +        # Unpack a tarfile
 +        salt '​*'​ archive.tar xf foo.tar dest=/​target/​directory
 +    ​
 +
 +archive.unrar:​
 +
 +    Uses `rar for Linux`_ to unpack rar files
 +
 +    .. _`rar for Linux`: http://​www.rarlab.com/​
 +
 +    rarfile
 +        Name of rar file to be unpacked
 +
 +    dest
 +        The destination directory into which to **unpack** the rar file
 +
 +    template : None
 +        Can be set to '​jinja'​ or another supported template engine to render
 +        the command arguments before execution:
 +
 +            salt '​*'​ archive.unrar template=jinja /​tmp/​rarfile.rar /​tmp/​{{grains.id}}/​ excludes=file_1,​file_2
 +
 +    CLI Example:
 +
 +        salt '​*'​ archive.unrar /​tmp/​rarfile.rar /​home/​strongbad/​ excludes=file_1,​file_2
 +
 +    ​
 +
 +archive.unzip:​
 +
 +    New in version 2015.5.0
 +        In versions 2014.7.x and earlier, this function was known as
 +        ``archive.unzip``.
 +
 +    Uses the ``unzip`` command to unpack zip files. This command is part of the
 +    `Info-ZIP`_ suite of tools, and is typically packaged as simply ``unzip``.
 +
 +    .. _`Info-ZIP`:​ http://​www.info-zip.org/​
 +
 +    zip_file
 +        Path of zip file to be unpacked
 +
 +    dest
 +        The destination directory into which the file should be unpacked
 +
 +    excludes : None
 +        Comma-separated list of files not to unpack. Can also be passed in a
 +        Python list.
 +
 +    template : None
 +        Can be set to '​jinja'​ or another supported template engine to render
 +        the command arguments before execution:
 +
 +            salt '​*'​ archive.cmd_unzip template=jinja /​tmp/​zipfile.zip /​tmp/​{{grains.id}}/​ excludes=file_1,​file_2
 +
 +    options : None
 +        Additional command-line options to pass to the ``unzip`` binary.
 +
 +        Changed in version 2015.8.0
 +
 +            The mandatory `-` prefixing has been removed. ​ An options string
 +            beginning with a `--long-option`,​ would have uncharacteristically
 +            needed its first `-` removed under the former scheme.
 +
 +    runas : None
 +        Unpack the zip file as the specified user. Defaults to the user under
 +        which the minion is running.
 +
 +        New in version 2015.5.0
 +
 +    CLI Example:
 +
 +        salt '​*'​ archive.cmd_unzip /​tmp/​zipfile.zip /​home/​strongbad/​ excludes=file_1,​file_2
 +    ​
 +
 +archive.zip:​
 +
 +    New in version 2015.5.0
 +        In versions 2014.7.x and earlier, this function was known as
 +        ``archive.zip``.
 +
 +    Uses the ``zip`` command to create zip files. This command is part of the
 +    `Info-ZIP`_ suite of tools, and is typically packaged as simply ``zip``.
 +
 +    .. _`Info-ZIP`:​ http://​www.info-zip.org/​
 +
 +    zip_file
 +        Path of zip file to be created
 +
 +    sources
 +        Comma-separated list of sources to include in the zip file. Sources can
 +        also be passed in a Python list.
 +
 +    template : None
 +        Can be set to '​jinja'​ or another supported template engine to render
 +        the command arguments before execution:
 +
 +            salt '​*'​ archive.cmd_zip template=jinja /​tmp/​zipfile.zip /​tmp/​sourcefile1,/​tmp/​{{grains.id}}.txt
 +
 +    cwd : None
 +        Use this argument along with relative paths in ``sources`` to create
 +        zip files which do not contain the leading directories. If not
 +        specified, the zip file will be created as if the cwd was ``/``, and
 +        creating a zip file of ``/​foo/​bar/​baz.txt`` will contain the parent
 +        directories ``foo`` and ``bar``. To create a zip file containing just
 +        ``baz.txt``,​ the following command would be used:
 +
 +            salt '​*'​ archive.cmd_zip /​tmp/​baz.zip baz.txt cwd=/​foo/​bar
 +
 +        New in version 2014.7.1
 +
 +    runas : None
 +        Create the zip file as the specified user. Defaults to the user under
 +        which the minion is running.
 +
 +        New in version 2015.5.0
 +
 +
 +    CLI Example:
 +
 +        salt '​*'​ archive.cmd_zip /​tmp/​zipfile.zip /​tmp/​sourcefile1,/​tmp/​sourcefile2
 +    ​
 +
 +artifactory.get_latest_snapshot:​
 +
 +       Gets latest snapshot of the given artifact
 +
 +       ​artifactory_url
 +           URL of artifactory instance
 +       ​repository
 +           ​Snapshot repository in artifactory to retrieve artifact from, for example: libs-snapshots
 +       ​group_id
 +           Group Id of the artifact
 +       ​artifact_id
 +           ​Artifact Id of the artifact
 +       ​packaging
 +           ​Packaging type (jar,​war,​ear,​etc)
 +       ​target_dir
 +           ​Target directory to download artifact to (default: /tmp)
 +       ​target_file
 +           ​Target file to download artifact to (by default it is target_dir/​artifact_id-snapshot_version.packaging)
 +       ​classifier
 +           ​Artifact classifier name (ex: sources,​javadoc,​etc). Optional parameter.
 +       ​username
 +           ​Artifactory username. Optional parameter.
 +       ​password
 +           ​Artifactory password. Optional parameter.
 +       
 +
 +artifactory.get_release:​
 +
 +       Gets the specified release of the artifact
 +
 +       ​artifactory_url
 +           URL of artifactory instance
 +       ​repository
 +           ​Release repository in artifactory to retrieve artifact from, for example: libs-releases
 +       ​group_id
 +           Group Id of the artifact
 +       ​artifact_id
 +           ​Artifact Id of the artifact
 +       ​packaging
 +           ​Packaging type (jar,​war,​ear,​etc)
 +       ​version
 +           ​Version of the artifact
 +       ​target_dir
 +           ​Target directory to download artifact to (default: /tmp)
 +       ​target_file
 +           ​Target file to download artifact to (by default it is target_dir/​artifact_id-version.packaging)
 +       ​classifier
 +           ​Artifact classifier name (ex: sources,​javadoc,​etc). Optional parameter.
 +       ​username
 +           ​Artifactory username. Optional parameter.
 +       ​password
 +           ​Artifactory password. Optional parameter.
 +       
 +
 +artifactory.get_snapshot:​
 +
 +       Gets snapshot of the desired version of the artifact
 +
 +       ​artifactory_url
 +           URL of artifactory instance
 +       ​repository
 +           ​Snapshot repository in artifactory to retrieve artifact from, for example: libs-snapshots
 +       ​group_id
 +           Group Id of the artifact
 +       ​artifact_id
 +           ​Artifact Id of the artifact
 +       ​packaging
 +           ​Packaging type (jar,​war,​ear,​etc)
 +       ​version
 +           ​Version of the artifact
 +       ​target_dir
 +           ​Target directory to download artifact to (default: /tmp)
 +       ​target_file
 +           ​Target file to download artifact to (by default it is target_dir/​artifact_id-snapshot_version.packaging)
 +       ​classifier
 +           ​Artifact classifier name (ex: sources,​javadoc,​etc). Optional parameter.
 +       ​username
 +           ​Artifactory username. Optional parameter.
 +       ​password
 +           ​Artifactory password. Optional parameter.
 +       
 +
 +beacons.add:​
 +
 +    Add a beacon on the minion
 +
 +    :param name:            Name of the beacon to configure
 +    :param beacon_data: ​    ​Dictionary or list containing configuration for beacon.
 +    :​return: ​               Boolean and status message on success or failure of add.
 +
 +    CLI Example:
 +
 +        salt '​*'​ beacons.add ps "​{'​salt-master':​ '​stopped',​ '​apache2':​ '​stopped'​}"​
 +
 +    ​
 +
 +beacons.delete:​
 +
 +    Delete a beacon item
 +
 +    :param name:            Name of the beacon to delete
 +    :​return: ​               Boolean and status message on success or failure of delete.
 +
 +    CLI Example:
 +
 +        salt '​*'​ beacons.delete ps
 +
 +        salt '​*'​ beacons.delete load
 +
 +    ​
 +
 +beacons.disable:​
 +
 +    Disable all beaconsd jobs on the minion
 +
 +    :​return: ​               Boolean and status message on success or failure of disable.
 +
 +    CLI Example:
 +
 +        salt '​*'​ beacons.disable
 +    ​
 +
 +beacons.disable_beacon:​
 +
 +    Disable beacon on the minion
 +
 +    :​name: ​                 Name of the beacon to disable.
 +    :​return: ​               Boolean and status message on success or failure of disable.
 +
 +    CLI Example:
 +
 +        salt '​*'​ beacons.disable_beacon ps
 +    ​
 +
 +beacons.enable:​
 +
 +    Enable all beacons on the minion
 +
 +    :​return: ​               Boolean and status message on success or failure of enable.
 +
 +    CLI Example:
 +
 +        salt '​*'​ beacons.enable
 +    ​
 +
 +beacons.enable_beacon:​
 +
 +    Enable beacon on the minion
 +
 +    :​name: ​                 Name of the beacon to enable.
 +    :​return: ​               Boolean and status message on success or failure of enable.
 +
 +    CLI Example:
 +
 +        salt '​*'​ beacons.enable_beacon ps
 +    ​
 +
 +beacons.list:​
 +
 +    List the beacons currently configured on the minion
 +
 +    :param return_yaml: ​    ​Whether to return YAML formatted output, default True
 +    :​return: ​               List of currently configured Beacons.
 +
 +    CLI Example:
 +
 +        salt '​*'​ beacons.list
 +
 +    ​
 +
 +beacons.modify:​
 +
 +    Modify an existing beacon
 +
 +    :param name:            Name of the beacon to configure
 +    :param beacon_data: ​    ​Dictionary or list containing updated configuration for beacon.
 +    :​return: ​               Boolean and status message on success or failure of modify.
 +
 +    CLI Example:
 +
 +        salt '​*'​ beacon.modify ps "​{'​salt-master':​ '​stopped',​ '​apache2':​ '​stopped'​}"​
 +    ​
 +
 +beacons.save:​
 +
 +    Save all beacons on the minion
 +
 +    :​return: ​               Boolean and status message on success or failure of save.
 +
 +    CLI Example:
 +
 +        salt '​*'​ beacons.save
 +    ​
 +
 +bigip.add_pool_member:​
 +
 +    A function to connect to a bigip device and add a new member to an existing pool.
 +
 +    hostname
 +        The host/​address of the bigip device
 +    username
 +        The iControl REST username
 +    password
 +        The iControl REST password
 +    name
 +        The name of the pool to modify
 +    member
 +        The name of the member to add
 +        i.e. 10.1.1.2:80
 +
 +    CLI Example:
 +
 +        salt '​*'​ bigip.add_pool_members bigip admin admin my-pool 10.2.2.1:80
 +    ​
 +
 +bigip.commit_transaction:​
 +
 +    A function to connect to a bigip device and commit an existing transaction.
 +
 +    hostname
 +        The host/​address of the bigip device
 +    username
 +        The iControl REST username
 +    password
 +        The iControl REST password
 +    label
 +        the label of this transaction stored within the grain:
 +        ``bigip_f5_trans:<​label>​``
 +
 +    CLI Example::
 +
 +        salt '​*'​ bigip.commit_transaction bigip admin admin my_transaction
 +    ​
 +
 +bigip.create_monitor:​
 +
 +    A function to connect to a bigip device and create a monitor.
 +
 +    hostname
 +        The host/​address of the bigip device
 +    username
 +        The iControl REST username
 +    password
 +        The iControl REST password
 +    monitor_type
 +        The type of monitor to create
 +    name
 +        The name of the monitor to create
 +    kwargs
 +        Consult F5 BIGIP user guide for specific options for each monitor type.
 +        Typically, tmsh arg names are used.
 +
 +    CLI Example::
 +
 +        salt '​*'​ bigip.create_monitor bigip admin admin http my-http-monitor timeout=10 interval=5
 +    ​
 +
 +bigip.create_node:​
 +
 +    A function to connect to a bigip device and create a node.
 +
 +    hostname
 +        The host/​address of the bigip device
 +    username
 +        The iControl REST username
 +    password
 +        The iControl REST password
 +    name
 +        The name of the node
 +    address
 +        The address of the node
 +    trans_label
 +        The label of the transaction stored within the grain:
 +        ``bigip_f5_trans:<​label>​``
 +
 +    CLI Example::
 +
 +        salt '​*'​ bigip.create_node bigip admin admin 10.1.1.2
 +    ​
 +
 +bigip.create_pool:​
 +
 +    A function to connect to a bigip device and create a pool.
 +
 +    hostname
 +        The host/​address of the bigip device
 +    username
 +        The iControl REST username
 +    password
 +        The iControl REST password
 +    name
 +        The name of the pool to create.
 +    members
 +        List of comma delimited pool members to add to the pool.
 +        i.e. 10.1.1.1:​80,​10.1.1.2:​80,​10.1.1.3:​80
 +    allow_nat
 +        [yes | no]
 +    allow_snat
 +        [yes | no]
 +    description
 +        [string]
 +    gateway_failsafe_device
 +        [string]
 +    ignore_persisted_weight
 +        [enabled | disabled]
 +    ip_tos_to_client
 +        [pass-through | [integer]]
 +    ip_tos_to_server
 +        [pass-through | [integer]]
 +    link_qos_to_client
 +        [pass-through | [integer]]
 +    link_qos_to_server
 +        [pass-through | [integer]]
 +    load_balancing_mode
 +        [dynamic-ratio-member | dynamic-ratio-node |
 +        fastest-app-response | fastest-node |
 +        least-connections-members |
 +        least-connections-node |
 +        least-sessions |
 +        observed-member | observed-node |
 +        predictive-member | predictive-node |
 +        ratio-least-connections-member |
 +        ratio-least-connections-node |
 +        ratio-member | ratio-node | ratio-session |
 +        round-robin | weighted-least-connections-member |
 +        weighted-least-connections-node]
 +    min_active_members
 +        [integer]
 +    min_up_members
 +        [integer]
 +    min_up_members_action
 +        [failover | reboot | restart-all]
 +    min_up_members_checking
 +        [enabled | disabled]
 +    monitor
 +        [name]
 +    profiles
 +        [none | profile_name]
 +    queue_depth_limit
 +        [integer]
 +    queue_on_connection_limit
 +        [enabled | disabled]
 +    queue_time_limit
 +        [integer]
 +    reselect_tries
 +        [integer]
 +    service_down_action
 +        [drop | none | reselect | reset]
 +    slow_ramp_time
 +        [integer]
 +
 +    CLI Example::
 +
 +        salt '​*'​ bigip.create_pool bigip admin admin my-pool 10.1.1.1:​80,​10.1.1.2:​80,​10.1.1.3:​80 monitor=http
 +    ​
 +
 +bigip.create_profile:​
 +
 +    A function to connect to a bigip device and create a profile.
 +
 +    hostname
 +        The host/​address of the bigip device
 +    username
 +        The iControl REST username
 +    password
 +        The iControl REST password
 +    profile_type
 +        The type of profile to create
 +    name
 +        The name of the profile to create
 +    kwargs
 +        ``[ arg=val ] ... [arg=key1:​val1,​key2:​val2] ...``
 +
 +        Consult F5 BIGIP user guide for specific options for each monitor type.
 +        Typically, tmsh arg names are used.
 +
 +    Creating Complex Args
 +        Profiles can get pretty complicated in terms of the amount of possible
 +        config options. Use the following shorthand to create complex arguments such
 +        as lists, dictionaries,​ and lists of dictionaries. An option is also
 +        provided to pass raw json as well.
 +
 +        lists ``[i,​i,​i]``:​
 +            ``param='​item1,​item2,​item3'​``
 +
 +        Dictionary ``[k:​v,​k:​v,​k,​v]``:​
 +            ``param='​key-1:​val-1,​key-2:​val2,​key-3:​va-3'​``
 +
 +        List of Dictionaries ``[k:​v,​k:​v|k:​v,​k:​v|k:​v,​k:​v]``:​
 +           ​``param='​key-1:​val-1,​key-2:​val-2|key-1:​val-1,​key-2:​val-2|key-1:​val-1,​key-2:​val-2'​``
 +
 +        JSON: ``'j{ ... }j'``:
 +           ​``cert-key-chain='​j{ "​default":​ { "​cert":​ "​default.crt",​ "​chain":​ "​default.crt",​ "​key":​ "​default.key"​ } }j'``
 +
 +        Escaping Delimiters:
 +            Use ``\,`` or ``\:`` or ``\|`` to escape characters which shouldn'​t
 +            be treated as delimiters i.e. ``ciphers='​DEFAULT\:​!SSLv3'​``
 +
 +    CLI Examples::
 +
 +        salt '​*'​ bigip.create_profile bigip admin admin http my-http-profile defaultsFrom='/​Common/​http'​
 +        salt '​*'​ bigip.create_profile bigip admin admin http my-http-profile defaultsFrom='/​Common/​http'​ \
 +            enforcement=maxHeaderCount:​3200,​maxRequests:​10
 +
 +    ​
 +
 +bigip.create_virtual:​
 +
 +    A function to connect to a bigip device and create a virtual server.
 +
 +    hostname
 +        The host/​address of the bigip device
 +    username
 +        The iControl REST username
 +    password
 +        The iControl REST password
 +    name
 +        The name of the virtual to create
 +    destination
 +        [ [virtual_address_name:​port] | [ipv4:port] | [ipv6.port] ]
 +    pool
 +        [ [pool_name] | none]
 +    address_status
 +        [yes | no]
 +    auto_lasthop
 +        [default | enabled | disabled ]
 +    bwc_policy
 +        [none] | string]
 +    cmp_enabled
 +        [yes | no]
 +    dhcp_relay
 +        [yes | no]
 +    connection_limit
 +        [integer]
 +    description
 +        [string]
 +    state
 +        [disabled | enabled]
 +    fallback_persistence
 +        [none | [profile name] ]
 +    flow_eviction_policy
 +        [none | [eviction policy name] ]
 +    gtm_score
 +        [integer]
 +    ip_forward
 +        [yes | no]
 +    ip_protocol
 +        [any | protocol]
 +    internal
 +        [yes | no]
 +    twelve_forward
 +        (12-forward)
 +        [yes | no]
 +    last_hop-pool
 +        [ [pool_name] | none]
 +    mask
 +        { [ipv4] | [ipv6] }
 +    mirror
 +        { [disabled | enabled | none] }
 +    nat64
 +        [enabled | disabled]
 +    persist
 +        [none | profile1,​profile2,​profile3 ... ]
 +    profiles
 +        [none | default | profile1,​profile2,​profile3 ... ]
 +    policies
 +        [none | default | policy1,​policy2,​policy3 ... ]
 +    rate_class
 +        [name]
 +    rate_limit
 +        [integer]
 +    rate_limit_mode
 +        [destination | object | object-destination |
 +        object-source | object-source-destination |
 +        source | source-destination]
 +    rate_limit_dst
 +        [integer]
 +    rate_limitçsrc
 +        [integer]
 +    rules
 +        [none | [rule_one,​rule_two ...] ]
 +    related_rules
 +        [none | [rule_one,​rule_two ...] ]
 +    reject
 +        [yes | no]
 +    source
 +        { [ipv4[/​prefixlen]] | [ipv6[/​prefixlen]] }
 +    source_address_translation
 +        [none | snat:​pool_name | lsn | automap ]
 +    source_port
 +        [change | preserve | preserve-strict]
 +    state
 +        [enabled | disabled]
 +    traffic_classes
 +        [none | default | class_one,​class_two ... ]
 +    translate_address
 +        [enabled | disabled]
 +    translate_port
 +        [enabled | disabled]
 +    vlans
 +        [none | default | [enabled|disabled]:​vlan1,​vlan2,​vlan3 ... ]
 +
 +    CLI Examples::
 +
 +        salt '​*'​ bigip.create_virtual bigip admin admin my-virtual-3 26.2.2.5:80 \
 +            pool=my-http-pool-http profiles=http,​tcp
 +
 +        salt '​*'​ bigip.create_virtual bigip admin admin my-virtual-3 43.2.2.5:80 \
 +            pool=test-http-pool-http profiles=http,​websecurity persist=cookie,​hash \
 +            policies=asm_auto_l7_policy__http-virtual \
 +            rules=_sys_APM_ExchangeSupport_helper,​_sys_https_redirect \
 +            related_rules=_sys_APM_activesync,​_sys_APM_ExchangeSupport_helper \
 +            source_address_translation=snat:​my-snat-pool \
 +            translate_address=enabled translate_port=enabled \
 +            traffic_classes=my-class,​other-class \
 +            vlans=enabled:​external,​internal
 +
 +    ​
 +
 +bigip.delete_monitor:​
 +
 +    A function to connect to a bigip device and delete an existing monitor.
 +
 +    hostname
 +        The host/​address of the bigip device
 +    username
 +        The iControl REST username
 +    password
 +        The iControl REST password
 +    monitor_type
 +        The type of monitor to delete
 +    name
 +        The name of the monitor to delete
 +
 +    CLI Example::
 +
 +        salt '​*'​ bigip.delete_monitor bigip admin admin http my-http-monitor
 +
 +    ​
 +
 +bigip.delete_node:​
 +
 +    A function to connect to a bigip device and delete a specific node.
 +
 +    hostname
 +        The host/​address of the bigip device
 +    username
 +        The iControl REST username
 +    password
 +        The iControl REST password
 +    name
 +        The name of the node which will be deleted.
 +    trans_label
 +        The label of the transaction stored within the grain:
 +        ``bigip_f5_trans:<​label>​``
 +
 +    CLI Example::
 +
 +        salt '​*'​ bigip.delete_node bigip admin admin my-node
 +    ​
 +
 +bigip.delete_pool:​
 +
 +    A function to connect to a bigip device and delete a specific pool.
 +
 +    hostname
 +        The host/​address of the bigip device
 +    username
 +        The iControl REST username
 +    password
 +        The iControl REST password
 +    name
 +        The name of the pool which will be deleted
 +
 +    CLI Example::
 +
 +        salt '​*'​ bigip.delete_node bigip admin admin my-pool
 +    ​
 +
 +bigip.delete_pool_member:​
 +
 +    A function to connect to a bigip device and delete a specific pool.
 +
 +    hostname
 +        The host/​address of the bigip device
 +    username
 +        The iControl REST username
 +    password
 +        The iControl REST password
 +    name
 +        The name of the pool to modify
 +    member
 +        The name of the pool member to delete
 +
 +    CLI Example::
 +
 +        salt '​*'​ bigip.delete_node bigip admin admin my-pool 10.2.2.2:80
 +    ​
 +
 +bigip.delete_profile:​
 +
 +    A function to connect to a bigip device and delete an existing profile.
 +
 +    hostname
 +        The host/​address of the bigip device
 +    username
 +        The iControl REST username
 +    password
 +        The iControl REST password
 +    profile_type
 +        The type of profile to delete
 +    name
 +        The name of the profile to delete
 +
 +    CLI Example::
 +
 +        salt '​*'​ bigip.delete_profile bigip admin admin http my-http-profile
 +
 +    ​
 +
 +bigip.delete_transaction:​
 +
 +    A function to connect to a bigip device and delete an existing transaction.
 +
 +    hostname
 +        The host/​address of the bigip device
 +    username
 +        The iControl REST username
 +    password
 +        The iControl REST password
 +    label
 +        The label of this transaction stored within the grain:
 +        ``bigip_f5_trans:<​label>​``
 +
 +    CLI Example::
 +
 +        salt '​*'​ bigip.delete_transaction bigip admin admin my_transaction
 +    ​
 +
 +bigip.delete_virtual:​
 +
 +    A function to connect to a bigip device and delete a specific virtual.
 +
 +    hostname
 +        The host/​address of the bigip device
 +    username
 +        The iControl REST username
 +    password
 +        The iControl REST password
 +    name
 +        The name of the virtual to delete
 +
 +    CLI Example::
 +
 +        salt '​*'​ bigip.delete_virtual bigip admin admin my-virtual
 +    ​
 +
 +bigip.list_monitor:​
 +
 +    A function to connect to a bigip device and list an existing monitor. ​ If no name is provided than all
 +    monitors of the specified type will be listed.
 +
 +    hostname
 +        The host/​address of the bigip device
 +    username
 +        The iControl REST username
 +    password
 +        The iControl REST password
 +    monitor_type
 +        The type of monitor(s) to list
 +    name
 +        The name of the monitor to list
 +
 +    CLI Example::
 +
 +        salt '​*'​ bigip.list_monitor bigip admin admin http my-http-monitor
 +
 +    ​
 +
 +bigip.list_node:​
 +
 +    A function to connect to a bigip device and list all nodes or a specific node.
 +
 +
 +    hostname
 +        The host/​address of the bigip device
 +    username
 +        The iControl REST username
 +    password
 +        The iControl REST password
 +    name
 +        The name of the node to list. If no name is specified than all nodes
 +        will be listed.
 +    trans_label
 +        The label of the transaction stored within the grain:
 +        ``bigip_f5_trans:<​label>​``
 +
 +    CLI Example::
 +
 +        salt '​*'​ bigip.list_node bigip admin admin my-node
 +    ​
 +
 +bigip.list_pool:​
 +
 +    A function to connect to a bigip device and list all pools or a specific pool.
 +
 +    hostname
 +        The host/​address of the bigip device
 +    username
 +        The iControl REST username
 +    password
 +        The iControl REST password
 +    name
 +        The name of the pool to list. If no name is specified then all pools
 +        will be listed.
 +
 +    CLI Example::
 +
 +        salt '​*'​ bigip.list_pool bigip admin admin my-pool
 +    ​
 +
 +bigip.list_profile:​
 +
 +    A function to connect to a bigip device and list an existing profile. ​ If no name is provided than all
 +    profiles of the specified type will be listed.
 +
 +    hostname
 +        The host/​address of the bigip device
 +    username
 +        The iControl REST username
 +    password
 +        The iControl REST password
 +    profile_type
 +        The type of profile(s) to list
 +    name
 +        The name of the profile to list
 +
 +    CLI Example::
 +
 +        salt '​*'​ bigip.list_profile bigip admin admin http my-http-profile
 +
 +    ​
 +
 +bigip.list_transaction:​
 +
 +    A function to connect to a bigip device and list an existing transaction.
 +
 +    hostname
 +        The host/​address of the bigip device
 +    username
 +        The iControl REST username
 +    password
 +        The iControl REST password
 +    label
 +        the label of this transaction stored within the grain:
 +        ``bigip_f5_trans:<​label>​``
 +
 +    CLI Example::
 +
 +        salt '​*'​ bigip.list_transaction bigip admin admin my_transaction
 +
 +    ​
 +
 +bigip.list_virtual:​
 +
 +    A function to connect to a bigip device and list all virtuals or a specific virtual.
 +
 +    hostname
 +        The host/​address of the bigip device
 +    username
 +        The iControl REST username
 +    password
 +        The iControl REST password
 +    name
 +        The name of the virtual to list. If no name is specified than all
 +        virtuals will be listed.
 +
 +    CLI Example::
 +
 +        salt '​*'​ bigip.list_virtual bigip admin admin my-virtual
 +    ​
 +
 +bigip.modify_monitor:​
 +
 +    A function to connect to a bigip device and modify an existing monitor.
 +
 +    hostname
 +        The host/​address of the bigip device
 +    username
 +        The iControl REST username
 +    password
 +        The iControl REST password
 +    monitor_type
 +        The type of monitor to modify
 +    name
 +        The name of the monitor to modify
 +    kwargs
 +        Consult F5 BIGIP user guide for specific options for each monitor type.
 +        Typically, tmsh arg names are used.
 +
 +    CLI Example::
 +
 +        salt '​*'​ bigip.modify_monitor bigip admin admin http my-http-monitor ​ timout=16 interval=6
 +
 +    ​
 +
 +bigip.modify_node:​
 +
 +    A function to connect to a bigip device and modify an existing node.
 +
 +    hostname
 +        The host/​address of the bigip device
 +    username
 +        The iControl REST username
 +    password
 +        The iControl REST password
 +    name
 +        The name of the node to modify
 +    connection_limit
 +        [integer]
 +    description
 +        [string]
 +    dynamic_ratio
 +        [integer]
 +    logging
 +        [enabled | disabled]
 +    monitor
 +        [[name] | none | default]
 +    rate_limit
 +        [integer]
 +    ratio
 +        [integer]
 +    session
 +        [user-enabled | user-disabled]
 +    state
 +        [user-down | user-up ]
 +    trans_label
 +        The label of the transaction stored within the grain:
 +        ``bigip_f5_trans:<​label>​``
 +
 +    CLI Example::
 +
 +        salt '​*'​ bigip.modify_node bigip admin admin 10.1.1.2 ratio=2 logging=enabled
 +    ​
 +
 +bigip.modify_pool:​
 +
 +    A function to connect to a bigip device and modify an existing pool.
 +
 +    hostname
 +        The host/​address of the bigip device
 +    username
 +        The iControl REST username
 +    password
 +        The iControl REST password
 +    name
 +        The name of the pool to modify.
 +    allow_nat
 +        [yes | no]
 +    allow_snat
 +        [yes | no]
 +    description
 +        [string]
 +    gateway_failsafe_device
 +        [string]
 +    ignore_persisted_weight
 +        [yes | no]
 +    ip_tos_to_client
 +        [pass-through | [integer]]
 +    ip_tos_to_server
 +        [pass-through | [integer]]
 +    link_qos_to_client
 +        [pass-through | [integer]]
 +    link_qos_to_server
 +        [pass-through | [integer]]
 +    load_balancing_mode
 +        [dynamic-ratio-member | dynamic-ratio-node |
 +        fastest-app-response | fastest-node |
 +        least-connections-members |
 +        least-connections-node |
 +        least-sessions |
 +        observed-member | observed-node |
 +        predictive-member | predictive-node |
 +        ratio-least-connections-member |
 +        ratio-least-connections-node |
 +        ratio-member | ratio-node | ratio-session |
 +        round-robin | weighted-least-connections-member |
 +        weighted-least-connections-node]
 +    min_active_members
 +        [integer]
 +    min_up_members
 +        [integer]
 +    min_up_members_action
 +        [failover | reboot | restart-all]
 +    min_up_members_checking
 +        [enabled | disabled]
 +    monitor
 +        [name]
 +    profiles
 +        [none | profile_name]
 +    queue_on_connection_limit
 +        [enabled | disabled]
 +    queue_depth_limit
 +        [integer]
 +    queue_time_limit
 +        [integer]
 +    reselect_tries
 +        [integer]
 +    service_down_action
 +        [drop | none | reselect | reset]
 +    slow_ramp_time
 +        [integer]
 +
 +    CLI Example::
 +
 +        salt '​*'​ bigip.modify_pool bigip admin admin my-pool 10.1.1.1:​80,​10.1.1.2:​80,​10.1.1.3:​80 min_active_members=1
 +    ​
 +
 +bigip.modify_pool_member:​
 +
 +    A function to connect to a bigip device and modify an existing member of a pool.
 +
 +    hostname
 +        The host/​address of the bigip device
 +    username
 +        The iControl REST username
 +    password
 +        The iControl REST password
 +    name
 +        The name of the pool to modify
 +    member
 +        The name of the member to modify i.e. 10.1.1.2:80
 +    connection_limit
 +        [integer]
 +    description
 +        [string]
 +    dynamic_ratio
 +        [integer]
 +    inherit_profile
 +        [enabled | disabled]
 +    logging
 +        [enabled | disabled]
 +    monitor
 +        [name]
 +    priority_group
 +        [integer]
 +    profiles
 +        [none | profile_name]
 +    rate_limit
 +        [integer]
 +    ratio
 +        [integer]
 +    session
 +        [user-enabled | user-disabled]
 +    state
 +        [ user-up | user-down ]
 +
 +    CLI Example::
 +
 +        salt '​*'​ bigip.modify_pool_member bigip admin admin my-pool 10.2.2.1:80 state=use-down session=user-disabled
 +    ​
 +
 +bigip.modify_profile:​
 +
 +    A function to connect to a bigip device and create a profile.
 +
 +    A function to connect to a bigip device and create a profile.
 +
 +    hostname
 +        The host/​address of the bigip device
 +    username
 +        The iControl REST username
 +    password
 +        The iControl REST password
 +    profile_type
 +        The type of profile to create
 +    name
 +        The name of the profile to create
 +    kwargs
 +        ``[ arg=val ] ... [arg=key1:​val1,​key2:​val2] ...``
 +
 +        Consult F5 BIGIP user guide for specific options for each monitor type.
 +        Typically, tmsh arg names are used.
 +
 +    Creating Complex Args
 +
 +        Profiles can get pretty complicated in terms of the amount of possible
 +        config options. Use the following shorthand to create complex arguments such
 +        as lists, dictionaries,​ and lists of dictionaries. An option is also
 +        provided to pass raw json as well.
 +
 +        lists ``[i,​i,​i]``:​
 +            ``param='​item1,​item2,​item3'​``
 +
 +        Dictionary ``[k:​v,​k:​v,​k,​v]``:​
 +            ``param='​key-1:​val-1,​key-2:​val2,​key-3:​va-3'​``
 +
 +        List of Dictionaries ``[k:​v,​k:​v|k:​v,​k:​v|k:​v,​k:​v]``:​
 +           ​``param='​key-1:​val-1,​key-2:​val-2|key-1:​val-1,​key-2:​val-2|key-1:​val-1,​key-2:​val-2'​``
 +
 +        JSON: ``'j{ ... }j'``:
 +           ​``cert-key-chain='​j{ "​default":​ { "​cert":​ "​default.crt",​ "​chain":​ "​default.crt",​ "​key":​ "​default.key"​ } }j'``
 +
 +        Escaping Delimiters:
 +            Use ``\,`` or ``\:`` or ``\|`` to escape characters which shouldn'​t
 +            be treated as delimiters i.e. ``ciphers='​DEFAULT\:​!SSLv3'​``
 +
 +    CLI Examples::
 +
 +        salt '​*'​ bigip.modify_profile bigip admin admin http my-http-profile defaultsFrom='/​Common/​http'​
 +
 +        salt '​*'​ bigip.modify_profile bigip admin admin http my-http-profile defaultsFrom='/​Common/​http'​ \
 +            enforcement=maxHeaderCount:​3200,​maxRequests:​10
 +
 +        salt '​*'​ bigip.modify_profile bigip admin admin client-ssl my-client-ssl-1 retainCertificate=false \
 +            ciphers='​DEFAULT\:​!SSLv3'​
 +            cert_key_chain='​j{ "​default":​ { "​cert":​ "​default.crt",​ "​chain":​ "​default.crt",​ "​key":​ "​default.key"​ } }j'
 +    ​
 +
 +bigip.modify_virtual:​
 +
 +    A function to connect to a bigip device and modify an existing virtual server.
 +
 +    hostname
 +        The host/​address of the bigip device
 +    username
 +        The iControl REST username
 +    password
 +        The iControl REST password
 +    name
 +        The name of the virtual to modify
 +    destination
 +        [ [virtual_address_name:​port] | [ipv4:port] | [ipv6.port] ]
 +    pool
 +        [ [pool_name] | none]
 +    address_status
 +        [yes | no]
 +    auto_lasthop
 +        [default | enabled | disabled ]
 +    bwc_policy
 +        [none] | string]
 +    cmp_enabled
 +        [yes | no]
 +    dhcp_relay
 +        [yes | no}
 +    connection_limit
 +        [integer]
 +    description
 +        [string]
 +    state
 +        [disabled | enabled]
 +    fallback_persistence
 +        [none | [profile name] ]
 +    flow_eviction_policy
 +        [none | [eviction policy name] ]
 +    gtm_score
 +        [integer]
 +    ip_forward
 +        [yes | no]
 +    ip_protocol
 +        [any | protocol]
 +    internal
 +        [yes | no]
 +    twelve_forward
 +        (12-forward)
 +        [yes | no]
 +    last_hop-pool
 +        [ [pool_name] | none]
 +    mask
 +        { [ipv4] | [ipv6] }
 +    mirror
 +        { [disabled | enabled | none] }
 +    nat64
 +        [enabled | disabled]
 +    persist
 +        [none | profile1,​profile2,​profile3 ... ]
 +    profiles
 +        [none | default | profile1,​profile2,​profile3 ... ]
 +    policies
 +        [none | default | policy1,​policy2,​policy3 ... ]
 +    rate_class
 +        [name]
 +    rate_limit
 +        [integer]
 +    rate_limitr_mode
 +        [destination | object | object-destination |
 +        object-source | object-source-destination |
 +        source | source-destination]
 +    rate_limit_dst
 +        [integer]
 +    rate_limit_src
 +        [integer]
 +    rules
 +        [none | [rule_one,​rule_two ...] ]
 +    related_rules
 +        [none | [rule_one,​rule_two ...] ]
 +    reject
 +        [yes | no]
 +    source
 +        { [ipv4[/​prefixlen]] | [ipv6[/​prefixlen]] }
 +    source_address_translation
 +        [none | snat:​pool_name | lsn | automap ]
 +    source_port
 +        [change | preserve | preserve-strict]
 +    state
 +        [enabled | disable]
 +    traffic_classes
 +        [none | default | class_one,​class_two ... ]
 +    translate_address
 +        [enabled | disabled]
 +    translate_port
 +        [enabled | disabled]
 +    vlans
 +        [none | default | [enabled|disabled]:​vlan1,​vlan2,​vlan3 ... ]
 +
 +    CLI Example::
 +
 +        salt '​*'​ bigip.modify_virtual bigip admin admin my-virtual source_address_translation=none
 +        salt '​*'​ bigip.modify_virtual bigip admin admin my-virtual rules=my-rule,​my-other-rule
 +    ​
 +
 +bigip.replace_pool_members:​
 +
 +    A function to connect to a bigip device and replace members of an existing pool with new members.
 +
 +    hostname
 +        The host/​address of the bigip device
 +    username
 +        The iControl REST username
 +    password
 +        The iControl REST password
 +    name
 +        The name of the pool to modify
 +    members
 +        List of comma delimited pool members to replace existing members with.
 +        i.e. 10.1.1.1:​80,​10.1.1.2:​80,​10.1.1.3:​80
 +
 +    CLI Example::
 +
 +        salt '​*'​ bigip.replace_pool_members bigip admin admin my-pool 10.2.2.1:​80,​10.2.2.2:​80,​10.2.2.3:​80
 +    ​
 +
 +bigip.start_transaction:​
 +
 +    A function to connect to a bigip device and start a new transaction.
 +
 +    hostname
 +        The host/​address of the bigip device
 +    username
 +        The iControl REST username
 +    password
 +        The iControl REST password
 +    label
 +        The name / alias for this transaction. ​ The actual transaction
 +        id will be stored within a grain called ``bigip_f5_trans:<​label>​``
 +
 +    CLI Example::
 +
 +        salt '​*'​ bigip.start_transaction bigip admin admin my_transaction
 +
 +    ​
 +
 +blockdev.dump:​
 +
 +    Return all contents of dumpe2fs for a specified device
 +
 +    args
 +        a list containing only the desired arguments to return
 +
 +    CLI Example:
 +
 +        salt '​*'​ blockdev.dump /dev/sdX1
 +    ​
 +
 +blockdev.format:​
 +
 +    Format a filesystem onto a block device
 +
 +    New in version 2015.8.2
 +
 +    device
 +        The block device in which to create the new filesystem
 +
 +    fs_type
 +        The type of filesystem to create
 +
 +    inode_size
 +        Size of the inodes
 +
 +        This option is only enabled for ext and xfs filesystems
 +
 +    lazy_itable_init
 +        If enabled and the uninit_bg feature is enabled, the inode table will
 +        not be fully initialized by mke2fs. ​ This speeds up filesystem
 +        initialization noticeably, but it requires the kernel to finish
 +        initializing the filesystem ​ in  the  background ​ when  the filesystem
 +        is first mounted. ​ If the option value is omitted, it defaults to 1 to
 +        enable lazy inode table zeroing.
 +
 +        This option is only enabled for ext filesystems
 +
 +    CLI Example:
 +
 +        salt '​*'​ blockdev.format /dev/sdX1
 +    ​
 +
 +blockdev.fstype:​
 +
 +    Return the filesystem name of a block device
 +
 +    New in version 2015.8.2
 +
 +    device
 +        The name of the block device
 +
 +    CLI Example:
 +
 +        salt '​*'​ blockdev.fstype /dev/sdX1
 +    ​
 +
 +blockdev.resize2fs:​
 +
 +    Resizes the filesystem.
 +
 +    CLI Example:
 +        salt '​*'​ blockdev.resize2fs /dev/sdX1
 +    ​
 +
 +blockdev.tune:​
 +
 +    Set attributes for the specified device
 +
 +    CLI Example:
 +
 +        salt '​*'​ blockdev.tune /dev/sdX1 read-ahead=1024 read-write=True
 +
 +    Valid options are: ``read-ahead``,​ ``filesystem-read-ahead``,​
 +    ``read-only``,​ ``read-write``.
 +
 +    See the ``blockdev(8)`` manpage for a more complete description of these
 +    options.
 +    ​
 +
 +blockdev.wipe:​
 +
 +    Remove the filesystem information
 +
 +    CLI Example:
 +
 +        salt '​*'​ blockdev.wipe /dev/sdX1
 +    ​
 +
 +btrfs.add:
 +
 +    Add a devices to a BTRFS filesystem.
 +
 +    General options:
 +
 +    * **nodiscard**:​ Do not perform whole device TRIM
 +    * **force**: Force overwrite existing filesystem on the disk
 +
 +    CLI Example:
 +
 +        salt '​*'​ btrfs.add /mountpoint /dev/sda1 /dev/sda2
 +    ​
 +
 +btrfs.convert:​
 +
 +    Convert ext2/3/4 to BTRFS. Device should be mounted.
 +
 +    Filesystem can be converted temporarily so the further processing and rollback is possible,
 +    or permanently,​ where previous extended filesystem image gets deleted. Please note, permanent
 +    conversion takes a while as BTRFS filesystem needs to be properly rebalanced afterwards.
 +
 +    General options:
 +
 +    * **permanent**:​ Specify if the migration should be permanent (false by default)
 +    * **keeplf**: Keep ``lost+found`` of the partition (removed by default,
 +                  but still in the image, if not permanent migration)
 +
 +    CLI Example:
 +
 +        salt '​*'​ btrfs.convert /dev/sda1
 +        salt '​*'​ btrfs.convert /dev/sda1 permanent=True
 +    ​
 +
 +btrfs.defragment:​
 +
 +    Defragment mounted BTRFS filesystem.
 +    In order to defragment a filesystem, device should be properly mounted and writable.
 +
 +    If passed a device name, then defragmented whole filesystem, mounted on in.
 +    If passed a moun tpoint of the filesystem, then only this mount point is defragmented.
 +
 +    CLI Example:
 +
 +        salt '​*'​ btrfs.defragment /dev/sda1
 +        salt '​*'​ btrfs.defragment /​path/​on/​filesystem
 +    ​
 +
 +btrfs.delete:​
 +
 +    Remove devices from a BTRFS filesystem.
 +
 +    CLI Example:
 +
 +        salt '​*'​ btrfs.delete /mountpoint /dev/sda1 /dev/sda2
 +    ​
 +
 +btrfs.devices:​
 +
 +    Get known BTRFS formatted devices on the system.
 +
 +    CLI Example:
 +
 +        salt '​*'​ btrfs.devices
 +    ​
 +
 +btrfs.features:​
 +
 +    List currently available BTRFS features.
 +
 +    CLI Example:
 +
 +        salt '​*'​ btrfs.mkfs_features
 +    ​
 +
 +btrfs.info:
 +
 +    Get BTRFS filesystem information.
 +
 +    CLI Example:
 +
 +        salt '​*'​ btrfs.info /dev/sda1
 +    ​
 +
 +btrfs.mkfs:
 +
 +    Create a file system on the specified device. By default wipes out with force.
 +
 +    General options:
 +
 +    * **allocsize**:​ Specify the BTRFS offset from the start of the device.
 +    * **bytecount**:​ Specify the size of the resultant filesystem.
 +    * **nodesize**:​ Node size.
 +    * **leafsize**:​ Specify the nodesize, the tree block size in which btrfs stores data.
 +    * **noforce**:​ Prevent force overwrite when an existing filesystem is detected on the device.
 +    * **sectorsize**:​ Specify the sectorsize, the minimum data block allocation unit.
 +    * **nodiscard**:​ Do not perform whole device TRIM operation by default.
 +    * **uuid**: Pass UUID or pass True to generate one.
 +
 +
 +    Options:
 +
 +    * **dto**: (raid0|raid1|raid5|raid6|raid10|single|dup)
 +               ​Specify how the data must be spanned across the devices specified.
 +    * **mto**: (raid0|raid1|raid5|raid6|raid10|single|dup)
 +               ​Specify how metadata must be spanned across the devices specified.
 +    * **fts**: Features (call ``salt <​host>​ btrfs.features`` for full list of available features)
 +
 +    See the ``mkfs.btrfs(8)`` manpage for a more complete description of corresponding options description.
 +
 +    CLI Example:
 +
 +        salt '​*'​ btrfs.mkfs /dev/sda1
 +        salt '​*'​ btrfs.mkfs /dev/sda1 noforce=True
 +    ​
 +
 +btrfs.properties:​
 +
 +    List properties for given btrfs object. The object can be path of BTRFS device,
 +    mount point, or any directories/​files inside the BTRFS filesystem.
 +
 +    General options:
 +
 +    * **type**: Possible types are s[ubvol], f[ilesystem],​ i[node] and d[evice].
 +    * **force**: Force overwrite existing filesystem on the disk
 +    * **set**: <​key=value,​key1=value1...>​ Options for a filesystem properties.
 +
 +    CLI Example:
 +
 +        salt '​*'​ btrfs.properties /mountpoint
 +        salt '​*'​ btrfs.properties /dev/sda1 type=subvol set='​ro=false,​label="​My Storage"'​
 +    ​
 +
 +btrfs.resize:​
 +
 +    Resize filesystem.
 +
 +    General options:
 +
 +    * **mountpoint**:​ Specify the BTRFS mountpoint to resize.
 +    * **size**: ([+/​-]<​newsize>​[kKmMgGtTpPeE]|max) Specify the new size of the target.
 +
 +    CLI Example:
 +
 +        salt '​*'​ btrfs.resize /mountpoint size=+1g
 +        salt '​*'​ btrfs.resize /dev/sda1 size=max
 +    ​
 +
 +btrfs.usage:​
 +
 +    Show in which disk the chunks are allocated.
 +
 +    CLI Example:
 +
 +        salt '​*'​ btrfs.usage /​your/​mountpoint
 +    ​
 +
 +btrfs.version:​
 +
 +    Return BTRFS version.
 +
 +    CLI Example:
 +
 +        salt '​*'​ btrfs.version
 +    ​
 +
 +buildout.bootstrap:​
 +
 +    Run the buildout bootstrap dance (python bootstrap.py).
 +
 +    directory
 +        directory to execute in
 +
 +    config
 +        alternative buildout configuration file to use
 +
 +    runas
 +        User used to run buildout as
 +
 +    env
 +        environment variables to set when running
 +
 +    buildout_ver
 +        force a specific buildout version (1 | 2)
 +
 +    test_release
 +        buildout accept test release
 +
 +    offline
 +        are we executing buildout in offline mode
 +
 +    distribute
 +        Forcing use of distribute
 +
 +    new_st
 +        Forcing use of setuptools >= 0.7
 +
 +    python
 +        path to a python executable to use in place of default (salt one)
 +
 +    onlyif
 +        Only execute cmd if statement on the host return 0
 +
 +    unless
 +        Do not execute cmd if statement on the host return 0
 +
 +    use_vt
 +        Use the new salt VT to stream output [experimental]
 +
 +    CLI Example:
 +
 +        salt '​*'​ buildout.bootstrap /​srv/​mybuildout
 +    ​
 +
 +buildout.buildout:​
 +
 +    Run buildout in a directory.
 +
 +    directory
 +        directory to execute in
 +
 +    config
 +        buildout config to use
 +
 +    parts
 +        specific buildout parts to run
 +
 +    runas
 +        user used to run buildout as
 +
 +    env
 +        environment variables to set when running
 +
 +    buildout_ver
 +        force a specific buildout version (1 | 2)
 +
 +    test_release
 +        buildout accept test release
 +
 +    new_st
 +        Forcing use of setuptools >= 0.7
 +
 +    distribute
 +        use distribute over setuptools if possible
 +
 +    offline
 +        does buildout run offline
 +
 +    python
 +        python to use
 +
 +    debug
 +        run buildout with -D debug flag
 +
 +    onlyif
 +        Only execute cmd if statement on the host return 0
 +
 +    unless
 +        Do not execute cmd if statement on the host return 0
 +    newest
 +        run buildout in newest mode
 +
 +    verbose
 +        run buildout in verbose mode (-vvvvv)
 +
 +    use_vt
 +        Use the new salt VT to stream output [experimental]
 +
 +    CLI Example:
 +
 +        salt '​*'​ buildout.buildout /​srv/​mybuildout
 +    ​
 +
 +buildout.run_buildout:​
 +
 +    Run a buildout in a directory.
 +
 +    directory
 +        directory to execute in
 +
 +    config
 +        alternative buildout configuration file to use
 +
 +    offline
 +        are we executing buildout in offline mode
 +
 +    runas
 +        user used to run buildout as
 +
 +    env
 +        environment variables to set when running
 +
 +    onlyif
 +        Only execute cmd if statement on the host return 0
 +
 +    unless
 +        Do not execute cmd if statement on the host return 0
 +
 +    newest
 +        run buildout in newest mode
 +
 +    force
 +        run buildout unconditionally
 +
 +    verbose
 +        run buildout in verbose mode (-vvvvv)
 +
 +    use_vt
 +        Use the new salt VT to stream output [experimental]
 +
 +    CLI Example:
 +
 +        salt '​*'​ buildout.run_buildout /​srv/​mybuildout
 +    ​
 +
 +buildout.upgrade_bootstrap:​
 +
 +    Upgrade current bootstrap.py with the last released one.
 +
 +    Indeed, when we first run a buildout, a common source of problem
 +    is to have a locally stale bootstrap, we just try to grab a new copy
 +
 +    directory
 +        directory to execute in
 +
 +    offline
 +        are we executing buildout in offline mode
 +
 +    buildout_ver
 +        forcing to use a specific buildout version (1 | 2)
 +
 +    onlyif
 +        Only execute cmd if statement on the host return 0
 +
 +    unless
 +        Do not execute cmd if statement on the host return 0
 +
 +    CLI Example:
 +
 +        salt '​*'​ buildout.upgrade_bootstrap /​srv/​mybuildout
 +    ​
 +
 +cloud.action:​
 +
 +    Execute a single action on the given provider/​instance
 +
 +    CLI Example:
 +
 +        salt '​*'​ cloud.action start instance=myinstance
 +        salt '​*'​ cloud.action stop instance=myinstance
 +        salt '​*'​ cloud.action show_image provider=my-ec2-config image=ami-1624987f
 +    ​
 +
 +cloud.create:​
 +
 +    Create an instance using Salt Cloud
 +
 +    CLI Example:
 +
 +        salt minionname cloud.create my-ec2-config myinstance image=ami-1624987f size='​t1.micro'​ ssh_username=ec2-user securitygroup=default delvol_on_destroy=True
 +    ​
 +
 +cloud.destroy:​
 +
 +    Destroy the named VM(s)
 +
 +    CLI Example:
 +
 +        salt '​*'​ cloud.destroy myinstance
 +    ​
 +
 +cloud.full_query:​
 +
 +    List all available cloud provider data
 +
 +    CLI Example:
 +
 +        salt '​*'​ cloud.full_query
 +    ​
 +
 +cloud.get_instance:​
 +
 +    Return details on an instance.
 +
 +    Similar to the cloud action show_instance
 +    but returns only the instance details.
 +
 +    CLI Example:
 +
 +        salt '​*'​ cloud.get_instance myinstance
 +
 +    SLS Example:
 +
 +        {{ salt['​cloud.get_instance'​]('​myinstance'​)['​mac_address'​] }}
 +
 +    ​
 +
 +cloud.has_instance:​
 +
 +    Return true if the instance is found on a provider
 +
 +    CLI Example:
 +
 +        salt '​*'​ cloud.has_instance myinstance
 +    ​
 +
 +cloud.list_images:​
 +
 +    List cloud provider images for the given providers
 +
 +    CLI Example:
 +
 +        salt '​*'​ cloud.list_images my-gce-config
 +    ​
 +
 +cloud.list_locations:​
 +
 +    List cloud provider locations for the given providers
 +
 +    CLI Example:
 +
 +        salt '​*'​ cloud.list_locations my-gce-config
 +    ​
 +
 +cloud.list_sizes:​
 +
 +    List cloud provider sizes for the given providers
 +
 +    CLI Example:
 +
 +        salt '​*'​ cloud.list_sizes my-gce-config
 +    ​
 +
 +cloud.network_create:​
 +
 +    Create private network
 +
 +    CLI Example:
 +
 +        salt minionname cloud.network_create my-nova names=['​salt'​] cidr='​192.168.100.0/​24'​
 +
 +    ​
 +
 +cloud.network_list:​
 +
 +    List private networks
 +
 +    CLI Example:
 +
 +        salt minionname cloud.network_list my-nova
 +
 +    ​
 +
 +cloud.profile:​
 +
 +    Spin up an instance using Salt Cloud
 +
 +    CLI Example:
 +
 +        salt '​*'​ cloud.profile my-gce-config myinstance
 +    ​
 +
 +cloud.query:​
 +
 +    List cloud provider data for all providers
 +
 +    CLI Examples:
 +
 +        salt '​*'​ cloud.query
 +        salt '​*'​ cloud.query list_nodes_full
 +        salt '​*'​ cloud.query list_nodes_select
 +    ​
 +
 +cloud.select_query:​
 +
 +    List selected nodes
 +
 +    CLI Example:
 +
 +        salt '​*'​ cloud.select_query
 +    ​
 +
 +cloud.virtual_interface_create:​
 +
 +    Attach private interfaces to a server
 +
 +    CLI Example:
 +
 +        salt minionname cloud.virtual_interface_create my-nova names=['​salt-master'​] net_name='​salt'​
 +
 +    ​
 +
 +cloud.virtual_interface_list:​
 +
 +    List virtual interfaces on a server
 +
 +    CLI Example:
 +
 +        salt minionname cloud.virtual_interface_list my-nova names=['​salt-master'​]
 +
 +    ​
 +
 +cloud.volume_attach:​
 +
 +    Attach volume to a server
 +
 +    CLI Example:
 +
 +        salt minionname cloud.volume_attach my-nova myblock server_name=myserver device='/​dev/​xvdf'​
 +
 +    ​
 +
 +cloud.volume_create:​
 +
 +    Create volume
 +
 +    CLI Example:
 +
 +        salt minionname cloud.volume_create my-nova myblock size=100 voltype=SSD
 +
 +    ​
 +
 +cloud.volume_delete:​
 +
 +    Delete volume
 +
 +    CLI Example:
 +
 +        salt minionname cloud.volume_delete my-nova myblock
 +
 +    ​
 +
 +cloud.volume_detach:​
 +
 +    Detach volume from a server
 +
 +    CLI Example:
 +
 +        salt minionname cloud.volume_detach my-nova myblock server_name=myserver
 +
 +    ​
 +
 +cloud.volume_list:​
 +
 +    List block storage volumes
 +
 +    CLI Example:
 +
 +        salt minionname cloud.volume_list my-nova
 +
 +    ​
 +
 +cmd.exec_code:​
 +
 +    Pass in two strings, the first naming the executable language, aka -
 +    python2, python3, ruby, perl, lua, etc. the second string containing
 +    the code you wish to execute. The stdout will be returned.
 +
 +    CLI Example:
 +
 +        salt '​*'​ cmd.exec_code ruby 'puts "​cheese"'​
 +    ​
 +
 +cmd.exec_code_all:​
 +
 +    Pass in two strings, the first naming the executable language, aka -
 +    python2, python3, ruby, perl, lua, etc. the second string containing
 +    the code you wish to execute. All cmd artifacts (stdout, stderr, retcode, pid)
 +    will be returned.
 +
 +    CLI Example:
 +
 +        salt '​*'​ cmd.exec_code_all ruby 'puts "​cheese"'​
 +    ​
 +
 +cmd.has_exec:​
 +
 +    Returns true if the executable is available on the minion, false otherwise
 +
 +    CLI Example:
 +
 +        salt '​*'​ cmd.has_exec cat
 +    ​
 +
 +cmd.retcode:​
 +
 +    Execute a shell command and return the command'​s return code.
 +
 +    cmd:
 +        The command to run. ex: 'ls -lart /home'
 +
 +    cwd
 +        The current working directory to execute the command in, defaults to
 +        /root
 +
 +    stdin
 +        A string of standard input can be specified for the command to be run using
 +        the ``stdin`` parameter. This can be useful in cases where sensitive
 +        information must be read from standard input.:
 +
 +    runas
 +        User to run script as.
 +
 +    shell
 +        Shell to execute under. Defaults to the system default shell.
 +
 +    python_shell
 +        If False, let python handle the positional arguments. Set to True
 +        to use shell features, such as pipes or redirection
 +
 +    env
 +        A list of environment variables to be set prior to execution.
 +        Example:
 +
 +            salt://​scripts/​foo.sh:​
 +              cmd.script:
 +                - env:
 +                  - BATCH: '​yes'​
 +
 +        Warning:
 +
 +            The above illustrates a common PyYAML pitfall, that **yes**,
 +            **no**, **on**, **off**, **true**, and **false** are all loaded as
 +            boolean ``True`` and ``False`` values, and must be enclosed in
 +            quotes to be used as strings. More info on this (and other) PyYAML
 +            idiosyncrasies can be found :doc:`here
 +            </​topics/​troubleshooting/​yaml_idiosyncrasies>​`.
 +
 +        Variables as values are not evaluated. So $PATH in the following
 +        example is a literal '​$PATH':​
 +
 +            salt://​scripts/​bar.sh:​
 +              cmd.script:
 +                - env: "​PATH=/​some/​path:​$PATH"​
 +
 +        One can still use the existing $PATH by using a bit of Jinja:
 +
 +            {% set current_path = salt['​environ.get'​]('​PATH',​ '/​bin:/​usr/​bin'​) %}
 +
 +            mycommand:
 +              cmd.run:
 +                - name: ls -l /
 +                - env:
 +                  - PATH: {{ [current_path,​ '/​my/​special/​bin'​]|join(':'​) }}
 +
 +     ​clean_env:​
 +        Attempt to clean out all other shell environment variables and set
 +        only those provided in the '​env'​ argument to this function.
 +
 +    template
 +        If this setting is applied then the named templating engine will be
 +        used to render the downloaded file. Currently jinja, mako, and wempy
 +        are supported
 +
 +    rstrip
 +        Strip all whitespace off the end of output before it is returned.
 +
 +    umask
 +         The umask (in octal) to use when running the command.
 +
 +    output_loglevel
 +        Control the loglevel at which the output from the command is logged.
 +        Note that the command being run will still be logged (loglevel: DEBUG)
 +        regardless, unless ``quiet`` is used for this value.
 +
 +    timeout
 +        A timeout in seconds for the executed process to return.
 +
 +    use_vt
 +        Use VT utils (saltstack) to stream the command output more
 +        interactively to the console and the logs.
 +        This is experimental.
 +
 +    Note that ``env`` represents the environment variables for the command, and
 +    should be formatted as a dict, or a YAML string which resolves to a dict.
 +
 +    :rtype: int
 +    :rtype: None
 +    :returns: Return Code as an int or None if there was an exception.
 +
 +    CLI Example:
 +
 +        salt '​*'​ cmd.retcode "file /​bin/​bash"​
 +
 +    The template arg can be set to '​jinja'​ or another supported template
 +    engine to render the command arguments before execution.
 +    For example:
 +
 +        salt '​*'​ cmd.retcode template=jinja "file {{grains.pythonpath[0]}}/​python"​
 +
 +    A string of standard input can be specified for the command to be run using
 +    the ``stdin`` parameter. This can be useful in cases where sensitive
 +    information must be read from standard input.:
 +
 +        salt '​*'​ cmd.retcode "grep f" stdin='​one\ntwo\nthree\nfour\nfive\n'​
 +    ​
 +
 +cmd.run:
 +
 +    Execute the passed command and return the output as a string
 +
 +    Note that ``env`` represents the environment variables for the command, and
 +    should be formatted as a dict, or a YAML string which resolves to a dict.
 +
 +    cmd:
 +        The command to run. ex: 'ls -lart /home'
 +
 +    cwd
 +        The current working directory to execute the command in, defaults to
 +        /root
 +
 +    stdin
 +        A string of standard input can be specified for the command to be run using
 +        the ``stdin`` parameter. This can be useful in cases where sensitive
 +        information must be read from standard input.:
 +
 +    runas
 +        User to run script as.
 +
 +    shell
 +        Shell to execute under. Defaults to the system default shell.
 +
 +    python_shell
 +        If False, let python handle the positional arguments. Set to True
 +        to use shell features, such as pipes or redirection
 +
 +    env
 +        A list of environment variables to be set prior to execution.
 +        Example:
 +
 +            salt://​scripts/​foo.sh:​
 +              cmd.script:
 +                - env:
 +                  - BATCH: '​yes'​
 +
 +        Warning:
 +
 +            The above illustrates a common PyYAML pitfall, that **yes**,
 +            **no**, **on**, **off**, **true**, and **false** are all loaded as
 +            boolean ``True`` and ``False`` values, and must be enclosed in
 +            quotes to be used as strings. More info on this (and other) PyYAML
 +            idiosyncrasies can be found :doc:`here
 +            </​topics/​troubleshooting/​yaml_idiosyncrasies>​`.
 +
 +        Variables as values are not evaluated. So $PATH in the following
 +        example is a literal '​$PATH':​
 +
 +            salt://​scripts/​bar.sh:​
 +              cmd.script:
 +                - env: "​PATH=/​some/​path:​$PATH"​
 +
 +        One can still use the existing $PATH by using a bit of Jinja:
 +
 +            {% set current_path = salt['​environ.get'​]('​PATH',​ '/​bin:/​usr/​bin'​) %}
 +
 +            mycommand:
 +              cmd.run:
 +                - name: ls -l /
 +                - env:
 +                  - PATH: {{ [current_path,​ '/​my/​special/​bin'​]|join(':'​) }}
 +
 +     ​clean_env:​
 +        Attempt to clean out all other shell environment variables and set
 +        only those provided in the '​env'​ argument to this function.
 +
 +    template
 +        If this setting is applied then the named templating engine will be
 +        used to render the downloaded file. Currently jinja, mako, and wempy
 +        are supported
 +
 +    rstrip
 +        Strip all whitespace off the end of output before it is returned.
 +
 +    umask
 +         The umask (in octal) to use when running the command.
 +
 +    output_loglevel
 +        Control the loglevel at which the output from the command is logged.
 +        Note that the command being run will still be logged (loglevel: DEBUG)
 +        regardless, unless ``quiet`` is used for this value.
 +
 +    timeout
 +        A timeout in seconds for the executed process to return.
 +
 +    use_vt
 +        Use VT utils (saltstack) to stream the command output more
 +        interactively to the console and the logs.
 +        This is experimental.
 +
 +
 +    Warning:
 +
 +        This function does not process commands through a shell
 +        unless the python_shell flag is set to True. This means that any
 +        shell-specific functionality such as '​echo'​ or the use of pipes,
 +        redirection or &&, should either be migrated to cmd.shell or
 +        have the python_shell=True flag set here.
 +
 +        The use of python_shell=True means that the shell will accept _any_ input
 +        including potentially malicious commands such as '​good_command;​rm -rf /'.
 +        Be absolutely certain that you have sanitized your input prior to using
 +        python_shell=True
 +
 +    CLI Example:
 +
 +        salt '​*'​ cmd.run "ls -l | awk '/​foo/​{print \$2}'"​
 +
 +    The template arg can be set to '​jinja'​ or another supported template
 +    engine to render the command arguments before execution.
 +    For example:
 +
 +        salt '​*'​ cmd.run template=jinja "ls -l /​tmp/​{{grains.id}} | awk '/​foo/​{print \$2}'"​
 +
 +    Specify an alternate shell with the shell parameter:
 +
 +        salt '​*'​ cmd.run "​Get-ChildItem C:\ " shell='​powershell'​
 +
 +    A string of standard input can be specified for the command to be run using
 +    the ``stdin`` parameter. This can be useful in cases where sensitive
 +    information must be read from standard input.:
 +
 +        salt '​*'​ cmd.run "grep f" stdin='​one\ntwo\nthree\nfour\nfive\n'​
 +
 +    If an equal sign (``=``) appears in an argument to a Salt command it is
 +    interpreted as a keyword argument in the format ``key=val``. That
 +    processing can be bypassed in order to pass an equal sign through to the
 +    remote shell command by manually specifying the kwarg:
 +
 +        salt '​*'​ cmd.run cmd='​sed -e s/​=/:/​g'​
 +    ​
 +
 +cmd.run_all:​
 +
 +    Execute the passed command and return a dict of return data
 +
 +    cmd:
 +        The command to run. ex: 'ls -lart /home'
 +
 +    cwd
 +        The current working directory to execute the command in, defaults to
 +        /root
 +
 +    stdin
 +        A string of standard input can be specified for the command to be run using
 +        the ``stdin`` parameter. This can be useful in cases where sensitive
 +        information must be read from standard input.:
 +
 +    runas
 +        User to run script as.
 +
 +    shell
 +        Shell to execute under. Defaults to the system default shell.
 +
 +    python_shell
 +        If False, let python handle the positional arguments. Set to True
 +        to use shell features, such as pipes or redirection
 +
 +    env
 +        A list of environment variables to be set prior to execution.
 +        Example:
 +
 +            salt://​scripts/​foo.sh:​
 +              cmd.script:
 +                - env:
 +                  - BATCH: '​yes'​
 +
 +        Warning:
 +
 +            The above illustrates a common PyYAML pitfall, that **yes**,
 +            **no**, **on**, **off**, **true**, and **false** are all loaded as
 +            boolean ``True`` and ``False`` values, and must be enclosed in
 +            quotes to be used as strings. More info on this (and other) PyYAML
 +            idiosyncrasies can be found :doc:`here
 +            </​topics/​troubleshooting/​yaml_idiosyncrasies>​`.
 +
 +        Variables as values are not evaluated. So $PATH in the following
 +        example is a literal '​$PATH':​
 +
 +            salt://​scripts/​bar.sh:​
 +              cmd.script:
 +                - env: "​PATH=/​some/​path:​$PATH"​
 +
 +        One can still use the existing $PATH by using a bit of Jinja:
 +
 +            {% set current_path = salt['​environ.get'​]('​PATH',​ '/​bin:/​usr/​bin'​) %}
 +
 +            mycommand:
 +              cmd.run:
 +                - name: ls -l /
 +                - env:
 +                  - PATH: {{ [current_path,​ '/​my/​special/​bin'​]|join(':'​) }}
 +
 +     ​clean_env:​
 +        Attempt to clean out all other shell environment variables and set
 +        only those provided in the '​env'​ argument to this function.
 +
 +    template
 +        If this setting is applied then the named templating engine will be
 +        used to render the downloaded file. Currently jinja, mako, and wempy
 +        are supported
 +
 +    rstrip
 +        Strip all whitespace off the end of output before it is returned.
 +
 +    umask
 +         The umask (in octal) to use when running the command.
 +
 +    output_loglevel
 +        Control the loglevel at which the output from the command is logged.
 +        Note that the command being run will still be logged (loglevel: DEBUG)
 +        regardless, unless ``quiet`` is used for this value.
 +
 +    timeout
 +        A timeout in seconds for the executed process to return.
 +
 +    use_vt
 +        Use VT utils (saltstack) to stream the command output more
 +        interactively to the console and the logs.
 +        This is experimental.
 +
 +    Note that ``env`` represents the environment variables for the command, and
 +    should be formatted as a dict, or a YAML string which resolves to a dict.
 +
 +    redirect_stderr : False
 +        If set to ``True``, then stderr will be redirected to stdout. This is
 +        helpful for cases where obtaining both the retcode and output is
 +        desired, but it is not desired to have the output separated into both
 +        stdout and stderr.
 +
 +        New in version 2015.8.2
 +
 +    CLI Example:
 +
 +        salt '​*'​ cmd.run_all "ls -l | awk '/​foo/​{print \$2}'"​
 +
 +    The template arg can be set to '​jinja'​ or another supported template
 +    engine to render the command arguments before execution.
 +    For example:
 +
 +        salt '​*'​ cmd.run_all template=jinja "ls -l /​tmp/​{{grains.id}} | awk '/​foo/​{print \$2}'"​
 +
 +    A string of standard input can be specified for the command to be run using
 +    the ``stdin`` parameter. This can be useful in cases where sensitive
 +    information must be read from standard input.:
 +
 +        salt '​*'​ cmd.run_all "grep f" stdin='​one\ntwo\nthree\nfour\nfive\n'​
 +    ​
 +
 +cmd.run_chroot:​
 +
 +    New in version 2014.7.0
 +
 +    This function runs :​mod:​`cmd.run_all <​salt.modules.cmdmod.run_all>​` wrapped
 +    within a chroot, with dev and proc mounted in the chroot
 +
 +    root:
 +        Path to the root of the jail to use.
 +
 +    cmd:
 +        The command to run. ex: 'ls -lart /home'
 +
 +    cwd
 +        The current working directory to execute the command in, defaults to
 +        /root
 +
 +    stdin
 +        A string of standard input can be specified for the command to be run using
 +        the ``stdin`` parameter. This can be useful in cases where sensitive
 +        information must be read from standard input.:
 +
 +    runas
 +        User to run script as.
 +
 +    shell
 +        Shell to execute under. Defaults to the system default shell.
 +
 +    python_shell
 +        If False, let python handle the positional arguments. Set to True
 +        to use shell features, such as pipes or redirection
 +
 +    env
 +        A list of environment variables to be set prior to execution.
 +        Example:
 +
 +            salt://​scripts/​foo.sh:​
 +              cmd.script:
 +                - env:
 +                  - BATCH: '​yes'​
 +
 +        Warning:
 +
 +            The above illustrates a common PyYAML pitfall, that **yes**,
 +            **no**, **on**, **off**, **true**, and **false** are all loaded as
 +            boolean ``True`` and ``False`` values, and must be enclosed in
 +            quotes to be used as strings. More info on this (and other) PyYAML
 +            idiosyncrasies can be found :doc:`here
 +            </​topics/​troubleshooting/​yaml_idiosyncrasies>​`.
 +
 +        Variables as values are not evaluated. So $PATH in the following
 +        example is a literal '​$PATH':​
 +
 +            salt://​scripts/​bar.sh:​
 +              cmd.script:
 +                - env: "​PATH=/​some/​path:​$PATH"​
 +
 +        One can still use the existing $PATH by using a bit of Jinja:
 +
 +            {% set current_path = salt['​environ.get'​]('​PATH',​ '/​bin:/​usr/​bin'​) %}
 +
 +            mycommand:
 +              cmd.run:
 +                - name: ls -l /
 +                - env:
 +                  - PATH: {{ [current_path,​ '/​my/​special/​bin'​]|join(':'​) }}
 +
 +     ​clean_env:​
 +        Attempt to clean out all other shell environment variables and set
 +        only those provided in the '​env'​ argument to this function.
 +
 +    template
 +        If this setting is applied then the named templating engine will be
 +        used to render the downloaded file. Currently jinja, mako, and wempy
 +        are supported
 +
 +    rstrip
 +        Strip all whitespace off the end of output before it is returned.
 +
 +    umask
 +         The umask (in octal) to use when running the command.
 +
 +    output_loglevel
 +        Control the loglevel at which the output from the command is logged.
 +        Note that the command being run will still be logged (loglevel: DEBUG)
 +        regardless, unless ``quiet`` is used for this value.
 +
 +    timeout
 +        A timeout in seconds for the executed process to return.
 +
 +    use_vt
 +        Use VT utils (saltstack) to stream the command output more
 +        interactively to the console and the logs.
 +        This is experimental.
 +
 +
 +    CLI Example:
 +
 +        salt '​*'​ cmd.run_chroot /​var/​lib/​lxc/​container_name/​rootfs 'sh /​tmp/​bootstrap.sh'​
 +    ​
 +
 +cmd.run_stderr:​
 +
 +    Execute a command and only return the standard error
 +
 +    cmd:
 +        The command to run. ex: 'ls -lart /home'
 +
 +    cwd
 +        The current working directory to execute the command in, defaults to
 +        /root
 +
 +    stdin
 +        A string of standard input can be specified for the command to be run using
 +        the ``stdin`` parameter. This can be useful in cases where sensitive
 +        information must be read from standard input.:
 +
 +    runas
 +        User to run script as.
 +
 +    shell
 +        Shell to execute under. Defaults to the system default shell.
 +
 +    python_shell
 +        If False, let python handle the positional arguments. Set to True
 +        to use shell features, such as pipes or redirection
 +
 +    env
 +        A list of environment variables to be set prior to execution.
 +        Example:
 +
 +            salt://​scripts/​foo.sh:​
 +              cmd.script:
 +                - env:
 +                  - BATCH: '​yes'​
 +
 +        Warning:
 +
 +            The above illustrates a common PyYAML pitfall, that **yes**,
 +            **no**, **on**, **off**, **true**, and **false** are all loaded as
 +            boolean ``True`` and ``False`` values, and must be enclosed in
 +            quotes to be used as strings. More info on this (and other) PyYAML
 +            idiosyncrasies can be found :doc:`here
 +            </​topics/​troubleshooting/​yaml_idiosyncrasies>​`.
 +
 +        Variables as values are not evaluated. So $PATH in the following
 +        example is a literal '​$PATH':​
 +
 +            salt://​scripts/​bar.sh:​
 +              cmd.script:
 +                - env: "​PATH=/​some/​path:​$PATH"​
 +
 +        One can still use the existing $PATH by using a bit of Jinja:
 +
 +            {% set current_path = salt['​environ.get'​]('​PATH',​ '/​bin:/​usr/​bin'​) %}
 +
 +            mycommand:
 +              cmd.run:
 +                - name: ls -l /
 +                - env:
 +                  - PATH: {{ [current_path,​ '/​my/​special/​bin'​]|join(':'​) }}
 +
 +     ​clean_env:​
 +        Attempt to clean out all other shell environment variables and set
 +        only those provided in the '​env'​ argument to this function.
 +
 +    template
 +        If this setting is applied then the named templating engine will be
 +        used to render the downloaded file. Currently jinja, mako, and wempy
 +        are supported
 +
 +    rstrip
 +        Strip all whitespace off the end of output before it is returned.
 +
 +    umask
 +         The umask (in octal) to use when running the command.
 +
 +    output_loglevel
 +        Control the loglevel at which the output from the command is logged.
 +        Note that the command being run will still be logged (loglevel: DEBUG)
 +        regardless, unless ``quiet`` is used for this value.
 +
 +    timeout
 +        A timeout in seconds for the executed process to return.
 +
 +    use_vt
 +        Use VT utils (saltstack) to stream the command output more
 +        interactively to the console and the logs.
 +        This is experimental.
 +
 +    Note that ``env`` represents the environment variables for the command, and
 +    should be formatted as a dict, or a YAML string which resolves to a dict.
 +
 +    CLI Example:
 +
 +        salt '​*'​ cmd.run_stderr "ls -l | awk '/​foo/​{print \$2}'"​
 +
 +    The template arg can be set to '​jinja'​ or another supported template
 +    engine to render the command arguments before execution.
 +    For example:
 +
 +        salt '​*'​ cmd.run_stderr template=jinja "ls -l /​tmp/​{{grains.id}} | awk '/​foo/​{print \$2}'"​
 +
 +    A string of standard input can be specified for the command to be run using
 +    the ``stdin`` parameter. This can be useful in cases where sensitive
 +    information must be read from standard input.:
 +
 +        salt '​*'​ cmd.run_stderr "grep f" stdin='​one\ntwo\nthree\nfour\nfive\n'​
 +    ​
 +
 +cmd.run_stdout:​
 +
 +    Execute a command, and only return the standard out
 +
 +    cmd:
 +        The command to run. ex: 'ls -lart /home'
 +
 +    cwd
 +        The current working directory to execute the command in, defaults to
 +        /root
 +
 +    stdin
 +        A string of standard input can be specified for the command to be run using
 +        the ``stdin`` parameter. This can be useful in cases where sensitive
 +        information must be read from standard input.:
 +
 +    runas
 +        User to run script as.
 +
 +    shell
 +        Shell to execute under. Defaults to the system default shell.
 +
 +    python_shell
 +        If False, let python handle the positional arguments. Set to True
 +        to use shell features, such as pipes or redirection
 +
 +    env
 +        A list of environment variables to be set prior to execution.
 +        Example:
 +
 +            salt://​scripts/​foo.sh:​
 +              cmd.script:
 +                - env:
 +                  - BATCH: '​yes'​
 +
 +        Warning:
 +
 +            The above illustrates a common PyYAML pitfall, that **yes**,
 +            **no**, **on**, **off**, **true**, and **false** are all loaded as
 +            boolean ``True`` and ``False`` values, and must be enclosed in
 +            quotes to be used as strings. More info on this (and other) PyYAML
 +            idiosyncrasies can be found :doc:`here
 +            </​topics/​troubleshooting/​yaml_idiosyncrasies>​`.
 +
 +        Variables as values are not evaluated. So $PATH in the following
 +        example is a literal '​$PATH':​
 +
 +            salt://​scripts/​bar.sh:​
 +              cmd.script:
 +                - env: "​PATH=/​some/​path:​$PATH"​
 +
 +        One can still use the existing $PATH by using a bit of Jinja:
 +
 +            {% set current_path = salt['​environ.get'​]('​PATH',​ '/​bin:/​usr/​bin'​) %}
 +
 +            mycommand:
 +              cmd.run:
 +                - name: ls -l /
 +                - env:
 +                  - PATH: {{ [current_path,​ '/​my/​special/​bin'​]|join(':'​) }}
 +
 +     ​clean_env:​
 +        Attempt to clean out all other shell environment variables and set
 +        only those provided in the '​env'​ argument to this function.
 +
 +    template
 +        If this setting is applied then the named templating engine will be
 +        used to render the downloaded file. Currently jinja, mako, and wempy
 +        are supported
 +
 +    rstrip
 +        Strip all whitespace off the end of output before it is returned.
 +
 +    umask
 +         The umask (in octal) to use when running the command.
 +
 +    output_loglevel
 +        Control the loglevel at which the output from the command is logged.
 +        Note that the command being run will still be logged (loglevel: DEBUG)
 +        regardless, unless ``quiet`` is used for this value.
 +
 +    timeout
 +        A timeout in seconds for the executed process to return.
 +
 +    use_vt
 +        Use VT utils (saltstack) to stream the command output more
 +        interactively to the console and the logs.
 +        This is experimental.
 +
 +
 +    Note that ``env`` represents the environment variables for the command, and
 +    should be formatted as a dict, or a YAML string which resolves to a dict.
 +
 +    CLI Example:
 +
 +        salt '​*'​ cmd.run_stdout "ls -l | awk '/​foo/​{print \$2}'"​
 +
 +    The template arg can be set to '​jinja'​ or another supported template
 +    engine to render the command arguments before execution.
 +    For example:
 +
 +        salt '​*'​ cmd.run_stdout template=jinja "ls -l /​tmp/​{{grains.id}} | awk '/​foo/​{print \$2}'"​
 +
 +    A string of standard input can be specified for the command to be run using
 +    the ``stdin`` parameter. This can be useful in cases where sensitive
 +    information must be read from standard input.:
 +
 +        salt '​*'​ cmd.run_stdout "grep f" stdin='​one\ntwo\nthree\nfour\nfive\n'​
 +    ​
 +
 +cmd.script:
 +
 +    Download a script from a remote location and execute the script locally.
 +    The script can be located on the salt master file server or on an HTTP/FTP
 +    server.
 +
 +    The script will be executed directly, so it can be written in any available
 +    programming language.
 +
 +    source
 +        The location of the script to download. If the file is located on the
 +        master in the directory named spam, and is called eggs, the source
 +        string is salt://​spam/​eggs
 +
 +    args
 +        String of command line args to pass to the script. ​ Only used if no
 +        args are specified as part of the `name` argument. To pass a string
 +        containing spaces in YAML, you will need to doubly-quote it:  "arg1
 +        'arg two' arg3"
 +
 +    cwd
 +        The current working directory to execute the command in, defaults to
 +        /root
 +
 +    stdin
 +        A string of standard input can be specified for the command to be run using
 +        the ``stdin`` parameter. This can be useful in cases where sensitive
 +        information must be read from standard input.:
 +
 +    runas
 +        User to run script as.
 +
 +    shell
 +        Shell to execute under. Defaults to the system default shell.
 +
 +    python_shell
 +        If False, let python handle the positional arguments. Set to True
 +        to use shell features, such as pipes or redirection
 +
 +    env
 +        A list of environment variables to be set prior to execution.
 +        Example:
 +
 +            salt://​scripts/​foo.sh:​
 +              cmd.script:
 +                - env:
 +                  - BATCH: '​yes'​
 +
 +        Warning:
 +
 +            The above illustrates a common PyYAML pitfall, that **yes**,
 +            **no**, **on**, **off**, **true**, and **false** are all loaded as
 +            boolean ``True`` and ``False`` values, and must be enclosed in
 +            quotes to be used as strings. More info on this (and other) PyYAML
 +            idiosyncrasies can be found :doc:`here
 +            </​topics/​troubleshooting/​yaml_idiosyncrasies>​`.
 +
 +        Variables as values are not evaluated. So $PATH in the following
 +        example is a literal '​$PATH':​
 +
 +            salt://​scripts/​bar.sh:​
 +              cmd.script:
 +                - env: "​PATH=/​some/​path:​$PATH"​
 +
 +        One can still use the existing $PATH by using a bit of Jinja:
 +
 +            {% set current_path = salt['​environ.get'​]('​PATH',​ '/​bin:/​usr/​bin'​) %}
 +
 +            mycommand:
 +              cmd.run:
 +                - name: ls -l /
 +                - env:
 +                  - PATH: {{ [current_path,​ '/​my/​special/​bin'​]|join(':'​) }}
 +
 +    template
 +        If this setting is applied then the named templating engine will be
 +        used to render the downloaded file. Currently jinja, mako, and wempy
 +        are supported
 +
 +    umask
 +         The umask (in octal) to use when running the command.
 +
 +    output_loglevel
 +        Control the loglevel at which the output from the command is logged.
 +        Note that the command being run will still be logged (loglevel: DEBUG)
 +        regardless, unless ``quiet`` is used for this value.
 +
 +    quiet
 +        The command will be executed quietly, meaning no log entries of the
 +        actual command or its return data. This is deprecated as of the
 +        **2014.1.0** release, and is being replaced with
 +        ``output_loglevel:​ quiet``.
 +
 +    timeout
 +        If the command has not terminated after timeout seconds, send the
 +        subprocess sigterm, and if sigterm is ignored, follow up with sigkill
 +
 +    use_vt
 +        Use VT utils (saltstack) to stream the command output more
 +        interactively to the console and the logs.
 +        This is experimental.
 +
 +
 +    CLI Example:
 +
 +        salt '​*'​ cmd.script salt://​scripts/​runme.sh
 +        salt '​*'​ cmd.script salt://​scripts/​runme.sh 'arg1 arg2 "arg 3"'​
 +        salt '​*'​ cmd.script salt://​scripts/​windows_task.ps1 args=' -Input c:​\tmp\infile.txt'​ shell='​powershell'​
 +
 +
 +        salt '​*'​ cmd.script salt://​scripts/​runme.sh stdin='​one\ntwo\nthree\nfour\nfive\n'​
 +    ​
 +
 +cmd.script_retcode:​
 +
 +    Download a script from a remote location and execute the script locally.
 +    The script can be located on the salt master file server or on an HTTP/FTP
 +    server.
 +
 +    The script will be executed directly, so it can be written in any available
 +    programming language.
 +
 +    The script can also be formatted as a template, the default is jinja.
 +
 +    Only evaluate the script return code and do not block for terminal output
 +
 +    source
 +        The location of the script to download. If the file is located on the
 +        master in the directory named spam, and is called eggs, the source
 +        string is salt://​spam/​eggs
 +
 +    args
 +        String of command line args to pass to the script. ​ Only used if no
 +        args are specified as part of the `name` argument. To pass a string
 +        containing spaces in YAML, you will need to doubly-quote it:  "arg1
 +        'arg two' arg3"
 +
 +    cwd
 +        The current working directory to execute the command in, defaults to
 +        /root
 +
 +    stdin
 +        A string of standard input can be specified for the command to be run using
 +        the ``stdin`` parameter. This can be useful in cases where sensitive
 +        information must be read from standard input.:
 +
 +    runas
 +        User to run script as.
 +
 +    shell
 +        Shell to execute under. Defaults to the system default shell.
 +
 +    python_shell
 +        If False, let python handle the positional arguments. Set to True
 +        to use shell features, such as pipes or redirection
 +
 +    env
 +        A list of environment variables to be set prior to execution.
 +        Example:
 +
 +            salt://​scripts/​foo.sh:​
 +              cmd.script:
 +                - env:
 +                  - BATCH: '​yes'​
 +
 +        Warning:
 +
 +            The above illustrates a common PyYAML pitfall, that **yes**,
 +            **no**, **on**, **off**, **true**, and **false** are all loaded as
 +            boolean ``True`` and ``False`` values, and must be enclosed in
 +            quotes to be used as strings. More info on this (and other) PyYAML
 +            idiosyncrasies can be found :doc:`here
 +            </​topics/​troubleshooting/​yaml_idiosyncrasies>​`.
 +
 +        Variables as values are not evaluated. So $PATH in the following
 +        example is a literal '​$PATH':​
 +
 +            salt://​scripts/​bar.sh:​
 +              cmd.script:
 +                - env: "​PATH=/​some/​path:​$PATH"​
 +
 +        One can still use the existing $PATH by using a bit of Jinja:
 +
 +            {% set current_path = salt['​environ.get'​]('​PATH',​ '/​bin:/​usr/​bin'​) %}
 +
 +            mycommand:
 +              cmd.run:
 +                - name: ls -l /
 +                - env:
 +                  - PATH: {{ [current_path,​ '/​my/​special/​bin'​]|join(':'​) }}
 +
 +    template
 +        If this setting is applied then the named templating engine will be
 +        used to render the downloaded file. Currently jinja, mako, and wempy
 +        are supported
 +
 +    umask
 +         The umask (in octal) to use when running the command.
 +
 +    output_loglevel
 +        Control the loglevel at which the output from the command is logged.
 +        Note that the command being run will still be logged (loglevel: DEBUG)
 +        regardless, unless ``quiet`` is used for this value.
 +
 +    quiet
 +        The command will be executed quietly, meaning no log entries of the
 +        actual command or its return data. This is deprecated as of the
 +        **2014.1.0** release, and is being replaced with
 +        ``output_loglevel:​ quiet``.
 +
 +    timeout
 +        If the command has not terminated after timeout seconds, send the
 +        subprocess sigterm, and if sigterm is ignored, follow up with sigkill
 +
 +    use_vt
 +        Use VT utils (saltstack) to stream the command output more
 +        interactively to the console and the logs.
 +        This is experimental.
 +
 +
 +    CLI Example:
 +
 +        salt '​*'​ cmd.script_retcode salt://​scripts/​runme.sh
 +        salt '​*'​ cmd.script_retcode salt://​scripts/​runme.sh 'arg1 arg2 "arg 3"'​
 +        salt '​*'​ cmd.script_retcode salt://​scripts/​windows_task.ps1 args=' -Input c:​\tmp\infile.txt'​ shell='​powershell'​
 +
 +    A string of standard input can be specified for the command to be run using
 +    the ``stdin`` parameter. This can be useful in cases where sensitive
 +    information must be read from standard input.:
 +
 +        salt '​*'​ cmd.script_retcode salt://​scripts/​runme.sh stdin='​one\ntwo\nthree\nfour\nfive\n'​
 +    ​
 +
 +cmd.shell:
 +
 +    Execute the passed command and return the output as a string.
 +
 +    New in version 2015.5.0
 +
 +    cmd:
 +        The command to run. ex: 'ls -lart /home'
 +
 +    cwd
 +        The current working directory to execute the command in, defaults to
 +        /root
 +
 +    stdin
 +        A string of standard input can be specified for the command to be run using
 +        the ``stdin`` parameter. This can be useful in cases where sensitive
 +        information must be read from standard input.:
 +
 +    runas
 +        User to run script as.
 +
 +    shell
 +        Shell to execute under. Defaults to the system default shell.
 +
 +    env
 +        A list of environment variables to be set prior to execution.
 +        Example:
 +
 +            salt://​scripts/​foo.sh:​
 +              cmd.script:
 +                - env:
 +                  - BATCH: '​yes'​
 +
 +        Warning:
 +
 +            The above illustrates a common PyYAML pitfall, that **yes**,
 +            **no**, **on**, **off**, **true**, and **false** are all loaded as
 +            boolean ``True`` and ``False`` values, and must be enclosed in
 +            quotes to be used as strings. More info on this (and other) PyYAML
 +            idiosyncrasies can be found :doc:`here
 +            </​topics/​troubleshooting/​yaml_idiosyncrasies>​`.
 +
 +        Variables as values are not evaluated. So $PATH in the following
 +        example is a literal '​$PATH':​
 +
 +            salt://​scripts/​bar.sh:​
 +              cmd.script:
 +                - env: "​PATH=/​some/​path:​$PATH"​
 +
 +        One can still use the existing $PATH by using a bit of Jinja:
 +
 +            {% set current_path = salt['​environ.get'​]('​PATH',​ '/​bin:/​usr/​bin'​) %}
 +
 +            mycommand:
 +              cmd.run:
 +                - name: ls -l /
 +                - env:
 +                  - PATH: {{ [current_path,​ '/​my/​special/​bin'​]|join(':'​) }}
 +
 +     ​clean_env:​
 +        Attempt to clean out all other shell environment variables and set
 +        only those provided in the '​env'​ argument to this function.
 +
 +    template
 +        If this setting is applied then the named templating engine will be
 +        used to render the downloaded file. Currently jinja, mako, and wempy
 +        are supported
 +
 +    rstrip
 +        Strip all whitespace off the end of output before it is returned.
 +
 +    umask
 +         The umask (in octal) to use when running the command.
 +
 +    output_loglevel
 +        Control the loglevel at which the output from the command is logged.
 +        Note that the command being run will still be logged (loglevel: DEBUG)
 +        regardless, unless ``quiet`` is used for this value.
 +
 +    timeout
 +        A timeout in seconds for the executed process to return.
 +
 +    use_vt
 +        Use VT utils (saltstack) to stream the command output more
 +        interactively to the console and the logs.
 +        This is experimental.
 +
 +    Warning:
 +
 +        This passes the cmd argument directly to the shell
 +        without any further processing! Be absolutely sure that you
 +        have properly santized the command passed to this function
 +        and do not use untrusted inputs.
 +
 +    Note that ``env`` represents the environment variables for the command, and
 +    should be formatted as a dict, or a YAML string which resolves to a dict.
 +
 +    CLI Example:
 +
 +        salt '​*'​ cmd.shell "ls -l | awk '/​foo/​{print \$2}'"​
 +
 +    The template arg can be set to '​jinja'​ or another supported template
 +    engine to render the command arguments before execution.
 +    For example:
 +
 +        salt '​*'​ cmd.shell template=jinja "ls -l /​tmp/​{{grains.id}} | awk '/​foo/​{print \$2}'"​
 +
 +    Specify an alternate shell with the shell parameter:
 +
 +        salt '​*'​ cmd.shell "​Get-ChildItem C:\ " shell='​powershell'​
 +
 +    A string of standard input can be specified for the command to be run using
 +    the ``stdin`` parameter. This can be useful in cases where sensitive
 +    information must be read from standard input.:
 +
 +        salt '​*'​ cmd.shell "grep f" stdin='​one\ntwo\nthree\nfour\nfive\n'​
 +
 +    If an equal sign (``=``) appears in an argument to a Salt command it is
 +    interpreted as a keyword argument in the format ``key=val``. That
 +    processing can be bypassed in order to pass an equal sign through to the
 +    remote shell command by manually specifying the kwarg:
 +
 +        salt '​*'​ cmd.shell cmd='​sed -e s/​=/:/​g'​
 +    ​
 +
 +cmd.shells:
 +
 +    Lists the valid shells on this system via the /etc/shells file
 +
 +    New in version 2015.5.0
 +
 +    CLI Example::
 +
 +        salt '​*'​ cmd.shells
 +    ​
 +
 +cmd.tty:
 +
 +    Echo a string to a specific tty
 +
 +    CLI Example:
 +
 +        salt '​*'​ cmd.tty tty0 'This is a test'
 +        salt '​*'​ cmd.tty pts3 'This is a test'
 +    ​
 +
 +cmd.which:
 +
 +    Returns the path of an executable available on the minion, None otherwise
 +
 +    CLI Example:
 +
 +        salt '​*'​ cmd.which cat
 +    ​
 +
 +cmd.which_bin:​
 +
 +    Returns the first command found in a list of commands
 +
 +    CLI Example:
 +
 +        salt '​*'​ cmd.which_bin '​[pip2,​ pip, pip-python]'​
 +    ​
 +
 +composer.did_composer_install:​
 +
 +    Test to see if the vendor directory exists in this directory
 +
 +    dir
 +        Directory location of the composer.json file
 +
 +    CLI Example:
 +
 +        salt '​*'​ composer.did_composer_install /​var/​www/​application
 +    ​
 +
 +composer.install:​
 +
 +    Install composer dependencies for a directory.
 +
 +    If composer has not been installed globally making it available in the
 +    system PATH & making it executable, the ``composer`` and ``php`` parameters
 +    will need to be set to the location of the executables.
 +
 +    dir
 +        Directory location of the composer.json file.
 +
 +    composer
 +        Location of the composer.phar file. If not set composer will
 +        just execute "​composer"​ as if it is installed globally.
 +        (i.e. /​path/​to/​composer.phar)
 +
 +    php
 +        Location of the php executable to use with composer.
 +        (i.e. /​usr/​bin/​php)
 +
 +    runas
 +        Which system user to run composer as.
 +
 +    prefer_source
 +        --prefer-source option of composer.
 +
 +    prefer_dist
 +        --prefer-dist option of composer.
 +
 +    no_scripts
 +        --no-scripts option of composer.
 +
 +    no_plugins
 +        --no-plugins option of composer.
 +
 +    optimize
 +        --optimize-autoloader option of composer. Recommended for production.
 +
 +    no_dev
 +        --no-dev option for composer. Recommended for production.
 +
 +    quiet
 +        --quiet option for composer. Whether or not to return output from composer.
 +
 +    composer_home
 +        $COMPOSER_HOME environment variable
 +
 +    CLI Example:
 +
 +        salt '​*'​ composer.install /​var/​www/​application
 +
 +        salt '​*'​ composer.install /​var/​www/​application ​            ​no_dev=True optimize=True
 +    ​
 +
 +composer.selfupdate:​
 +
 +    Update composer itself.
 +
 +    If composer has not been installed globally making it available in the
 +    system PATH & making it executable, the ``composer`` and ``php`` parameters
 +    will need to be set to the location of the executables.
 +
 +    composer
 +        Location of the composer.phar file. If not set composer will
 +        just execute "​composer"​ as if it is installed globally.
 +        (i.e. /​path/​to/​composer.phar)
 +
 +    php
 +        Location of the php executable to use with composer.
 +        (i.e. /​usr/​bin/​php)
 +
 +    runas
 +        Which system user to run composer as.
 +
 +    quiet
 +        --quiet option for composer. Whether or not to return output from composer.
 +
 +    composer_home
 +        $COMPOSER_HOME environment variable
 +
 +    CLI Example:
 +
 +        salt '​*'​ composer.selfupdate
 +    ​
 +
 +composer.update:​
 +
 +    Update composer dependencies for a directory.
 +
 +    If `composer install` has not yet been run, this runs `composer install`
 +    instead.
 +
 +    If composer has not been installed globally making it available in the
 +    system PATH & making it executable, the ``composer`` and ``php`` parameters
 +    will need to be set to the location of the executables.
 +
 +    dir
 +        Directory location of the composer.json file.
 +
 +    composer
 +        Location of the composer.phar file. If not set composer will
 +        just execute "​composer"​ as if it is installed globally.
 +        (i.e. /​path/​to/​composer.phar)
 +
 +    php
 +        Location of the php executable to use with composer.
 +        (i.e. /​usr/​bin/​php)
 +
 +    runas
 +        Which system user to run composer as.
 +
 +    prefer_source
 +        --prefer-source option of composer.
 +
 +    prefer_dist
 +        --prefer-dist option of composer.
 +
 +    no_scripts
 +        --no-scripts option of composer.
 +
 +    no_plugins
 +        --no-plugins option of composer.
 +
 +    optimize
 +        --optimize-autoloader option of composer. Recommended for production.
 +
 +    no_dev
 +        --no-dev option for composer. Recommended for production.
 +
 +    quiet
 +        --quiet option for composer. Whether or not to return output from composer.
 +
 +    composer_home
 +        $COMPOSER_HOME environment variable
 +
 +    CLI Example:
 +
 +        salt '​*'​ composer.update /​var/​www/​application
 +
 +        salt '​*'​ composer.update /​var/​www/​application ​            ​no_dev=True optimize=True
 +    ​
 +
 +config.backup_mode:​
 +
 +    Return the backup mode
 +
 +    CLI Example:
 +
 +        salt '​*'​ config.backup_mode
 +    ​
 +
 +config.dot_vals:​
 +
 +    Pass in a configuration value that should be preceded by the module name
 +    and a dot, this will return a list of all read key/value pairs
 +
 +    CLI Example:
 +
 +        salt '​*'​ config.dot_vals host
 +    ​
 +
 +config.gather_bootstrap_script:​
 +
 +    Download the salt-bootstrap script, and return its location
 +
 +    bootstrap
 +        URL of alternate bootstrap script
 +
 +    CLI Example:
 +
 +        salt '​*'​ config.gather_bootstrap_script
 +    ​
 +
 +config.get:
 +
 +    .. versionadded:​ 0.14.0
 +
 +    Attempt to retrieve the named value from the minion config file, pillar,
 +    grains or the master config. If the named value is not available, return the
 +    value specified by ``default``. If not specified, the default is an empty
 +    string.
 +
 +    Values can also be retrieved from nested dictionaries. Assume the below
 +    data structure:
 +
 +        {'​pkg':​ {'​apache':​ '​httpd'​}}
 +
 +    To retrieve the value associated with the ``apache`` key, in the
 +    sub-dictionary corresponding to the ``pkg`` key, the following command can
 +    be used:
 +
 +        salt myminion config.get pkg:apache
 +
 +    The ``:`` (colon) is used to represent a nested dictionary level.
 +
 +    Changed in version 2015.5.0
 +        The ``delimiter`` argument was added, to allow delimiters other than
 +        ``:`` to be used.
 +
 +    This function traverses these data stores in this order, returning the
 +    first match found:
 +
 +    - Minion config file
 +    - Minion'​s grains
 +    - Minion'​s pillar data
 +    - Master config file
 +
 +    This means that if there is a value that is going to be the same for the
 +    majority of minions, it can be configured in the Master config file, and
 +    then overridden using the grains, pillar, or Minion config file.
 +
 +    **Arguments**
 +
 +    delimiter
 +        New in version 2015.5.0
 +
 +        Override the delimiter used to separate nested levels of a data
 +        structure.
 +
 +    merge
 +        New in version 2015.5.0
 +
 +        If passed, this parameter will change the behavior of the function so
 +        that, instead of traversing each data store above in order and
 +        returning the first match, the data stores are first merged together
 +        and then searched. The pillar data is merged into the master config
 +        data, then the grains are merged, followed by the Minion config data.
 +        The resulting data structure is then searched for a match. This allows
 +        for configurations to be more flexible.
 +
 +        Note:
 +
 +            The merging described above does not mean that grain data will end
 +            up in the Minion'​s pillar data, or pillar data will end up in the
 +            master config data, etc. The data is just combined for the purposes
 +            of searching an amalgam of the different data stores.
 +
 +        The supported merge strategies are as follows:
 +
 +        - **recurse** - If a key exists in both dictionaries,​ and the new value
 +          is not a dictionary, it is replaced. Otherwise, the sub-dictionaries
 +          are merged together into a single dictionary, recursively on down,
 +          following the same criteria. For example:
 +
 +              >>>​ dict1 = {'​foo':​ {'​bar':​ 1, '​qux':​ True},
 +                           '​hosts':​ ['​a',​ '​b',​ '​c'​],​
 +                           '​only_x':​ None}
 +              >>>​ dict2 = {'​foo':​ {'​baz':​ 2, '​qux':​ False},
 +                           '​hosts':​ ['​d',​ '​e',​ '​f'​],​
 +                           '​only_y':​ None}
 +              >>>​ merged
 +              {'​foo':​ {'​bar':​ 1, '​baz':​ 2, '​qux':​ False},
 +               '​hosts':​ ['​d',​ '​e',​ '​f'​],​
 +               '​only_dict1':​ None,
 +               '​only_dict2':​ None}
 +
 +        - **overwrite** - If a key exists in the top level of both
 +          dictionaries,​ the new value completely overwrites the old. For
 +          example:
 +
 +              >>>​ dict1 = {'​foo':​ {'​bar':​ 1, '​qux':​ True},
 +                           '​hosts':​ ['​a',​ '​b',​ '​c'​],​
 +                           '​only_x':​ None}
 +              >>>​ dict2 = {'​foo':​ {'​baz':​ 2, '​qux':​ False},
 +                           '​hosts':​ ['​d',​ '​e',​ '​f'​],​
 +                           '​only_y':​ None}
 +              >>>​ merged
 +              {'​foo':​ {'​baz':​ 2, '​qux':​ False},
 +               '​hosts':​ ['​d',​ '​e',​ '​f'​],​
 +               '​only_dict1':​ None,
 +               '​only_dict2':​ None}
 +
 +    CLI Example:
 +
 +        salt '​*'​ config.get pkg:apache
 +        salt '​*'​ config.get lxc.container_profile:​centos merge=recurse
 +    ​
 +
 +config.manage_mode:​
 +
 +    Return a mode value, normalized to a string
 +
 +    CLI Example:
 +
 +        salt '​*'​ config.manage_mode
 +    ​
 +
 +config.merge:​
 +
 +    Retrieves an option based on key, merging all matches.
 +
 +    Same as ``option()`` except that it merges all matches, rather than taking
 +    the first match.
 +
 +    CLI Example:
 +
 +        salt '​*'​ config.merge schedule
 +    ​
 +
 +config.option:​
 +
 +    Pass in a generic option and receive the value that will be assigned
 +
 +    CLI Example:
 +
 +        salt '​*'​ config.option redis.host
 +    ​
 +
 +config.valid_fileproto:​
 +
 +    Returns a boolean value based on whether or not the URI passed has a valid
 +    remote file protocol designation
 +
 +    CLI Example:
 +
 +        salt '​*'​ config.valid_fileproto salt://​path/​to/​file
 +    ​
 +
 +consul.acl_clone:​
 +
 +    Information about an ACL token.
 +
 +    :param consul_url: The Consul server URL.
 +    :param id: Unique identifier for the ACL to update.
 +    :return: Boolean, message of success or
 +             ​failure,​ and new ID of cloned ACL.
 +
 +    CLI Example:
 +
 +        salt '​*'​ consul.acl_info id='​c1c4d223-91cb-3d1f-1ee8-f2af9e7b6716'​
 +
 +    ​
 +
 +consul.acl_create:​
 +
 +    Create a new ACL token.
 +
 +    :param consul_url: The Consul server URL.
 +    :param name: Meaningful indicator of the ACL's purpose.
 +    :param type: Type is either client or management. A management
 +                 token is comparable to a root user and has the
 +                 ​ability to perform any action including creating,
 +                 ​modifying,​ and deleting ACLs.
 +    :param rules: The Consul server URL.
 +    :return: Boolean & message of success or failure.
 +
 +    CLI Example:
 +
 +        salt '​*'​ consul.acl_create
 +
 +    ​
 +
 +consul.acl_delete:​
 +
 +    Delete an ACL token.
 +
 +    :param consul_url: The Consul server URL.
 +    :param id: Unique identifier for the ACL to update.
 +    :return: Boolean & message of success or failure.
 +
 +    CLI Example:
 +
 +        salt '​*'​ consul.acl_delete id='​c1c4d223-91cb-3d1f-1ee8-f2af9e7b6716'​
 +
 +    ​
 +
 +consul.acl_info:​
 +
 +    Information about an ACL token.
 +
 +    :param consul_url: The Consul server URL.
 +    :param id: Unique identifier for the ACL to update.
 +    :return: Information about the ACL requested.
 +
 +    CLI Example:
 +
 +        salt '​*'​ consul.acl_info id='​c1c4d223-91cb-3d1f-1ee8-f2af9e7b6716'​
 +
 +    ​
 +
 +consul.acl_list:​
 +
 +    List the ACL tokens.
 +
 +    :param consul_url: The Consul server URL.
 +    :return: List of ACLs
 +
 +    CLI Example:
 +
 +        salt '​*'​ consul.acl_list
 +
 +    ​
 +
 +consul.acl_update:​
 +
 +    Update an ACL token.
 +
 +    :param consul_url: The Consul server URL.
 +    :param name: Meaningful indicator of the ACL's purpose.
 +    :param id: Unique identifier for the ACL to update.
 +    :param type: Type is either client or management. A management
 +                 token is comparable to a root user and has the
 +                 ​ability to perform any action including creating,
 +                 ​modifying,​ and deleting ACLs.
 +    :param rules: The Consul server URL.
 +    :return: Boolean & message of success or failure.
 +
 +    CLI Example:
 +
 +        salt '​*'​ consul.acl_update
 +
 +    ​
 +
 +consul.agent_check_deregister:​
 +
 +    The agent will take care of deregistering the check from the Catalog.
 +
 +    :param consul_url: The Consul server URL.
 +    :param checkid: The ID of the check to deregister from Consul.
 +    :return: Boolean and message indicating success or failure.
 +
 +    CLI Example:
 +
 +        salt '​*'​ consul.agent_check_deregister checkid='​Memory Utilization'​
 +
 +    ​
 +
 +consul.agent_check_fail:​
 +
 +    This endpoint is used with a check that is of the TTL type. When this
 +    is called, the status of the check is set to critical and the
 +    TTL clock is reset.
 +
 +    :param consul_url: The Consul server URL.
 +    :param checkid: The ID of the check to deregister from Consul.
 +    :param note: A human-readable message with the status of the check.
 +    :return: Boolean and message indicating success or failure.
 +
 +    CLI Example:
 +
 +        salt '​*'​ consul.agent_check_fail checkid='​redis_check1'​
 +                note='​Forcing check into critical state.'​
 +
 +    ​
 +
 +consul.agent_check_pass:​
 +
 +    This endpoint is used with a check that is of the TTL type. When this
 +    is called, the status of the check is set to passing and the TTL
 +    clock is reset.
 +
 +    :param consul_url: The Consul server URL.
 +    :param checkid: The ID of the check to mark as passing.
 +    :param note: A human-readable message with the status of the check.
 +    :return: Boolean and message indicating success or failure.
 +
 +    CLI Example:
 +
 +        salt '​*'​ consul.agent_check_pass checkid='​redis_check1'​
 +                note='​Forcing check into passing state.'​
 +
 +    ​
 +
 +consul.agent_check_register:​
 +
 +    The register endpoint is used to add a new check to the local agent.
 +
 +    :param consul_url: The Consul server URL.
 +    :param name: The description of what the check is for.
 +    :param id: The unique name to use for the check, if not
 +               ​provided '​name'​ is used.
 +    :param notes: Human readable description of the check.
 +    :param script: If script is provided, the check type is
 +                   a script, and Consul will evaluate that script
 +                   based on the interval parameter.
 +    :param http: Check will perform an HTTP GET request against
 +                 the value of HTTP (expected to be a URL) based
 +                 on the interval parameter.
 +    :param ttl: If a TTL type is used, then the TTL update endpoint
 +                must be used periodically to update the state of the check.
 +    :param interval: Interval at which the check should run.
 +    :return: Boolean and message indicating success or failure.
 +
 +    CLI Example:
 +
 +        salt '​*'​ consul.agent_check_register name='​Memory Utilization'​
 +                script='/​usr/​local/​bin/​check_mem.py'​ interval='​15s'​
 +
 +    ​
 +
 +consul.agent_check_warn:​
 +
 +    This endpoint is used with a check that is of the TTL type. When this
 +    is called, the status of the check is set to warning and the TTL
 +    clock is reset.
 +
 +    :param consul_url: The Consul server URL.
 +    :param checkid: The ID of the check to deregister from Consul.
 +    :param note: A human-readable message with the status of the check.
 +    :return: Boolean and message indicating success or failure.
 +
 +    CLI Example:
 +
 +        salt '​*'​ consul.agent_check_warn checkid='​redis_check1'​
 +                note='​Forcing check into warning state.'​
 +
 +    ​
 +
 +consul.agent_checks:​
 +
 +    Returns the checks the local agent is managing
 +
 +    :param consul_url: The Consul server URL.
 +    :return: Returns the checks the local agent is managing
 +
 +    CLI Example:
 +
 +        salt '​*'​ consul.agent_checks
 +
 +    ​
 +
 +consul.agent_join:​
 +
 +    Triggers the local agent to join a node
 +
 +    :param consul_url: The Consul server URL.
 +    :param address: The address for the agent to connect to.
 +    :param wan: Causes the agent to attempt to join using the WAN pool.
 +    :return: Boolean and message indicating success or failure.
 +
 +    CLI Example:
 +
 +        salt '​*'​ consul.agent_join address='​192.168.1.1'​
 +
 +    ​
 +
 +consul.agent_leave:​
 +
 +    Used to instruct the agent to force a node into the left state.
 +
 +    :param consul_url: The Consul server URL.
 +    :param node: The node the agent will force into left state
 +    :return: Boolean and message indicating success or failure.
 +
 +    CLI Example:
 +
 +        salt '​*'​ consul.agent_leave node='​web1.example.com'​
 +
 +    ​
 +
 +consul.agent_maintenance:​
 +
 +    Manages node maintenance mode
 +
 +    :param consul_url: The Consul server URL.
 +    :param enable: The enable flag is required.
 +                   ​Acceptable values are either true
 +                   (to enter maintenance mode) or
 +                   false (to resume normal operation).
 +    :param reason: If provided, its value should be a
 +                   text string explaining the reason for
 +                   ​placing the node into maintenance mode.
 +    :return: Boolean and message indicating success or failure.
 +
 +    CLI Example:
 +
 +        salt '​*'​ consul.agent_maintenance enable='​False'​ reason='​Upgrade in progress'​
 +
 +    ​
 +
 +consul.agent_members:​
 +
 +    Returns the members as seen by the local serf agent
 +
 +    :param consul_url: The Consul server URL.
 +    :return: Returns the members as seen by the local serf agent
 +
 +    CLI Example:
 +
 +        salt '​*'​ consul.agent_members
 +
 +    ​
 +
 +consul.agent_self:​
 +
 +    Returns the local node configuration
 +
 +    :param consul_url: The Consul server URL.
 +    :return: Returns the local node configuration
 +
 +    CLI Example:
 +
 +        salt '​*'​ consul.agent_self
 +
 +    ​
 +
 +consul.agent_service_deregister:​
 +
 +    Used to remove a service.
 +
 +    :param consul_url: The Consul server URL.
 +    :param serviceid: A serviceid describing the service.
 +    :return: Boolean and message indicating success or failure.
 +
 +    CLI Example:
 +
 +        salt '​*'​ consul.agent_service_deregister serviceid='​redis'​
 +
 +    ​
 +
 +consul.agent_service_maintenance:​
 +
 +    Used to place a service into maintenance mode.
 +
 +    :param consul_url: The Consul server URL.
 +    :param serviceid: A name of the service.
 +    :param enable: Whether the service should be enabled or disabled.
 +    :param reason: A human readable message of why the service was
 +                   ​enabled or disabled.
 +    :return: Boolean and message indicating success or failure.
 +
 +    CLI Example:
 +
 +        salt '​*'​ consul.agent_service_deregister serviceid='​redis'​
 +                enable='​True'​ reason='​Down for upgrade'​
 +
 +    ​
 +
 +consul.agent_service_register:​
 +
 +    The used to add a new service, with an optional
 +    health check, to the local agent.
 +
 +    :param consul_url: The Consul server URL.
 +    :param name: A name describing the service.
 +    :param address: The address used by the service, defaults
 +                    to the address of the agent.
 +    :param port: The port used by the service.
 +    :param id: Unique ID to identify the service, if not
 +               ​provided the value of the name parameter is used.
 +    :param tags: Identifying tags for service, string or list.
 +    :param script: If script is provided, the check type is
 +                   a script, and Consul will evaluate that script
 +                   based on the interval parameter.
 +    :param http: Check will perform an HTTP GET request against
 +                 the value of HTTP (expected to be a URL) based
 +                 on the interval parameter.
 +    :param check_ttl: If a TTL type is used, then the TTL update
 +                      endpoint must be used periodically to update
 +                      the state of the check.
 +    :param check_interval:​ Interval at which the check should run.
 +    :return: Boolean and message indicating success or failure.
 +
 +    CLI Example:
 +
 +        salt '​*'​ consul.agent_service_register name='​redis'​
 +            tags='​["​master",​ "​v1"​]'​ address="​127.0.0.1"​ port="​8080"​
 +            check_script="/​usr/​local/​bin/​check_redis.py"​ interval="​10s"​
 +
 +    ​
 +
 +consul.agent_services:​
 +
 +    Returns the services the local agent is managing
 +
 +    :param consul_url: The Consul server URL.
 +    :return: Returns the services the local agent is managing
 +
 +    CLI Example:
 +
 +        salt '​*'​ consul.agent_services
 +
 +    ​
 +
 +consul.catalog_datacenters:​
 +
 +    Return list of available datacenters from catalog.
 +
 +    :param consul_url: The Consul server URL.
 +    :return: The list of available datacenters.
 +
 +    CLI Example:
 +
 +        salt '​*'​ consul.catalog_datacenters
 +
 +    ​
 +
 +consul.catalog_deregister:​
 +
 +    Deregisters a node, service, or check
 +
 +    :param consul_url: The Consul server URL.
 +    :param node: The node to deregister.
 +    :param datacenter: By default, the datacenter of the agent is queried;
 +               ​however,​ the dc can be provided using the "​dc"​ parameter.
 +    :param checkid: The ID of the health check to deregister.
 +    :param serviceid: The ID of the service to deregister.
 +    :return: Boolean & message of success or failure.
 +
 +    CLI Example:
 +
 +        salt '​*'​ consul.catalog_register node='​node1'​
 +            serviceid='​redis_server1'​ checkid='​redis_check1'​
 +
 +    ​
 +
 +consul.catalog_node:​
 +
 +    Information about the registered node.
 +
 +    :param consul_url: The Consul server URL.
 +    :param node: The node to request information about.
 +    :param dc: By default, the datacenter of the agent is queried;
 +               ​however,​ the dc can be provided using the "​dc"​ parameter.
 +    :return: Information about the requested node.
 +
 +    CLI Example:
 +
 +        salt '​*'​ consul.catalog_service service='​redis'​
 +
 +    ​
 +
 +consul.catalog_nodes:​
 +
 +    Return list of available nodes from catalog.
 +
 +    :param consul_url: The Consul server URL.
 +    :param dc: By default, the datacenter of the agent is queried;
 +               ​however,​ the dc can be provided using the "​dc"​ parameter.
 +    :return: The list of available nodes.
 +
 +    CLI Example:
 +
 +        salt '​*'​ consul.catalog_nodes
 +
 +    ​
 +
 +consul.catalog_register:​
 +
 +    Registers a new node, service, or check
 +
 +    :param consul_url: The Consul server URL.
 +    :param dc: By default, the datacenter of the agent is queried;
 +               ​however,​ the dc can be provided using the "​dc"​ parameter.
 +    :param node: The node to register.
 +    :param address: The address of the node.
 +    :param service: The service that will be registered.
 +    :param service_address:​ The address that the service listens on.
 +    :param service_port:​ The port for the service.
 +    :param service_id: A unique identifier for the service, if this is not
 +                       ​provided "​name"​ will be used.
 +    :param service_tags:​ Any tags associated with the service.
 +    :param check: The name of the health check to register
 +    :param check_status:​ The initial status of the check,
 +                         must be one of unknown, passing, warning, or critical.
 +    :param check_service:​ The service that the check is performed against.
 +    :param check_id: Unique identifier for the service.
 +    :param check_notes:​ An opaque field that is meant to hold human-readable text.
 +    :return: Boolean & message of success or failure.
 +
 +    CLI Example:
 +
 +        salt '​*'​ consul.catalog_register node='​node1'​ address='​192.168.1.1'​
 +            service='​redis'​ service_address='​127.0.0.1'​ service_port='​8080'​
 +            service_id='​redis_server1'​
 +
 +    ​
 +
 +consul.catalog_service:​
 +
 +    Information about the registered service.
 +
 +    :param consul_url: The Consul server URL.
 +    :param dc: By default, the datacenter of the agent is queried;
 +               ​however,​ the dc can be provided using the "​dc"​ parameter.
 +    :param tag: Filter returned services with tag parameter.
 +    :return: Information about the requested service.
 +
 +    CLI Example:
 +
 +        salt '​*'​ consul.catalog_service service='​redis'​
 +
 +    ​
 +
 +consul.catalog_services:​
 +
 +    Return list of available services rom catalog.
 +
 +    :param consul_url: The Consul server URL.
 +    :param dc: By default, the datacenter of the agent is queried;
 +               ​however,​ the dc can be provided using the "​dc"​ parameter.
 +    :return: The list of available services.
 +
 +    CLI Example:
 +
 +        salt '​*'​ consul.catalog_services
 +
 +    ​
 +
 +consul.delete:​
 +
 +    Delete values from Consul
 +
 +    :param consul_url: The Consul server URL.
 +    :param key: The key to use as the starting point for the list.
 +    :param recurse: Delete values recursively beginning at the value of key.
 +    :param cas: This flag is used to turn the DELETE into
 +                a Check-And-Set operation.
 +    :return: Boolean & message of success or failure.
 +
 +    CLI Example:
 +
 +        salt '​*'​ consul.delete key='​web'​
 +
 +        salt '​*'​ consul.delete key='​web'​ recurse='​True'​
 +
 +    ​
 +
 +consul.event_fire:​
 +
 +    List the ACL tokens.
 +
 +    :param consul_url: The Consul server URL.
 +    :param name: The name of the event to fire.
 +    :param dc: By default, the datacenter of the agent is queried;
 +               ​however,​ the dc can be provided using the "​dc"​ parameter.
 +    :param node: Filter by node name.
 +    :param service: Filter by service name.
 +    :param tag: Filter by tag name.
 +    :return: List of ACLs
 +
 +    CLI Example:
 +
 +        salt '​*'​ consul.event_fire name='​deploy'​
 +
 +    ​
 +
 +consul.event_list:​
 +
 +    List the recent events.
 +
 +    :param consul_url: The Consul server URL.
 +    :param name: The name of the event to fire.
 +    :return: List of ACLs
 +
 +    CLI Example:
 +
 +        salt '​*'​ consul.event_list
 +
 +    ​
 +
 +consul.get:
 +
 +    Get key from Consul
 +
 +    :param consul_url: The Consul server URL.
 +    :param key: The key to use as the starting point for the list.
 +    :param recurse: Return values recursively beginning at the value of key.
 +    :param decode: By default values are stored as Base64 encoded values,
 +                   ​decode will return the whole key with the value decoded.
 +    :param raw: Simply return the decoded value of the key.
 +    :return: The keys in Consul.
 +
 +    CLI Example:
 +
 +        salt '​*'​ consul.get key='​web/​key1'​
 +
 +        salt '​*'​ consul.list key='​web'​ recurse='​True
 +
 +        salt '​*'​ consul.list key='​web'​ recurse='​True'​ decode='​True'​
 +
 +    By default values stored in Consul are base64 encoded, passing the
 +    decode option will show them as the decoded values.
 +
 +        salt '​*'​ consul.list key='​web'​ recurse='​True'​ decode='​True'​ raw='​True'​
 +
 +    By default Consult will return other information about the key, the raw
 +    option will return only the raw value.
 +
 +    ​
 +
 +consul.health_checks:​
 +
 +    Health information about the registered service.
 +
 +    :param consul_url: The Consul server URL.
 +    :param service: The service to request health information about.
 +    :param dc: By default, the datacenter of the agent is queried;
 +               ​however,​ the dc can be provided using the "​dc"​ parameter.
 +    :return: Health information about the requested node.
 +
 +    CLI Example:
 +
 +        salt '​*'​ consul.health_checks service='​redis1'​
 +
 +    ​
 +
 +consul.health_node:​
 +
 +    Health information about the registered node.
 +
 +    :param consul_url: The Consul server URL.
 +    :param node: The node to request health information about.
 +    :param dc: By default, the datacenter of the agent is queried;
 +               ​however,​ the dc can be provided using the "​dc"​ parameter.
 +    :return: Health information about the requested node.
 +
 +    CLI Example:
 +
 +        salt '​*'​ consul.health_node node='​node1'​
 +
 +    ​
 +
 +consul.health_service:​
 +
 +    Health information about the registered service.
 +
 +    :param consul_url: The Consul server URL.
 +    :param service: The service to request health information about.
 +    :param dc: By default, the datacenter of the agent is queried;
 +               ​however,​ the dc can be provided using the "​dc"​ parameter.
 +    :param tag: Filter returned services with tag parameter.
 +    :param passing: Filter results to only nodes with all
 +                    checks in the passing state.
 +    :return: Health information about the requested node.
 +
 +    CLI Example:
 +
 +        salt '​*'​ consul.health_service service='​redis1'​
 +
 +        salt '​*'​ consul.health_service service='​redis1'​ passing='​True'​
 +
 +    ​
 +
 +consul.health_state:​
 +
 +    Returns the checks in the state provided on the path.
 +
 +    :param consul_url: The Consul server URL.
 +    :param state: The state to show checks for. The supported states
 +                  are any, unknown, passing, warning, or critical.
 +                  The any state is a wildcard that can be used to
 +                  return all checks.
 +    :param dc: By default, the datacenter of the agent is queried;
 +               ​however,​ the dc can be provided using the "​dc"​ parameter.
 +    :return: The checks in the provided state.
 +
 +    CLI Example:
 +
 +        salt '​*'​ consul.health_state state='​redis1'​
 +
 +        salt '​*'​ consul.health_state service='​redis1'​ passing='​True'​
 +
 +    ​
 +
 +consul.list:​
 +
 +    List keys in Consul
 +
 +    :param consul_url: The Consul server URL.
 +    :param key: The key to use as the starting point for the list.
 +    :return: The list of keys.
 +
 +    CLI Example:
 +
 +        salt '​*'​ consul.list
 +
 +        salt '​*'​ consul.list key='​web'​
 +
 +    ​
 +
 +consul.put:
 +
 +    Put values into Consul
 +
 +    :param consul_url: The Consul server URL.
 +    :param key: The key to use as the starting point for the list.
 +    :param value: The value to set the key to.
 +    :param flags: This can be used to specify an unsigned value
 +                  between 0 and 2^64-1. Clients can choose to use
 +                  this however makes sense for their application.
 +    :param cas: This flag is used to turn the PUT into a
 +                Check-And-Set operation.
 +    :param acquire: This flag is used to turn the PUT into a
 +                    lock acquisition operation.
 +    :param release: This flag is used to turn the PUT into a
 +                    lock release operation.
 +    :return: Boolean & message of success or failure.
 +
 +    CLI Example:
 +
 +        salt '​*'​ consul.put key='​web/​key1'​ value="​Hello there"
 +
 +        salt '​*'​ consul.put key='​web/​key1'​ value="​Hello there"
 +                                acquire='​d5d371f4-c380-5280-12fd-8810be175592'​
 +
 +        salt '​*'​ consul.put key='​web/​key1'​ value="​Hello there"
 +                                release='​d5d371f4-c380-5280-12fd-8810be175592'​
 +
 +    ​
 +
 +consul.session_create:​
 +
 +    Used to create a session.
 +
 +    :param consul_url: The Consul server URL.
 +    :param lockdelay: Duration string using a "​s"​ suffix for seconds.
 +                      The default is 15s.
 +    :param node: Must refer to a node that is already registered,
 +                 if specified. By default, the agent'​s own node
 +                 name is used.
 +    :param name: A human-readable name for the session
 +    :param checks: A list of associated health checks. It is highly
 +                   ​recommended that, if you override this list, you
 +                   ​include the default "​serfHealth"​.
 +    :param behavior: Can be set to either release or delete. This controls
 +                     the behavior when a session is invalidated. By default,
 +                     this is release, causing any locks that are held to be
 +                     ​released. Changing this to delete causes any locks that
 +                     are held to be deleted. delete is useful for creating
 +                     ​ephemeral key/value entries.
 +    :param ttl: Session is invalidated if it is not renewed before
 +                the TTL expires
 +    :return: Boolean and message indicating success or failure.
 +
 +    CLI Example:
 +
 +        salt '​*'​ consul.session_create node='​node1'​ name='​my-session'​
 +                behavior='​delete'​ ttl='​3600s'​
 +
 +    ​
 +
 +consul.session_destroy:​
 +
 +    Destroy session
 +
 +    :param consul_url: The Consul server URL.
 +    :param session: The ID of the session to destroy.
 +    :param dc: By default, the datacenter of the agent is queried;
 +               ​however,​ the dc can be provided using the "​dc"​ parameter.
 +    :return: Boolean & message of success or failure.
 +
 +    CLI Example:
 +
 +        salt '​*'​ consul.session_destroy session='​c1c4d223-91cb-3d1f-1ee8-f2af9e7b6716'​
 +
 +    ​
 +
 +consul.session_info:​
 +
 +    Information about a session
 +
 +    :param consul_url: The Consul server URL.
 +    :param session: The ID of the session to return information about.
 +    :param dc: By default, the datacenter of the agent is queried;
 +               ​however,​ the dc can be provided using the "​dc"​ parameter.
 +    :return: Boolean & message of success or failure.
 +
 +    CLI Example:
 +
 +        salt '​*'​ consul.session_info session='​c1c4d223-91cb-3d1f-1ee8-f2af9e7b6716'​
 +
 +    ​
 +
 +consul.session_list:​
 +
 +    Used to list sessions.
 +
 +    :param consul_url: The Consul server URL.
 +    :param dc: By default, the datacenter of the agent is queried;
 +               ​however,​ the dc can be provided using the "​dc"​ parameter.
 +    :param return_list:​ By default, all information about the sessions is
 +                        returned, using the return_list parameter will return
 +                        a list of session IDs.
 +    :return: A list of all available sessions.
 +
 +    CLI Example:
 +
 +        salt '​*'​ consul.session_list
 +
 +    ​
 +
 +consul.status_leader:​
 +
 +    Returns the current Raft leader
 +
 +    :param consul_url: The Consul server URL.
 +    :return: The address of the Raft leader.
 +
 +    CLI Example:
 +
 +        salt '​*'​ consul.status_leader
 +
 +    ​
 +
 +consul.status_peers:​
 +
 +    Returns the current Raft peer set
 +
 +    :param consul_url: The Consul server URL.
 +    :return: Retrieves the Raft peers for the
 +             ​datacenter in which the the agent is running.
 +
 +    CLI Example:
 +
 +        salt '​*'​ consul.status_peers
 +
 +    ​
 +
 +container_resource.cache_file:​
 +
 +    Wrapper for cp.cache_file which raises an error if the file was unable to
 +    be cached.
 +
 +    CLI Example:
 +
 +        salt myminion container_resource.cache_file salt://​foo/​bar/​baz.txt
 +    ​
 +
 +container_resource.copy_to:​
 +
 +    Common logic for copying files to containers
 +
 +    path
 +        path to the container parent (for LXC only)
 +        default: /​var/​lib/​lxc (system default)
 +
 +    CLI Example:
 +
 +        salt myminion container_resource.copy_to mycontainer /​local/​file/​path /​container/​file/​path container_type=docker exec_driver=nsenter
 +    ​
 +
 +container_resource.run:​
 +
 +    Common logic for running shell commands in containers
 +
 +    path
 +        path to the container parent (for LXC only)
 +        default: /​var/​lib/​lxc (system default)
 +
 +    CLI Example:
 +
 +        salt myminion container_resource.run mycontainer 'ps aux' container_type=docker exec_driver=nsenter output=stdout
 +    ​
 +
 +cp.cache_dir:​
 +
 +    Download and cache everything under a directory from the master
 +
 +
 +    include_pat : None
 +        Glob or regex to narrow down the files cached from the given path. If
 +        matching with a regex, the regex must be prefixed with ``E@``,
 +        otherwise the expression will be interpreted as a glob.
 +
 +        New in version 2014.7.0
 +
 +    exclude_pat : None
 +        Glob or regex to exclude certain files from being cached from the given
 +        path. If matching with a regex, the regex must be prefixed with ``E@``,
 +        otherwise the expression will be interpreted as a glob.
 +
 +        Note:
 +
 +            If used with ``include_pat``,​ files matching this pattern will be
 +            excluded from the subset of files defined by ``include_pat``.
 +
 +        New in version 2014.7.0
 +
 +
 +    CLI Examples:
 +
 +        salt '​*'​ cp.cache_dir salt://​path/​to/​dir
 +        salt '​*'​ cp.cache_dir salt://​path/​to/​dir include_pat='​E@*.py$'​
 +    ​
 +
 +cp.cache_file:​
 +
 +    Used to cache a single file on the salt-minion
 +    Returns the location of the new cached file on the minion
 +
 +    CLI Example:
 +
 +        salt '​*'​ cp.cache_file salt://​path/​to/​file
 +    ​
 +
 +cp.cache_files:​
 +
 +    Used to gather many files from the master, the gathered files will be
 +    saved in the minion cachedir reflective to the paths retrieved from the
 +    master.
 +
 +    CLI Example:
 +
 +        salt '​*'​ cp.cache_files salt://​pathto/​file1,​salt://​pathto/​file1
 +    ​
 +
 +cp.cache_local_file:​
 +
 +    Cache a local file on the minion in the localfiles cache
 +
 +    CLI Example:
 +
 +        salt '​*'​ cp.cache_local_file /etc/hosts
 +    ​
 +
 +cp.cache_master:​
 +
 +    Retrieve all of the files on the master and cache them locally
 +
 +    CLI Example:
 +
 +        salt '​*'​ cp.cache_master
 +    ​
 +
 +cp.get_dir:
 +
 +    Used to recursively copy a directory from the salt master
 +
 +    CLI Example:
 +
 +        salt '​*'​ cp.get_dir salt://​path/​to/​dir/​ /​minion/​dest
 +
 +    get_dir supports the same template and gzip arguments as get_file.
 +    ​
 +
 +cp.get_file:​
 +
 +    Used to get a single file from the salt master
 +
 +    CLI Example:
 +
 +        salt '​*'​ cp.get_file salt://​path/​to/​file /​minion/​dest
 +
 +    Template rendering can be enabled on both the source and destination file
 +    names like so:
 +
 +        salt '​*'​ cp.get_file "​salt://​{{grains.os}}/​vimrc"​ /etc/vimrc template=jinja
 +
 +    This example would instruct all Salt minions to download the vimrc from a
 +    directory with the same name as their os grain and copy it to /etc/vimrc
 +
 +    For larger files, the cp.get_file module also supports gzip compression.
 +    Because gzip is CPU-intensive,​ this should only be used in scenarios where
 +    the compression ratio is very high (e.g. pretty-printed JSON or YAML
 +    files).
 +
 +    Use the *gzip* named argument to enable it.  Valid values are 1..9, where 1
 +    is the lightest compression and 9 the heaviest. ​ 1 uses the least CPU on
 +    the master (and minion), 9 uses the most.
 +    ​
 +
 +cp.get_file_str:​
 +
 +    Return the contents of a file from a URL
 +
 +    CLI Example:
 +
 +        salt '​*'​ cp.get_file_str salt://​my/​file
 +    ​
 +
 +cp.get_template:​
 +
 +    Render a file as a template before setting it down.
 +    Warning, order is not the same as in fileclient.cp for
 +    non breaking old API.
 +
 +    CLI Example:
 +
 +        salt '​*'​ cp.get_template salt://​path/​to/​template /​minion/​dest
 +    ​
 +
 +cp.get_url:
 +
 +    Used to get a single file from a URL.
 +
 +    The default behaviuor is to write the fetched file to the given
 +    destination path. To simply return the text contents instead, set destination to
 +    None.
 +
 +    CLI Example:
 +
 +        salt '​*'​ cp.get_url salt://​my/​file /tmp/mine
 +        salt '​*'​ cp.get_url http://​www.slashdot.org /​tmp/​index.html
 +    ​
 +
 +cp.hash_file:​
 +
 +    Return the hash of a file, to get the hash of a file on the
 +    salt master file server prepend the path with salt://<​file on server>
 +    otherwise, prepend the file with / for a local file.
 +
 +    CLI Example:
 +
 +        salt '​*'​ cp.hash_file salt://​path/​to/​file
 +    ​
 +
 +cp.is_cached:​
 +
 +    Return a boolean if the given path on the master has been cached on the
 +    minion
 +
 +    CLI Example:
 +
 +        salt '​*'​ cp.is_cached salt://​path/​to/​file
 +    ​
 +
 +cp.list_master:​
 +
 +    List all of the files stored on the master
 +
 +    CLI Example:
 +
 +        salt '​*'​ cp.list_master
 +    ​
 +
 +cp.list_master_dirs:​
 +
 +    List all of the directories stored on the master
 +
 +    CLI Example:
 +
 +        salt '​*'​ cp.list_master_dirs
 +    ​
 +
 +cp.list_master_symlinks:​
 +
 +    List all of the symlinks stored on the master
 +
 +    CLI Example:
 +
 +        salt '​*'​ cp.list_master_symlinks
 +    ​
 +
 +cp.list_minion:​
 +
 +    List all of the files cached on the minion
 +
 +    CLI Example:
 +
 +        salt '​*'​ cp.list_minion
 +    ​
 +
 +cp.list_states:​
 +
 +    List all of the available state modules in an environment
 +
 +    CLI Example:
 +
 +        salt '​*'​ cp.list_states
 +    ​
 +
 +cp.push:
 +
 +    Push a file from the minion up to the master, the file will be saved to
 +    the salt master in the master'​s minion files cachedir
 +    (defaults to ``/​var/​cache/​salt/​master/​minions/​minion-id/​files``)
 +
 +    Since this feature allows a minion to push a file up to the master server
 +    it is disabled by default for security purposes. To enable, set
 +    ``file_recv`` to ``True`` in the master configuration file, and restart the
 +    master.
 +
 +    keep_symlinks
 +        Keep the path value without resolving its canonical form
 +
 +    upload_path
 +        Provide a different path inside the master'​s minion files cachedir
 +
 +    CLI Example:
 +
 +        salt '​*'​ cp.push /etc/fstab
 +        salt '​*'​ cp.push /​etc/​system-release keep_symlinks=True
 +        salt '​*'​ cp.push /etc/fstab upload_path='/​new/​path/​fstab'​
 +    ​
 +
 +cp.push_dir:​
 +
 +    Push a directory from the minion up to the master, the files will be saved
 +    to the salt master in the master'​s minion files cachedir (defaults to
 +    ``/​var/​cache/​salt/​master/​minions/​minion-id/​files``). ​ It also has a glob
 +    for matching specific files using globbing.
 +
 +    New in version 2014.7.0
 +
 +    Since this feature allows a minion to push files up to the master server it
 +    is disabled by default for security purposes. To enable, set ``file_recv``
 +    to ``True`` in the master configuration file, and restart the master.
 +
 +    upload_path
 +        Provide a different path and directory name inside the master'​s minion
 +        files cachedir
 +
 +    CLI Example:
 +
 +        salt '​*'​ cp.push /​usr/​lib/​mysql
 +        salt '​*'​ cp.push /​usr/​lib/​mysql upload_path='/​newmysql/​path'​
 +        salt '​*'​ cp.push_dir /​etc/​modprobe.d/​ glob='​*.conf'​
 +    ​
 +
 +cp.recv:
 +
 +    Used with salt-cp, pass the files dict, and the destination.
 +
 +    This function receives small fast copy files from the master via salt-cp.
 +    It does not work via the CLI.
 +    ​
 +
 +cron.list_tab:​
 +
 +    Return the contents of the specified user's crontab
 +
 +    CLI Example:
 +
 +        salt '​*'​ cron.list_tab root
 +    ​
 +
 +cron.ls:
 +
 +This function is an alias of ``list_tab``.
 +
 +    Return the contents of the specified user's crontab
 +
 +    CLI Example:
 +
 +        salt '​*'​ cron.list_tab root
 +    ​
 +
 +cron.raw_cron:​
 +
 +    Return the contents of the user's crontab
 +
 +    CLI Example:
 +
 +        salt '​*'​ cron.raw_cron root
 +    ​
 +
 +cron.rm:
 +
 +This function is an alias of ``rm_job``.
 +
 +    Remove a cron job for a specified user. If any of the day/time params are
 +    specified, the job will only be removed if the specified params match.
 +
 +    CLI Example:
 +
 +        salt '​*'​ cron.rm_job root /​usr/​local/​weekly
 +        salt '​*'​ cron.rm_job root /​usr/​bin/​foo dayweek=1
 +    ​
 +
 +cron.rm_env:​
 +
 +    Remove cron environment variable for a specified user.
 +
 +    CLI Example:
 +
 +        salt '​*'​ cron.rm_env root MAILTO
 +    ​
 +
 +cron.rm_job:​
 +
 +    Remove a cron job for a specified user. If any of the day/time params are
 +    specified, the job will only be removed if the specified params match.
 +
 +    CLI Example:
 +
 +        salt '​*'​ cron.rm_job root /​usr/​local/​weekly
 +        salt '​*'​ cron.rm_job root /​usr/​bin/​foo dayweek=1
 +    ​
 +
 +cron.rm_special:​
 +
 +    Remove a special cron job for a specified user.
 +
 +    CLI Example:
 +
 +        salt '​*'​ cron.rm_job root @hourly /​usr/​bin/​foo
 +    ​
 +
 +cron.set_env:​
 +
 +    Set up an environment variable in the crontab.
 +
 +    CLI Example:
 +
 +        salt '​*'​ cron.set_env root MAILTO user@example.com
 +    ​
 +
 +cron.set_job:​
 +
 +    Sets a cron job up for a specified user.
 +
 +    CLI Example:
 +
 +        salt '​*'​ cron.set_job root '​*'​ '​*'​ '​*'​ '​*'​ 1 /​usr/​local/​weekly
 +    ​
 +
 +cron.set_special:​
 +
 +    Set up a special command in the crontab.
 +
 +    CLI Example:
 +
 +        salt '​*'​ cron.set_special root @hourly 'echo foobar'​
 +    ​
 +
 +cron.write_cron_file:​
 +
 +    Writes the contents of a file to a user's crontab
 +
 +    CLI Example:
 +
 +        salt '​*'​ cron.write_cron_file root /​tmp/​new_cron
 +    ​
 +
 +cron.write_cron_file_verbose:​
 +
 +    Writes the contents of a file to a user's crontab and return error message on error
 +
 +    CLI Example:
 +
 +        salt '​*'​ cron.write_cron_file_verbose root /​tmp/​new_cron
 +    ​
 +
 +data.cas:
 +
 +    Check and set a value in the minion datastore
 +
 +    CLI Example:
 +
 +        salt '​*'​ data.cas <key> <​value>​ <​old_value>​
 +    ​
 +
 +data.clear:
 +
 +    Clear out all of the data in the minion datastore, this function is
 +    destructive!
 +
 +    CLI Example:
 +
 +        salt '​*'​ data.clear
 +    ​
 +
 +data.dump:
 +
 +    Replace the entire datastore with a passed data structure
 +
 +    CLI Example:
 +
 +        salt '​*'​ data.dump '​{'​eggs':​ '​spam'​}'​
 +    ​
 +
 +data.get:
 +
 +    Get a (list of) value(s) from the minion datastore
 +
 +    New in version 2015.8.0
 +
 +    CLI Example:
 +
 +        salt '​*'​ data.get <​key(s)>​
 +    ​
 +
 +data.getval:​
 +
 +    Get a value from the minion datastore
 +
 +    .. deprecated::​ Boron
 +         Use ``get`` instead
 +
 +    CLI Example:
 +
 +        salt '​*'​ data.getval <key>
 +    ​
 +
 +data.getvals:​
 +
 +    Get values from the minion datastore
 +
 +    .. deprecated::​ Boron
 +         Use ``get`` instead
 +
 +    CLI Example:
 +
 +        salt '​*'​ data.getvals <key> [<​key>​ ...]
 +    ​
 +
 +data.has_key:​
 +
 +    Check if key is in the minion datastore
 +
 +    New in version 2015.8.0
 +
 +    CLI Example:
 +
 +        salt '​*'​ data.has_key <​mykey>​
 +    ​
 +
 +data.items:
 +
 +    Get items from the minion datastore
 +
 +    New in version 2015.8.0
 +
 +    CLI Example:
 +
 +        salt '​*'​ data.items
 +    ​
 +
 +data.keys:
 +
 +    Get all keys from the minion datastore
 +
 +    New in version 2015.8.0
 +
 +    CLI Example:
 +
 +        salt '​*'​ data.keys
 +    ​
 +
 +data.load:
 +
 +    Return all of the data in the minion datastore
 +
 +    CLI Example:
 +
 +        salt '​*'​ data.load
 +    ​
 +
 +data.pop:
 +
 +    Pop (return & delete) a value from the minion datastore
 +
 +    New in version 2015.5.2
 +
 +    CLI Example:
 +
 +        salt '​*'​ data.pop <key> "there was no val"
 +    ​
 +
 +data.update:​
 +
 +    Update a key with a value in the minion datastore
 +
 +    CLI Example:
 +
 +        salt '​*'​ data.update <key> <​value>​
 +    ​
 +
 +data.values:​
 +
 +    Get values from the minion datastore
 +
 +    New in version 2015.8.0
 +
 +    CLI Example:
 +
 +        salt '​*'​ data.values
 +    ​
 +
 +defaults.get:​
 +
 +    defaults.get is used much like pillar.get except that it will read
 +    a default value for a pillar from defaults.json or defaults.yaml
 +    files that are stored in the root of a salt formula.
 +
 +    CLI Example:
 +
 +        salt '​*'​ defaults.get core:​users:​root
 +
 +    The defaults is computed from pillar key. The first entry is considered as
 +    the formula namespace.
 +
 +    For example, querying ``core:​users:​root`` will try to load
 +    ``salt://​core/​defaults.yaml`` and ``salt://​core/​defaults.json``.
 +    ​
 +
 +devmap.multipath_flush:​
 +
 +    Device-Mapper Multipath flush
 +
 +    CLI Example:
 +
 +        salt '​*'​ devmap.multipath_flush mpath1
 +    ​
 +
 +devmap.multipath_list:​
 +
 +    Device-Mapper Multipath list
 +
 +    CLI Example:
 +
 +        salt '​*'​ devmap.multipath_list
 +    ​
 +
 +disk.blkid:
 +
 +    Return block device attributes: UUID, LABEL, etc. This function only works
 +    on systems where blkid is available.
 +
 +    CLI Example:
 +
 +        salt '​*'​ disk.blkid
 +        salt '​*'​ disk.blkid /dev/sda
 +    ​
 +
 +disk.inodeusage:​
 +
 +    Return inode usage information for volumes mounted on this minion
 +
 +    CLI Example:
 +
 +        salt '​*'​ disk.inodeusage
 +    ​
 +
 +disk.percent:​
 +
 +    Return partition information for volumes mounted on this minion
 +
 +    CLI Example:
 +
 +        salt '​*'​ disk.percent /var
 +    ​
 +
 +disk.usage:
 +
 +    Return usage information for volumes mounted on this minion
 +
 +    CLI Example:
 +
 +        salt '​*'​ disk.usage
 +    ​
 +
 +django.collectstatic:​
 +
 +    Collect static files from each of your applications into a single location
 +    that can easily be served in production.
 +
 +    CLI Example:
 +
 +        salt '​*'​ django.collectstatic <​settings_module>​
 +    ​
 +
 +django.command:​
 +
 +    Run arbitrary django management command
 +
 +    CLI Example:
 +
 +        salt '​*'​ django.command <​settings_module>​ <​command>​
 +    ​
 +
 +django.createsuperuser:​
 +
 +    Create a super user for the database.
 +    This function defaults to use the ``--noinput`` flag which prevents the
 +    creation of a password for the superuser.
 +
 +    CLI Example:
 +
 +        salt '​*'​ django.createsuperuser <​settings_module>​ user user@example.com
 +    ​
 +
 +django.loaddata:​
 +
 +    Load fixture data
 +
 +    Fixtures:
 +        comma separated list of fixtures to load
 +
 +    CLI Example:
 +
 +        salt '​*'​ django.loaddata <​settings_module>​ <comma delimited list of fixtures>​
 +
 +    ​
 +
 +django.syncdb:​
 +
 +    Run syncdb
 +
 +    Execute the Django-Admin syncdb command, if South is available on the
 +    minion the ``migrate`` option can be passed as ``True`` calling the
 +    migrations to run after the syncdb completes
 +
 +    CLI Example:
 +
 +        salt '​*'​ django.syncdb <​settings_module>​
 +    ​
 +
 +dnsmasq.fullversion:​
 +
 +    Shows installed version of dnsmasq and compile options.
 +
 +    CLI Example:
 +
 +        salt '​*'​ dnsmasq.version
 +    ​
 +
 +dnsmasq.get_config:​
 +
 +    Dumps all options from the config file.
 +
 +    CLI Examples:
 +
 +        salt '​*'​ dnsmasq.get_config
 +        salt '​*'​ dnsmasq.get_config file=/​etc/​dnsmasq.conf
 +    ​
 +
 +dnsmasq.set_config:​
 +
 +    Sets a value or a set of values in the specified file. By default, if
 +    conf-dir is configured in this file, salt will attempt to set the option
 +    in any file inside the conf-dir where it has already been enabled. If it
 +    does not find it inside any files, it will append it to the main config
 +    file. Setting follow to False will turn off this behavior.
 +
 +    If a config option currently appears multiple times (such as dhcp-host,
 +    which is specified at least once per host), the new option will be added
 +    to the end of the main config file (and not to any includes). If you need
 +    an option added to a specific include file, specify it as the config_file.
 +
 +    CLI Examples:
 +
 +        salt '​*'​ dnsmasq.set_config domain=mydomain.com
 +        salt '​*'​ dnsmasq.set_config follow=False domain=mydomain.com
 +        salt '​*'​ dnsmasq.set_config file=/​etc/​dnsmasq.conf domain=mydomain.com
 +    ​
 +
 +dnsmasq.version:​
 +
 +    Shows installed version of dnsmasq.
 +
 +    CLI Example:
 +
 +        salt '​*'​ dnsmasq.version
 +    ​
 +
 +dnsutil.A:
 +
 +    Return the A record(s) for `host`.
 +
 +    Always returns a list.
 +
 +    CLI Example:
 +
 +        salt ns1 dnsutil.A www.google.com
 +    ​
 +
 +dnsutil.AAAA:​
 +
 +    Return the AAAA record(s) for `host`.
 +
 +    Always returns a list.
 +
 +    New in version 2014.7.5
 +
 +    CLI Example:
 +
 +        salt ns1 dnsutil.AAAA www.google.com
 +    ​
 +
 +dnsutil.MX:
 +
 +    Return a list of lists for the MX of ``domain``.
 +
 +    If the '​resolve'​ argument is True, resolve IPs for the servers.
 +
 +    It's limited to one IP, because although in practice it's very rarely a
 +    round robin, it is an acceptable configuration and pulling just one IP lets
 +    the data be similar to the non-resolved version. If you think an MX has
 +    multiple IPs, don't use the resolver here, resolve them in a separate step.
 +
 +    CLI Example:
 +
 +        salt ns1 dig.MX google.com
 +    ​
 +
 +dnsutil.NS:
 +
 +    Return a list of IPs of the nameservers for ``domain``
 +
 +    If '​resolve'​ is False, don't resolve names.
 +
 +    CLI Example:
 +
 +        salt ns1 dig.NS google.com
 +
 +    ​
 +
 +dnsutil.SPF:​
 +
 +    Return the allowed IPv4 ranges in the SPF record for ``domain``.
 +
 +    If record is ``SPF`` and the SPF record is empty, the TXT record will be
 +    searched automatically. If you know the domain uses TXT and not SPF,
 +    specifying that will save a lookup.
 +
 +    CLI Example:
 +
 +        salt ns1 dig.SPF google.com
 +    ​
 +
 +dnsutil.check_ip:​
 +
 +    Check that string ip_addr is a valid IP
 +
 +    CLI Example:
 +
 +        salt ns1 dig.check_ip 127.0.0.1
 +    ​
 +
 +dnsutil.hosts_append:​
 +
 +    Append a single line to the /etc/hosts file.
 +
 +    CLI Example:
 +
 +        salt '​*'​ dnsutil.hosts_append /etc/hosts 127.0.0.1 ad1.yuk.co,​ad2.yuk.co
 +    ​
 +
 +dnsutil.hosts_remove:​
 +
 +    Remove a host from the /etc/hosts file. If doing so will leave a line
 +    containing only an IP address, then the line will be deleted. This function
 +    will leave comments and blank lines intact.
 +
 +    CLI Examples:
 +
 +        salt '​*'​ dnsutil.hosts_remove /etc/hosts ad1.yuk.co
 +        salt '​*'​ dnsutil.hosts_remove /etc/hosts ad2.yuk.co,​ad1.yuk.co
 +    ​
 +
 +dnsutil.parse_hosts:​
 +
 +    Parse /etc/hosts file.
 +
 +    CLI Example:
 +
 +        salt '​*'​ dnsutil.parse_hosts
 +    ​
 +
 +dnsutil.parse_zone:​
 +
 +    Parses a zone file. Can be passed raw zone data on the API level.
 +
 +    CLI Example:
 +
 +        salt ns1 dnsutil.parse_zone /​var/​lib/​named/​example.com.zone
 +    ​
 +
 +dnsutil.serial:​
 +
 +    Return, store and update a dns serial for your zone files.
 +
 +    zone: a keywork for a specific zone
 +
 +    update: store an updated version of the serial in a grain
 +
 +    If ``update`` is False, the function will retrieve an existing serial or
 +    return the current date if no serial is stored. Nothing will be stored
 +
 +    If ``update`` is True, the function will set the serial to the current date
 +    if none exist or if the existing serial is for a previous date. If a serial
 +    for greater than the current date is already stored, the function will
 +    increment it.
 +
 +    This module stores the serial in a grain, you can explicitly set the
 +    stored value as a grain named ``dnsserial_<​zone_name>​``.
 +
 +    CLI Example:
 +
 +        salt ns1 dnsutil.serial example.com
 +    ​
 +
 +drbd.overview:​
 +
 +    Show status of the DRBD devices
 +
 +    CLI Example:
 +
 +        salt '​*'​ drbd.overview
 +    ​
 +
 +elasticsearch.alias_create:​
 +
 +    Create an alias for a specific index/​indices
 +
 +    CLI example::
 +
 +        salt myminion elasticsearch.alias_create testindex_v1 testindex
 +    ​
 +
 +elasticsearch.alias_delete:​
 +
 +    Delete an alias of an index
 +
 +    CLI example::
 +
 +        salt myminion elasticsearch.alias_delete testindex_v1 testindex
 +    ​
 +
 +elasticsearch.alias_exists:​
 +
 +    Return a boolean indicating whether given alias exists
 +
 +    CLI example::
 +
 +        salt myminion elasticsearch.alias_exists testindex
 +    ​
 +
 +elasticsearch.alias_get:​
 +
 +    Check for the existence of an alias and if it exists, return it
 +
 +    CLI example::
 +
 +        salt myminion elasticsearch.alias_get testindex
 +    ​
 +
 +elasticsearch.document_create:​
 +
 +    Create a document in a specified index
 +
 +    CLI example::
 +
 +        salt myminion elasticsearch.document_create testindex doctype1 '​{}'​
 +    ​
 +
 +elasticsearch.document_delete:​
 +
 +    Delete a document from an index
 +
 +    CLI example::
 +
 +        salt myminion elasticsearch.document_delete testindex doctype1 AUx-384m0Bug_8U80wQZ
 +    ​
 +
 +elasticsearch.document_exists:​
 +
 +    Return a boolean indicating whether given document exists
 +
 +    CLI example::
 +
 +        salt myminion elasticsearch.document_exists testindex AUx-384m0Bug_8U80wQZ
 +    ​
 +
 +elasticsearch.document_get:​
 +
 +    Check for the existence of a document and if it exists, return it
 +
 +    CLI example::
 +
 +        salt myminion elasticsearch.document_get testindex AUx-384m0Bug_8U80wQZ
 +    ​
 +
 +elasticsearch.index_create:​
 +
 +    Create an index
 +
 +    CLI example::
 +
 +        salt myminion elasticsearch.index_create testindex
 +    ​
 +
 +elasticsearch.index_delete:​
 +
 +    Delete an index
 +
 +    CLI example::
 +
 +        salt myminion elasticsearch.index_delete testindex
 +    ​
 +
 +elasticsearch.index_exists:​
 +
 +    Return a boolean indicating whether given index exists
 +
 +    CLI example::
 +
 +        salt myminion elasticsearch.index_exists testindex
 +    ​
 +
 +elasticsearch.index_get:​
 +
 +    Check for the existence of an index and if it exists, return it
 +
 +    CLI example::
 +
 +        salt myminion elasticsearch.index_get testindex
 +    ​
 +
 +elasticsearch.index_template_create:​
 +
 +    Create an index template
 +
 +    CLI example::
 +
 +        salt myminion elasticsearch.index_template_create testindex_templ '{ "​template":​ "​logstash-*",​ "​order":​ 1, "​settings":​ { "​number_of_shards":​ 1 } }'
 +    ​
 +
 +elasticsearch.index_template_delete:​
 +
 +    Delete an index template (type) along with its data
 +
 +    CLI example::
 +
 +        salt myminion elasticsearch.index_template_delete testindex_templ user
 +    ​
 +
 +elasticsearch.index_template_exists:​
 +
 +    Return a boolean indicating whether given index template exists
 +
 +    CLI example::
 +
 +        salt myminion elasticsearch.index_template_exists testindex_templ
 +    ​
 +
 +elasticsearch.index_template_get:​
 +
 +    Retrieve template definition of index or index/type
 +
 +    CLI example::
 +
 +        salt myminion elasticsearch.index_template_get testindex_templ user
 +    ​
 +
 +elasticsearch.mapping_create:​
 +
 +    Create a mapping in a given index
 +
 +    CLI example::
 +
 +        salt myminion elasticsearch.mapping_create testindex user '{ "​user"​ : { "​properties"​ : { "​message"​ : {"​type"​ : "​string",​ "​store"​ : true } } } }'
 +    ​
 +
 +elasticsearch.mapping_delete:​
 +
 +    Delete a mapping (type) along with its data
 +
 +    CLI example::
 +
 +        salt myminion elasticsearch.mapping_delete testindex user
 +    ​
 +
 +elasticsearch.mapping_get:​
 +
 +    Retrieve mapping definition of index or index/type
 +
 +    CLI example::
 +
 +        salt myminion elasticsearch.mapping_get testindex user
 +    ​
 +
 +environ.get:​
 +
 +    Get a single salt process environment variable.
 +
 +    key
 +        String used as the key for environment lookup.
 +
 +    default
 +        If the key is not found in the environment,​ return this value.
 +        Default: ''​
 +
 +
 +    CLI Example:
 +
 +        salt '​*'​ environ.get foo
 +        salt '​*'​ environ.get baz default=False
 +    ​
 +
 +environ.has_value:​
 +
 +    Determine whether the key exists in the current salt process
 +    environment dictionary. Optionally compare the current value
 +    of the environment against the supplied value string.
 +
 +    key
 +        Must be a string. Used as key for environment lookup.
 +
 +    value:
 +        Optional. If key exists in the environment,​ compare the
 +        current value with this value. Return True if they are equal.
 +
 +    CLI Example:
 +
 +        salt '​*'​ environ.has_value foo
 +    ​
 +
 +environ.item:​
 +
 +    Get one or more salt process environment variables.
 +    Returns a dict.
 +
 +    keys
 +        Either a string or a list of strings that will be used as the
 +        keys for environment lookup.
 +
 +    default
 +        If the key is not found in the environment,​ return this value.
 +        Default: ''​
 +
 +    CLI Example:
 +
 +        salt '​*'​ environ.item foo
 +        salt '​*'​ environ.item '[foo, baz]' default=None
 +    ​
 +
 +environ.items:​
 +
 +    Return a dict of the entire environment set for the salt process
 +
 +    CLI Example:
 +
 +        salt '​*'​ environ.items
 +    ​
 +
 +environ.setenv:​
 +
 +    Set multiple salt process environment variables from a dict.
 +    Returns a dict.
 +
 +    environ
 +        Must be a dict. The top-level keys of the dict are the names
 +        of the environment variables to set. Each key's value must be
 +        a string or False. Refer to the '​false_unsets'​ parameter for
 +        behavior when a value set to False.
 +
 +    false_unsets
 +        If a key's value is False and false_unsets is True, then the
 +        key will be removed from the salt processes environment dict
 +        entirely. If a key's value is False and false_unsets is not
 +        True, then the key's value will be set to an empty string.
 +        Default: False
 +
 +    clear_all
 +        USE WITH CAUTION! This option can unset environment variables
 +        needed for salt to function properly.
 +        If clear_all is True, then any environment variables not
 +        defined in the environ dict will be deleted.
 +        Default: False
 +
 +    update_minion
 +        If True, apply these environ changes to the main salt-minion
 +        process. If False, the environ changes will only affect the
 +        current salt subprocess.
 +        Default: False
 +
 +
 +    CLI Example:
 +
 +        salt '​*'​ environ.setenv '​{"​foo":​ "​bar",​ "​baz":​ "​quux"​}'​
 +        salt '​*'​ environ.setenv '​{"​a":​ "​b",​ "​c":​ False}'​ false_unsets=True
 +    ​
 +
 +environ.setval:​
 +
 +    Set a single salt process environment variable. Returns True
 +    on success.
 +
 +    key
 +        The environment key to set. Must be a string.
 +
 +    val
 +        The value to set. Must be a string or False. Refer to the
 +        '​false_unsets'​ parameter for behavior when set to False.
 +
 +    false_unsets
 +        If val is False and false_unsets is True, then the key will be
 +        removed from the salt processes environment dict entirely.
 +        If val is False and false_unsets is not True, then the key's
 +        value will be set to an empty string.
 +        Default: False.
 +
 +
 +    CLI Example:
 +
 +        salt '​*'​ environ.setval foo bar
 +        salt '​*'​ environ.setval baz val=False false_unsets=True
 +    ​
 +
 +etcd.get:
 +
 +    New in version 2014.7.0
 +
 +    Get a value from etcd, by direct path
 +
 +    CLI Examples:
 +
 +        salt myminion etcd.get /​path/​to/​key
 +        salt myminion etcd.get /​path/​to/​key profile=my_etcd_config
 +        salt myminion etcd.get /​path/​to/​key recurse=True profile=my_etcd_config
 +    ​
 +
 +etcd.ls:
 +
 +    New in version 2014.7.0
 +
 +    Return all keys and dirs inside a specific path
 +
 +    CLI Example:
 +
 +
 +        salt myminion etcd.ls /​path/​to/​dir/​
 +        salt myminion etcd.ls /​path/​to/​dir/​ profile=my_etcd_config
 +    ​
 +
 +etcd.rm:
 +
 +    New in version 2014.7.0
 +
 +    Delete a key from etcd
 +
 +    CLI Example:
 +
 +
 +        salt myminion etcd.rm /​path/​to/​key
 +        salt myminion etcd.rm /​path/​to/​key profile=my_etcd_config
 +        salt myminion etcd.rm /​path/​to/​dir recurse=True profile=my_etcd_config
 +    ​
 +
 +etcd.set:
 +
 +    New in version 2014.7.0
 +
 +    Set a value in etcd, by direct path
 +
 +    CLI Example:
 +
 +        salt myminion etcd.set /​path/​to/​key value
 +        salt myminion etcd.set /​path/​to/​key value profile=my_etcd_config
 +    ​
 +
 +etcd.tree:
 +
 +    New in version 2014.7.0
 +
 +    Recurse through etcd and return all values
 +
 +    CLI Example:
 +
 +
 +        salt myminion etcd.tree
 +        salt myminion etcd.tree profile=my_etcd_config
 +        salt myminion etcd.tree /​path/​to/​keys profile=my_etcd_config
 +    ​
 +
 +event.fire:
 +
 +    Fire an event on the local minion event bus. Data must be formed as a dict.
 +
 +    CLI Example:
 +
 +        salt '​*'​ event.fire '​{"​data":"​my event data"​}'​ '​tag'​
 +    ​
 +
 +event.fire_master:​
 +
 +    Fire an event off up to the master server
 +
 +    CLI Example:
 +
 +        salt '​*'​ event.fire_master '​{"​data":"​my event data"​}'​ '​tag'​
 +    ​
 +
 +event.send:
 +
 +    Send an event to the Salt Master
 +
 +    New in version 2014.7.0
 +
 +    :param tag: A tag to give the event.
 +        Use slashes to create a namespace for related events. E.g.,
 +        ``myco/​build/​buildserver1/​start``,​ ``myco/​build/​buildserver1/​success``,​
 +        ``myco/​build/​buildserver1/​failure``.
 +
 +    :param data: A dictionary of data to send in the event.
 +        This is free-form. Send any data points that are needed for whoever is
 +        consuming the event. Arguments on the CLI are interpreted as YAML so
 +        complex data structures are possible.
 +
 +    :param with_env: Include environment variables from the current shell
 +        environment in the event data as ``environ``.. This is a short-hand for
 +        working with systems that seed the environment with relevant data such
 +        as Jenkins.
 +    :type with_env: Specify ``True`` to include all environment variables, or
 +        specify a list of strings of variable names to include.
 +
 +    :param with_grains:​ Include grains from the current minion in the event
 +        data as ``grains``.
 +    :type with_grains:​ Specify ``True`` to include all grains, or specify a
 +        list of strings of grain names to include.
 +
 +    :param with_pillar:​ Include Pillar values from the current minion in the
 +        event data as ``pillar``. Remember Pillar data is often sensitive data
 +        so be careful. This is useful for passing ephemeral Pillar values
 +        through an event. Such as passing the ``pillar={}`` kwarg in
 +        :​py:​func:​`state.sls <​salt.modules.state.sls>​` from the Master, through
 +        an event on the Minion, then back to the Master.
 +    :type with_pillar:​ Specify ``True`` to include all Pillar values, or
 +        specify a list of strings of Pillar keys to include. It is a
 +        best-practice to only specify a relevant subset of Pillar data.
 +
 +    :param kwargs: Any additional keyword arguments passed to this function
 +        will be interpreted as key-value pairs and included in the event data.
 +        This provides a convenient alternative to YAML for simple values.
 +
 +    CLI Example:
 +
 +        salt-call event.send myco/mytag foo=Foo bar=Bar
 +        salt-call event.send '​myco/​mytag'​ '{foo: Foo, bar: Bar}'
 +
 +    A convenient way to allow Jenkins to execute ``salt-call`` is via sudo. The
 +    following rule in sudoers will allow the ``jenkins`` user to run only the
 +    following command.
 +
 +    ``/​etc/​sudoers`` (allow preserving the environment):​
 +
 +        jenkins ALL=(ALL) NOPASSWD:​SETENV:​ /​usr/​bin/​salt-call event.send*
 +
 +    Call Jenkins via sudo (preserve the environment):​
 +
 +        sudo -E salt-call event.send myco/​jenkins/​build/​success with_env=[BUILD_ID,​ BUILD_URL, GIT_BRANCH, GIT_COMMIT]
 +
 +    ​
 +
 +extfs.attributes:​
 +
 +    Return attributes from dumpe2fs for a specified device
 +
 +    CLI Example:
 +
 +        salt '​*'​ extfs.attributes /dev/sda1
 +    ​
 +
 +extfs.blocks:​
 +
 +    Return block and inode info from dumpe2fs for a specified device
 +
 +    CLI Example:
 +
 +        salt '​*'​ extfs.blocks /dev/sda1
 +    ​
 +
 +extfs.dump:
 +
 +    Return all contents of dumpe2fs for a specified device
 +
 +    CLI Example:
 +
 +        salt '​*'​ extfs.dump /dev/sda1
 +    ​
 +
 +extfs.mkfs:
 +
 +    Create a file system on the specified device
 +
 +    CLI Example:
 +
 +        salt '​*'​ extfs.mkfs /dev/sda1 fs_type=ext4 opts='​acl,​noexec'​
 +
 +    Valid options are:
 +
 +    * **block_size**:​ 1024, 2048 or 4096
 +    * **check**: check for bad blocks
 +    * **direct**: use direct IO
 +    * **ext_opts**:​ extended file system options (comma-separated)
 +    * **fragment_size**:​ size of fragments
 +    * **force**: setting force to True will cause mke2fs to specify the -F
 +      option twice (it is already set once); this is truly dangerous
 +    * **blocks_per_group**:​ number of blocks in a block group
 +    * **number_of_groups**:​ ext4 option for a virtual block group
 +    * **bytes_per_inode**:​ set the bytes/inode ratio
 +    * **inode_size**:​ size of the inode
 +    * **journal**:​ set to True to create a journal (default on ext3/4)
 +    * **journal_opts**:​ options for the fs journal (comma separated)
 +    * **blocks_file**:​ read bad blocks from file
 +    * **label**: label to apply to the file system
 +    * **reserved**:​ percentage of blocks reserved for super-user
 +    * **last_dir**:​ last mounted directory
 +    * **test**: set to True to not actually create the file system (mke2fs -n)
 +    * **number_of_inodes**:​ override default number of inodes
 +    * **creator_os**:​ override "​creator operating system"​ field
 +    * **opts**: mount options (comma separated)
 +    * **revision**:​ set the filesystem revision (default 1)
 +    * **super**: write superblock and group descriptors only
 +    * **fs_type**:​ set the filesystem type (REQUIRED)
 +    * **usage_type**:​ how the filesystem is going to be used
 +    * **uuid**: set the UUID for the file system
 +
 +    See the ``mke2fs(8)`` manpage for a more complete description of these
 +    options.
 +    ​
 +
 +extfs.tune:
 +
 +    Set attributes for the specified device (using tune2fs)
 +
 +    CLI Example:
 +
 +        salt '​*'​ extfs.tune /dev/sda1 force=True label=wildstallyns opts='​acl,​noexec'​
 +
 +    Valid options are:
 +
 +    * **max**: max mount count
 +    * **count**: mount count
 +    * **error**: error behavior
 +    * **extended_opts**:​ extended options (comma separated)
 +    * **force**: force, even if there are errors (set to True)
 +    * **group**: group name or gid that can use the reserved blocks
 +    * **interval**:​ interval between checks
 +    * **journal**:​ set to True to create a journal (default on ext3/4)
 +    * **journal_opts**:​ options for the fs journal (comma separated)
 +    * **label**: label to apply to the file system
 +    * **reserved**:​ percentage of blocks reserved for super-user
 +    * **last_dir**:​ last mounted directory
 +    * **opts**: mount options (comma separated)
 +    * **feature**:​ set or clear a feature (comma separated)
 +    * **mmp_check**:​ mmp check interval
 +    * **reserved**:​ reserved blocks count
 +    * **quota_opts**:​ quota options (comma separated)
 +    * **time**: time last checked
 +    * **user**: user or uid who can use the reserved blocks
 +    * **uuid**: set the UUID for the file system
 +
 +    See the ``mke2fs(8)`` manpage for a more complete description of these
 +    options.
 +    ​
 +
 +file.access:​
 +
 +    New in version 2014.1.0
 +
 +    Test whether the Salt process has the specified access to the file. One of
 +    the following modes must be specified:
 +
 +    .. code-block::​text
 +
 +        f: Test the existence of the path
 +        r: Test the readability of the path
 +        w: Test the writability of the path
 +        x: Test whether the path can be executed
 +
 +    CLI Example:
 +
 +        salt '​*'​ file.access /​path/​to/​file f
 +        salt '​*'​ file.access /​path/​to/​file x
 +    ​
 +
 +file.append:​
 +
 +    New in version 0.9.5
 +
 +    Append text to the end of a file
 +
 +    path
 +        path to file
 +
 +    `*args`
 +        strings to append to file
 +
 +    CLI Example:
 +
 +        salt '​*'​ file.append /etc/motd \
 +                "With all thine offerings thou shalt offer salt." \
 +                "Salt is what makes things taste bad when it isn't in them."
 +
 +    .. admonition::​ Attention
 +
 +        If you need to pass a string to append and that string contains
 +        an equal sign, you **must** include the argument name, args.
 +        For example:
 +
 +            salt '​*'​ file.append /etc/motd args='​cheese=spam'​
 +
 +            salt '​*'​ file.append /etc/motd args="​['​cheese=spam','​spam=cheese'​]"​
 +
 +    ​
 +
 +file.basename:​
 +
 +    Returns the final component of a pathname
 +
 +    New in version 2015.5.0
 +
 +    This can be useful at the CLI but is frequently useful when scripting.
 +
 +        {%- set filename = salt['​file.basename'​](source_file) %}
 +
 +    CLI Example:
 +
 +        salt '​*'​ file.basename '​test/​test.config'​
 +    ​
 +
 +file.blockreplace:​
 +
 +    New in version 2014.1.0
 +
 +    Replace content of a text block in a file, delimited by line markers
 +
 +    A block of content delimited by comments can help you manage several lines
 +    entries without worrying about old entries removal.
 +
 +    Note:
 +
 +        This function will store two copies of the file in-memory (the original
 +        version and the edited version) in order to detect changes and only
 +        edit the targeted file if necessary.
 +
 +    path
 +        Filesystem path to the file to be edited
 +
 +    marker_start
 +        The line content identifying a line as the start of the content block.
 +        Note that the whole line containing this marker will be considered, so
 +        whitespace or extra content before or after the marker is included in
 +        final output
 +
 +    marker_end
 +        The line content identifying a line as the end of the content block.
 +        Note that the whole line containing this marker will be considered, so
 +        whitespace or extra content before or after the marker is included in
 +        final output
 +
 +    content
 +        The content to be used between the two lines identified by marker_start
 +        and marker_stop.
 +
 +    append_if_not_found : False
 +        If markers are not found and set to ``True`` then, the markers and
 +        content will be appended to the file.
 +
 +    prepend_if_not_found : False
 +        If markers are not found and set to ``True`` then, the markers and
 +        content will be prepended to the file.
 +
 +
 +    backup
 +        The file extension to use for a backup of the file if any edit is made.
 +        Set to ``False`` to skip making a backup.
 +
 +    dry_run
 +        Don't make any edits to the file.
 +
 +    show_changes
 +        Output a unified diff of the old file and the new file. If ``False``,
 +        return a boolean if any changes were made.
 +
 +    CLI Example:
 +
 +        salt '​*'​ file.blockreplace /etc/hosts '#-- start managed zone foobar : DO NOT EDIT --' \
 +        '#-- end managed zone foobar --' $'​10.0.1.1 foo.foobar\n10.0.1.2 bar.foobar'​ True
 +
 +    ​
 +
 +file.check_file_meta:​
 +
 +    Check for the changes in the file metadata.
 +
 +    CLI Example:
 +
 +        salt '​*'​ file.check_file_meta /​etc/​httpd/​conf.d/​httpd.conf salt://​http/​httpd.conf '​{hash_type:​ '​md5',​ '​hsum':​ <​md5sum>​}'​ root, root, '​755'​ base
 +
 +    Note:
 +
 +        Supported hash types include sha512, sha384, sha256, sha224, sha1, and
 +        md5.
 +
 +    name
 +        Path to file destination
 +
 +    sfn
 +        Template-processed source file contents
 +
 +    source
 +        URL to file source
 +
 +    source_sum
 +        File checksum information as a dictionary
 +
 +            {hash_type: md5, hsum: <​md5sum>​}
 +
 +    user
 +        Destination file user owner
 +
 +    group
 +        Destination file group owner
 +
 +    mode
 +        Destination file permissions mode
 +
 +    saltenv
 +        Salt environment used to resolve source files
 +
 +    contents
 +        File contents
 +    ​
 +
 +file.check_hash:​
 +
 +    Check if a file matches the given hash string
 +
 +    Returns true if the hash matched, otherwise false. Raises ValueError if
 +    the hash was not formatted correctly.
 +
 +    path
 +        A file path
 +    hash
 +        A string in the form <​hash_type>:<​hash_value>​. For example:
 +        ``md5:​e138491e9d5b97023cea823fe17bac22``
 +
 +    CLI Example:
 +
 +        salt '​*'​ file.check_hash /etc/fstab md5:<​md5sum>​
 +    ​
 +
 +file.check_managed:​
 +
 +    Check to see what changes need to be made for a file
 +
 +    CLI Example:
 +
 +        salt '​*'​ file.check_managed /​etc/​httpd/​conf.d/​httpd.conf salt://​http/​httpd.conf '​{hash_type:​ '​md5',​ '​hsum':​ <​md5sum>​}'​ root, root, '​755'​ jinja True None None base
 +    ​
 +
 +file.check_managed_changes:​
 +
 +    Return a dictionary of what changes need to be made for a file
 +
 +    CLI Example:
 +
 +        salt '​*'​ file.check_managed_changes /​etc/​httpd/​conf.d/​httpd.conf salt://​http/​httpd.conf '​{hash_type:​ '​md5',​ '​hsum':​ <​md5sum>​}'​ root, root, '​755'​ jinja True None None base
 +    ​
 +
 +file.check_perms:​
 +
 +    Check the permissions on files and chown if needed
 +
 +    CLI Example:
 +
 +        salt '​*'​ file.check_perms /​etc/​sudoers '​{}'​ root root 400
 +
 +    Changed in version 2014.1.3
 +        ``follow_symlinks`` option added
 +    ​
 +
 +file.chgrp:
 +
 +    Change the group of a file
 +
 +    path
 +        path to the file or directory
 +
 +    group
 +        group owner
 +
 +    CLI Example:
 +
 +        salt '​*'​ file.chgrp /etc/passwd root
 +    ​
 +
 +file.chown:
 +
 +    Chown a file, pass the file the desired user and group
 +
 +    path
 +        path to the file or directory
 +
 +    user
 +        user owner
 +
 +    group
 +        group owner
 +
 +    CLI Example:
 +
 +        salt '​*'​ file.chown /etc/passwd root root
 +    ​
 +
 +file.comment:​
 +
 +    .. deprecated::​ 0.17.0
 +       Use :​py:​func:​`~salt.modules.file.replace` instead.
 +
 +    Comment out specified lines in a file
 +
 +    path
 +        The full path to the file to be edited
 +    regex
 +        A regular expression used to find the lines that are to be commented;
 +        this pattern will be wrapped in parenthesis and will move any
 +        preceding/​trailing ``^`` or ``$`` characters outside the parenthesis
 +        (e.g., the pattern ``^foo$`` will be rewritten as ``^(foo)$``)
 +    char : ``#``
 +        The character to be inserted at the beginning of a line in order to
 +        comment it out
 +    backup : ``.bak``
 +        The file will be backed up before edit with this file extension
 +
 +        Warning:
 +
 +            This backup will be overwritten each time ``sed`` / ``comment`` /
 +            ``uncomment`` is called. Meaning the backup will only be useful
 +            after the first invocation.
 +
 +    CLI Example:
 +
 +        salt '​*'​ file.comment /​etc/​modules pcspkr
 +    ​
 +
 +file.comment_line:​
 +
 +    Comment or Uncomment a line in a text file.
 +
 +    :param path: string
 +        The full path to the text file.
 +
 +    :param regex: string
 +        A regex expression that begins with ``^`` that will find the line you wish
 +        to comment. Can be as simple as ``^color =``
 +
 +    :param char: string
 +        The character used to comment a line in the type of file you're referencing.
 +        Default is ``#``
 +
 +    :param cmnt: boolean
 +        True to comment the line. False to uncomment the line. Default is True.
 +
 +    :param backup: string
 +        The file extension to give the backup file. Default is ``.bak``
 +
 +    :return: boolean
 +        Returns True if successful, False if not
 +
 +    CLI Example:
 +
 +    The following example will comment out the ``pcspkr`` line in the
 +    ``/​etc/​modules`` file using the default ``#`` character and create a backup
 +    file named ``modules.bak``
 +
 +        salt '​*'​ file.comment_line '/​etc/​modules'​ '​^pcspkr'​
 +
 +
 +    CLI Example:
 +
 +    The following example will uncomment the ``log_level`` setting in ``minion``
 +    config file if it is set to either ``warning``,​ ``info``, or ``debug`` using
 +    the ``#`` character and create a backup file named ``minion.bk``
 +
 +        salt '​*'​ file.comment_line '​C:​\salt\conf\minion'​ '​^log_level:​ (warning|info|debug)'​ '#'​ False '​.bk'​
 +    ​
 +
 +file.contains:​
 +
 +    .. deprecated::​ 0.17.0
 +       Use :​func:​`search` instead.
 +
 +    Return ``True`` if the file at ``path`` contains ``text``
 +
 +    CLI Example:
 +
 +        salt '​*'​ file.contains /​etc/​crontab '​mymaintenance.sh'​
 +    ​
 +
 +file.contains_glob:​
 +
 +    .. deprecated::​ 0.17.0
 +       Use :​func:​`search` instead.
 +
 +    Return ``True`` if the given glob matches a string in the named file
 +
 +    CLI Example:
 +
 +        salt '​*'​ file.contains_glob /etc/foobar '​*cheese*'​
 +    ​
 +
 +file.contains_regex:​
 +
 +    .. deprecated::​ 0.17.0
 +       Use :​func:​`search` instead.
 +
 +    Return True if the given regular expression matches on any line in the text
 +    of a given file.
 +
 +    If the lchar argument (leading char) is specified, it
 +    will strip `lchar` from the left side of each line before trying to match
 +
 +    CLI Example:
 +
 +        salt '​*'​ file.contains_regex /​etc/​crontab
 +    ​
 +
 +file.contains_regex_multiline:​
 +
 +    .. deprecated::​ 0.17.0
 +       Use :​func:​`search` instead.
 +
 +    Return True if the given regular expression matches anything in the text
 +    of a given file
 +
 +    Traverses multiple lines at a time, via the salt BufferedReader (reads in
 +    chunks)
 +
 +    CLI Example:
 +
 +        salt '​*'​ file.contains_regex_multiline /​etc/​crontab '​^maint'​
 +    ​
 +
 +file.copy:
 +
 +    Copy a file or directory from source to dst
 +
 +    In order to copy a directory, the recurse flag is required, and
 +    will by default overwrite files in the destination with the same path,
 +    and retain all other existing files. (similar to cp -r on unix)
 +
 +    remove_existing will remove all files in the target directory,
 +    and then copy files from the source.
 +
 +    CLI Example:
 +
 +        salt '​*'​ file.copy /​path/​to/​src /​path/​to/​dst
 +        salt '​*'​ file.copy /​path/​to/​src_dir /​path/​to/​dst_dir recurse=True
 +        salt '​*'​ file.copy /​path/​to/​src_dir /​path/​to/​dst_dir recurse=True remove_existing=True
 +
 +    ​
 +
 +file.delete_backup:​
 +
 +    New in version 0.17.0
 +
 +    Delete a previous version of a file that was backed up using Salt's
 +    :doc:`file state backup </​ref/​states/​backup_mode>​` system.
 +
 +    path
 +        The path on the minion to check for backups
 +    backup_id
 +        The numeric id for the backup you wish to delete, as found using
 +        :​mod:​`file.list_backups <​salt.modules.file.list_backups>​`
 +
 +    CLI Example:
 +
 +        salt '​*'​ file.restore_backup /​foo/​bar/​baz.txt 0
 +    ​
 +
 +file.directory_exists:​
 +
 +    Tests to see if path is a valid directory. ​ Returns True/False.
 +
 +    CLI Example:
 +
 +        salt '​*'​ file.directory_exists /etc
 +
 +    ​
 +
 +file.dirname:​
 +
 +    Returns the directory component of a pathname
 +
 +    New in version 2015.5.0
 +
 +    This can be useful at the CLI but is frequently useful when scripting.
 +
 +        {%- from salt['​file.dirname'​](tpldir) + '/​vars.jinja'​ import parent_vars %}
 +
 +    CLI Example:
 +
 +        salt '​*'​ file.dirname '​test/​path/​filename.config'​
 +    ​
 +
 +file.diskusage:​
 +
 +    Recursively calculate disk usage of path and return it
 +    in bytes
 +
 +    CLI Example:
 +
 +        salt '​*'​ file.diskusage /​path/​to/​check
 +    ​
 +
 +file.extract_hash:​
 +
 +    This routine is called from the :​mod:​`file.managed
 +    <​salt.states.file.managed>​` state to pull a hash from a remote file.
 +    Regular expressions are used line by line on the ``source_hash`` file, to
 +    find a potential candidate of the indicated hash type.  This avoids many
 +    problems of arbitrary file lay out rules. It specifically permits pulling
 +    hash codes from debian ``*.dsc`` files.
 +
 +    For example:
 +
 +        openerp_7.0-latest-1.tar.gz:​
 +          file.managed:​
 +            - name: /​tmp/​openerp_7.0-20121227-075624-1_all.deb
 +            - source: http://​nightly.openerp.com/​7.0/​nightly/​deb/​openerp_7.0-20121227-075624-1.tar.gz
 +            - source_hash:​ http://​nightly.openerp.com/​7.0/​nightly/​deb/​openerp_7.0-20121227-075624-1.dsc
 +
 +    CLI Example:
 +
 +        salt '​*'​ file.extract_hash /etc/foo sha512 /​path/​to/​hash/​file
 +    ​
 +
 +file.file_exists:​
 +
 +    Tests to see if path is a valid file.  Returns True/False.
 +
 +    CLI Example:
 +
 +        salt '​*'​ file.file_exists /etc/passwd
 +
 +    ​
 +
 +file.find:
 +
 +    Approximate the Unix ``find(1)`` command and return a list of paths that
 +    meet the specified criteria.
 +
 +    The options include match criteria:
 +
 +        name    = path-glob ​                # case sensitive
 +        iname   = path-glob ​                # case insensitive
 +        regex   = path-regex ​               # case sensitive
 +        iregex ​ = path-regex ​               # case insensitive
 +        type    = file-types ​               # match any listed type
 +        user    = users                     # match any listed user
 +        group   = groups ​                   # match any listed group
 +        size    = [+-]number[size-unit] ​    # default unit = byte
 +        mtime   = interval ​                 # modified since date
 +        grep    = regex                     # search file contents
 +
 +    and/or actions:
 +
 +        delete [= file-types] ​              # default type = '​f'​
 +        exec    = command [arg ...]         # where {} is replaced by pathname
 +        print  [= print-opts]
 +
 +    and/or depth criteria:
 +
 +        maxdepth = maximum depth to transverse in path
 +        mindepth = minimum depth to transverse before checking files or directories
 +
 +    The default action is ``print=path``
 +
 +    ``path-glob``:​
 +
 +        *                = match zero or more chars
 +        ?                = match any char
 +        [abc]            = match a, b, or c
 +        [!abc] or [^abc] = match anything except a, b, and c
 +        [x-y]            = match chars x through y
 +        [!x-y] or [^x-y] = match anything except chars x through y
 +        {a,​b,​c} ​         = match a or b or c
 +
 +    ``path-regex``:​ a Python Regex (regular expression) pattern to match pathnames
 +
 +    ``file-types``:​ a string of one or more of the following:
 +
 +        a: all file types
 +        b: block device
 +        c: character device
 +        d: directory
 +        p: FIFO (named pipe)
 +        f: plain file
 +        l: symlink
 +        s: socket
 +
 +    ``users``: a space and/or comma separated list of user names and/or uids
 +
 +    ``groups``: a space and/or comma separated list of group names and/or gids
 +
 +    ``size-unit``:​
 +
 +        b: bytes
 +        k: kilobytes
 +        m: megabytes
 +        g: gigabytes
 +        t: terabytes
 +
 +    interval:
 +
 +        [<​num>​w] [<​num>​d] [<​num>​h] [<​num>​m] [<​num>​s]
 +
 +        where:
 +            w: week
 +            d: day
 +            h: hour
 +            m: minute
 +            s: second
 +
 +    print-opts: a comma and/or space separated list of one or more of the
 +    following:
 +
 +        group: group name
 +        md5:   MD5 digest of file contents
 +        mode:  file permissions (as integer)
 +        mtime: last modification time (as time_t)
 +        name:  file basename
 +        path:  file absolute path
 +        size:  file size in bytes
 +        type:  file type
 +        user:  user name
 +
 +    CLI Examples:
 +
 +        salt '​*'​ file.find / type=f name=\*.bak size=+10m
 +        salt '​*'​ file.find /var mtime=+30d size=+10m print=path,​size,​mtime
 +        salt '​*'​ file.find /var/log name=\*.[0-9] mtime=+30d size=+10m delete
 +    ​
 +
 +file.get_devmm:​
 +
 +    Get major/minor info from a device
 +
 +    CLI Example:
 +
 +       salt '​*'​ file.get_devmm /dev/chr
 +    ​
 +
 +file.get_diff:​
 +
 +    Return unified diff of file compared to file on master
 +
 +    CLI Example:
 +
 +        salt '​*'​ file.get_diff /​home/​fred/​.vimrc salt://​users/​fred/​.vimrc
 +    ​
 +
 +file.get_gid:​
 +
 +    Return the id of the group that owns a given file
 +
 +    path
 +        file or directory of which to get the gid
 +
 +    follow_symlinks
 +        indicated if symlinks should be followed
 +
 +
 +    CLI Example:
 +
 +        salt '​*'​ file.get_gid /etc/passwd
 +
 +    Changed in version 0.16.4
 +        ``follow_symlinks`` option added
 +    ​
 +
 +file.get_group:​
 +
 +    Return the group that owns a given file
 +
 +    path
 +        file or directory of which to get the group
 +
 +    follow_symlinks
 +        indicated if symlinks should be followed
 +
 +    CLI Example:
 +
 +        salt '​*'​ file.get_group /etc/passwd
 +
 +    Changed in version 0.16.4
 +        ``follow_symlinks`` option added
 +    ​
 +
 +file.get_hash:​
 +
 +    Get the hash sum of a file
 +
 +    This is better than ``get_sum`` for the following reasons:
 +        - It does not read the entire file into memory.
 +        - It does not return a string on error. The returned value of
 +            ``get_sum`` cannot really be trusted since it is vulnerable to
 +            collisions: ``get_sum(...,​ '​xyz'​) == 'Hash xyz not supported'​``
 +
 +    path
 +        path to the file or directory
 +
 +    form
 +        desired sum format
 +
 +    chunk_size
 +        amount to sum at once
 +
 +    CLI Example:
 +
 +        salt '​*'​ file.get_hash /etc/shadow
 +    ​
 +
 +file.get_managed:​
 +
 +    Return the managed file data for file.managed
 +
 +    name
 +        location where the file lives on the server
 +
 +    template
 +        template format
 +
 +    source
 +        managed source file
 +
 +    source_hash
 +        hash of the source file
 +
 +    user
 +        user owner
 +
 +    group
 +        group owner
 +
 +    mode
 +        file mode
 +
 +    context
 +        variables to add to the environment
 +
 +    default
 +        default values of for context_dict
 +
 +
 +    CLI Example:
 +
 +        salt '​*'​ file.get_managed /​etc/​httpd/​conf.d/​httpd.conf jinja salt://​http/​httpd.conf '​{hash_type:​ '​md5',​ '​hsum':​ <​md5sum>​}'​ root root '​755'​ base None None
 +    ​
 +
 +file.get_mode:​
 +
 +    Return the mode of a file
 +
 +    path
 +        file or directory of which to get the mode
 +
 +    follow_symlinks
 +        indicated if symlinks should be followed
 +
 +    CLI Example:
 +
 +        salt '​*'​ file.get_mode /etc/passwd
 +
 +    Changed in version 2014.1.0
 +        ``follow_symlinks`` option added
 +    ​
 +
 +file.get_selinux_context:​
 +
 +    Get an SELinux context from a given path
 +
 +    CLI Example:
 +
 +        salt '​*'​ file.get_selinux_context /etc/hosts
 +    ​
 +
 +file.get_sum:​
 +
 +    Return the checksum for the given file. The following checksum algorithms
 +    are supported:
 +
 +    * md5
 +    * sha1
 +    * sha224
 +    * sha256 **(default)**
 +    * sha384
 +    * sha512
 +
 +    path
 +        path to the file or directory
 +
 +    form
 +        desired sum format
 +
 +    CLI Example:
 +
 +        salt '​*'​ file.get_sum /etc/passwd sha512
 +    ​
 +
 +file.get_uid:​
 +
 +    Return the id of the user that owns a given file
 +
 +    path
 +        file or directory of which to get the uid
 +
 +    follow_symlinks
 +        indicated if symlinks should be followed
 +
 +    CLI Example:
 +
 +        salt '​*'​ file.get_uid /etc/passwd
 +
 +    Changed in version 0.16.4
 +        ``follow_symlinks`` option added
 +    ​
 +
 +file.get_user:​
 +
 +    Return the user that owns a given file
 +
 +    path
 +        file or directory of which to get the user
 +
 +    follow_symlinks
 +        indicated if symlinks should be followed
 +
 +    CLI Example:
 +
 +        salt '​*'​ file.get_user /etc/passwd
 +
 +    Changed in version 0.16.4
 +        ``follow_symlinks`` option added
 +    ​
 +
 +file.gid_to_group:​
 +
 +    Convert the group id to the group name on this system
 +
 +    gid
 +        gid to convert to a group name
 +
 +    CLI Example:
 +
 +        salt '​*'​ file.gid_to_group 0
 +    ​
 +
 +file.grep:
 +
 +    Grep for a string in the specified file
 +
 +    Note:
 +        This function'​s return value is slated for refinement in future
 +        versions of Salt
 +
 +    path
 +        A file path
 +    pattern
 +        A string. For example:
 +        ``test``
 +        ``a[0-5]``
 +    args
 +        grep options. For example:
 +        ``" -v"``
 +        ``" -i -B2"``
 +
 +    CLI Example:
 +
 +        salt '​*'​ file.grep /etc/passwd nobody
 +        salt '​*'​ file.grep /​etc/​sysconfig/​network-scripts/​ifcfg-eth0 ipaddr " -i"
 +        salt '​*'​ file.grep /​etc/​sysconfig/​network-scripts/​ifcfg-eth0 ipaddr " -i -B2"
 +        salt '​*'​ file.grep "/​etc/​sysconfig/​network-scripts/​*"​ ipaddr " -i -l"
 +    ​
 +
 +file.group_to_gid:​
 +
 +    Convert the group to the gid on this system
 +
 +    group
 +        group to convert to its gid
 +
 +    CLI Example:
 +
 +        salt '​*'​ file.group_to_gid root
 +    ​
 +
 +file.is_blkdev:​
 +
 +    Check if a file exists and is a block device.
 +
 +    CLI Example:
 +
 +       salt '​*'​ file.is_blkdev /dev/blk
 +    ​
 +
 +file.is_chrdev:​
 +
 +    Check if a file exists and is a character device.
 +
 +    CLI Example:
 +
 +       salt '​*'​ file.is_chrdev /dev/chr
 +    ​
 +
 +file.is_fifo:​
 +
 +    Check if a file exists and is a FIFO.
 +
 +    CLI Example:
 +
 +       salt '​*'​ file.is_fifo /dev/fifo
 +    ​
 +
 +file.is_link:​
 +
 +    Check if the path is a symlink
 +
 +    CLI Example:
 +
 +       salt '​*'​ file.is_link /​path/​to/​link
 +    ​
 +
 +file.join:
 +
 +    Return a normalized file system path for the underlying OS
 +
 +    New in version 2014.7.0
 +
 +    This can be useful at the CLI but is frequently useful when scripting
 +    combining path variables:
 +
 +        {% set www_root = '/​var'​ %}
 +        {% set app_dir = '​myapp'​ %}
 +
 +        myapp_config:​
 +          file:
 +            - managed
 +            - name: {{ salt['​file.join'​](www_root,​ app_dir, '​config.yaml'​) }}
 +
 +    CLI Example:
 +
 +        salt '​*'​ file.join '/'​ '​usr'​ '​local'​ '​bin'​
 +    ​
 +
 +file.lchown:​
 +
 +    Chown a file, pass the file the desired user and group without following
 +    symlinks.
 +
 +    path
 +        path to the file or directory
 +
 +    user
 +        user owner
 +
 +    group
 +        group owner
 +
 +    CLI Example:
 +
 +        salt '​*'​ file.chown /etc/passwd root root
 +    ​
 +
 +file.line:
 +
 +    New in version 2015.8.0
 +
 +    Edit a line in the configuration file.
 +
 +    :param path:
 +        Filesystem path to the file to be edited.
 +
 +    :param content:
 +        Content of the line.
 +
 +    :param match:
 +        Match the target line for an action by
 +        a fragment of a string or regular expression.
 +
 +    :param mode:
 +        Ensure
 +            If line does not exist, it will be added.
 +
 +        Replace
 +            If line already exist, it will be replaced.
 +
 +        Delete
 +            Delete the line, once found.
 +
 +        Insert
 +            Insert a line.
 +
 +    :param location:
 +        start
 +            Place the content at the beginning of the file.
 +
 +        end
 +            Place the content at the end of the file.
 +
 +    :param before:
 +        Regular expression or an exact case-sensitive fragment of the string.
 +
 +    :param after:
 +        Regular expression or an exact case-sensitive fragment of the string.
 +
 +    :param show_changes
 +        Output a unified diff of the old file and the new file.
 +        If ``False`` return a boolean if any changes were made.
 +        Default is ``True``
 +
 +        Note:
 +
 +            Using this option will store two copies of the file in-memory
 +            (the original version and the edited version) in order to generate the diff.
 +
 +    :param backup
 +        Create a backup of the original file with the extension:
 +        "​Year-Month-Day-Hour-Minutes-Seconds"​.
 +
 +    :param quiet
 +        Do not raise any exceptions. E.g. ignore the fact that the file that is
 +        tried to be edited does not exist and nothing really happened.
 +
 +    :param indent
 +        Keep indentation with the previous line.
 +
 +    If an equal sign (``=``) appears in an argument to a Salt command, it is
 +    interpreted as a keyword argument in the format of ``key=val``. That
 +    processing can be bypassed in order to pass an equal sign through to the
 +    remote shell command by manually specifying the kwarg:
 +
 +        salt '​*'​ file.line /​path/​to/​file content="​CREATEMAIL_SPOOL=no"​ match="​CREATE_MAIL_SPOOL=yes"​ mode="​replace"​
 +
 +    CLI Examples:
 +
 +        salt '​*'​ file.line /​etc/​nsswitch.conf "​networks:​ files dns", after="​hosts:​.*?",​ mode='​ensure'​
 +    ​
 +
 +file.link:
 +
 +    New in version 2014.1.0
 +
 +    Create a hard link to a file
 +
 +    CLI Example:
 +
 +        salt '​*'​ file.link /​path/​to/​file /​path/​to/​link
 +    ​
 +
 +file.list_backup:​
 +
 +This function is an alias of ``list_backups``.
 +
 +    New in version 0.17.0
 +
 +    Lists the previous versions of a file backed up using Salt's :doc:`file
 +    state backup </​ref/​states/​backup_mode>​` system.
 +
 +    path
 +        The path on the minion to check for backups
 +    limit
 +        Limit the number of results to the most recent N backups
 +
 +    CLI Example:
 +
 +        salt '​*'​ file.list_backups /​foo/​bar/​baz.txt
 +    ​
 +
 +file.list_backups:​
 +
 +    New in version 0.17.0
 +
 +    Lists the previous versions of a file backed up using Salt's :doc:`file
 +    state backup </​ref/​states/​backup_mode>​` system.
 +
 +    path
 +        The path on the minion to check for backups
 +    limit
 +        Limit the number of results to the most recent N backups
 +
 +    CLI Example:
 +
 +        salt '​*'​ file.list_backups /​foo/​bar/​baz.txt
 +    ​
 +
 +file.list_backups_dir:​
 +
 +    Lists the previous versions of a directory backed up using Salt's :doc:`file
 +    state backup </​ref/​states/​backup_mode>​` system.
 +
 +    path
 +        The directory on the minion to check for backups
 +    limit
 +        Limit the number of results to the most recent N backups
 +
 +    CLI Example:
 +
 +        salt '​*'​ file.list_backups_dir /​foo/​bar/​baz/​
 +    ​
 +
 +file.lstat:
 +
 +    New in version 2014.1.0
 +
 +    Returns the lstat attributes for the given file or dir. Does not support
 +    symbolic links.
 +
 +    CLI Example:
 +
 +        salt '​*'​ file.lstat /​path/​to/​file
 +    ​
 +
 +file.makedirs:​
 +
 +    Ensure that the directory containing this path is available.
 +
 +    Note:
 +
 +        The path must end with a trailing slash otherwise the directory/​directories
 +        will be created up to the parent directory. For example if path is
 +        ``/​opt/​code``,​ then it would be treated as ``/opt/`` but if the path
 +        ends with a trailing slash like ``/​opt/​code/​``,​ then it would be
 +        treated as ``/​opt/​code/​``.
 +
 +    CLI Example:
 +
 +        salt '​*'​ file.makedirs /opt/code/
 +    ​
 +
 +file.makedirs_perms:​
 +
 +    Taken and modified from os.makedirs to set user, group and mode for each
 +    directory created.
 +
 +    CLI Example:
 +
 +        salt '​*'​ file.makedirs_perms /opt/code
 +    ​
 +
 +file.manage_file:​
 +
 +    Checks the destination against what was retrieved with get_managed and
 +    makes the appropriate modifications (if necessary).
 +
 +    name
 +        location to place the file
 +
 +    sfn
 +        location of cached file on the minion
 +
 +        This is the path to the file stored on the minion. This file is placed on the minion
 +        using cp.cache_file. ​ If the hash sum of that file matches the source_sum, we do not
 +        transfer the file to the minion again.
 +
 +        This file is then grabbed and if it has template set, it renders the file to be placed
 +        into the correct place on the system using salt.files.utils.copyfile()
 +
 +    ret
 +        The initial state return data structure. Pass in ``None`` to use the default structure.
 +
 +    source
 +        file reference on the master
 +
 +    source_hash
 +        sum hash for source
 +
 +    user
 +        user owner
 +
 +    group
 +        group owner
 +
 +    backup
 +        backup_mode
 +
 +    makedirs
 +        make directories if they do not exist
 +
 +    template
 +        format of templating
 +
 +    show_diff
 +        Include diff in state return
 +
 +    contents:
 +        contents to be placed in the file
 +
 +    dir_mode
 +        mode for directories created with makedirs
 +
 +    CLI Example:
 +
 +        salt '​*'​ file.manage_file /​etc/​httpd/​conf.d/​httpd.conf ''​ '​{}'​ salt://​http/​httpd.conf '​{hash_type:​ '​md5',​ '​hsum':​ <​md5sum>​}'​ root root '​755'​ base ''​
 +
 +    Changed in version 2014.7.0
 +        ``follow_symlinks`` option added
 +
 +    ​
 +
 +file.mkdir:
 +
 +    Ensure that a directory is available.
 +
 +    CLI Example:
 +
 +        salt '​*'​ file.mkdir /​opt/​jetty/​context
 +    ​
 +
 +file.mknod:
 +
 +    New in version 0.17.0
 +
 +    Create a block device, character device, or fifo pipe.
 +    Identical to the gnu mknod.
 +
 +    CLI Examples:
 +
 +        salt '​*'​ file.mknod /dev/chr c 180 31
 +        salt '​*'​ file.mknod /dev/blk b 8 999
 +        salt '​*'​ file.nknod /dev/fifo p
 +    ​
 +
 +file.mknod_blkdev:​
 +
 +    New in version 0.17.0
 +
 +    Create a block device.
 +
 +    CLI Example:
 +
 +       salt '​*'​ file.mknod_blkdev /dev/blk 8 999
 +    ​
 +
 +file.mknod_chrdev:​
 +
 +    New in version 0.17.0
 +
 +    Create a character device.
 +
 +    CLI Example:
 +
 +       salt '​*'​ file.mknod_chrdev /dev/chr 180 31
 +    ​
 +
 +file.mknod_fifo:​
 +
 +    New in version 0.17.0
 +
 +    Create a FIFO pipe.
 +
 +    CLI Example:
 +
 +       salt '​*'​ file.mknod_fifo /dev/fifo
 +    ​
 +
 +file.move:
 +
 +    Move a file or directory
 +
 +    CLI Example:
 +
 +        salt '​*'​ file.move /​path/​to/​src /​path/​to/​dst
 +    ​
 +
 +file.normpath:​
 +
 +    Returns Normalize path, eliminating double slashes, etc.
 +
 +    New in version 2015.5.0
 +
 +    This can be useful at the CLI but is frequently useful when scripting.
 +
 +        {%- from salt['​file.normpath'​](tpldir + '/​../​vars.jinja'​) import parent_vars %}
 +
 +    CLI Example:
 +
 +        salt '​*'​ file.normpath '​a/​b/​c/​..'​
 +    ​
 +
 +file.open_files:​
 +
 +    Return a list of all physical open files on the system.
 +
 +    CLI Examples:
 +