forked from saltstack/salt
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge remote-tracking branch 'upstream/develop' into develop
* upstream/develop: (32 commits) Libcloud DNS module fix (saltstack#34628) Properly pass in userdata as string (saltstack#34623) Add NILinuxRT support to timezone execution module (saltstack#34556) Properly gate makostack (saltstack#34614) Add support for edge case when Cmd and Entrypoint can't be blanked (saltstack#34593) Update github IP for ssh state integration tests (saltstack#34592) When sorting list actual_data, make it a list (saltstack#34590) Avoid circular imports when calling salt.utils functions (saltstack#34586) [2016.3] Avoid salt.utils circular imports when using "from" (saltstack#34585) Adds a mock required for the network settings beacon Avoid circular imports when calling salt.utils functions (saltstack#34584) Gate docker unit test to check for docker (saltstack#34591) Typo (`defaul` → `default`) Add code formatting Fix typo (`seens` → `seen`) Add a bunch of documentation on getting files from other environments (saltstack#34560) Rename unit.states.boto_secgroup to unit.states.boto_secgroup_test Handle cases where Docker Remote API returns an empty ExecutionDriver Rename tests.unit.simple to tests.unit.simple_test salt/modules/zypper.py: accept ignore_epoch argument ...
- Loading branch information
Showing
39 changed files
with
456 additions
and
99 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -3,4 +3,3 @@ salt.fileserver.azurefs | |
======================= | ||
|
||
.. automodule:: salt.fileserver.azurefs | ||
:members: |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -3,4 +3,3 @@ salt.fileserver.gitfs | |
===================== | ||
|
||
.. automodule:: salt.fileserver.gitfs | ||
:members: |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -3,4 +3,3 @@ salt.fileserver.hgfs | |
==================== | ||
|
||
.. automodule:: salt.fileserver.hgfs | ||
:members: |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -3,4 +3,3 @@ salt.fileserver.minionfs | |
======================== | ||
|
||
.. automodule:: salt.fileserver.minionfs | ||
:members: |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -3,4 +3,3 @@ salt.fileserver.roots | |
===================== | ||
|
||
.. automodule:: salt.fileserver.roots | ||
:members: |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -3,4 +3,3 @@ salt.fileserver.s3fs | |
==================== | ||
|
||
.. automodule:: salt.fileserver.s3fs | ||
:members: |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -3,4 +3,3 @@ salt.fileserver.svnfs | |
===================== | ||
|
||
.. automodule:: salt.fileserver.svnfs | ||
:members: |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,89 @@ | ||
.. _file-server-environments: | ||
|
||
=========================================== | ||
Requesting Files from Specific Environments | ||
=========================================== | ||
|
||
The Salt fileserver supports multiple environments, allowing for SLS files and | ||
other files to be isolated for better organization. | ||
|
||
For the default backend (called :py:mod:`roots <salt.fileserver.roots>`), | ||
environments are defined using the :conf_master:`roots <file_roots>` option. | ||
Other backends (such as :py:mod:`gitfs <salt.fileserver.gitfs>`) define | ||
environments in their own ways. For a list of available fileserver backends, | ||
see :ref:`here <all-salt.fileserver>`. | ||
|
||
.. _querystring-syntax: | ||
|
||
Querystring Syntax | ||
================== | ||
|
||
Any ``salt://`` file URL can specify its fileserver environment using a | ||
querystring syntax, like so: | ||
|
||
.. code-block:: bash | ||
salt://path/to/file?saltenv=foo | ||
In :ref:`Reactor <reactor>` configurations, this method must be used to pull | ||
files from an environment other than ``base``. | ||
|
||
In States | ||
========= | ||
|
||
Minions can be instructed which environment to use both globally, and for a | ||
single state, and multiple methods for each are available: | ||
|
||
Globally | ||
-------- | ||
|
||
A minion can be pinned to an environment using the :conf_minion:`environment` | ||
option in the minion config file. | ||
|
||
Additionally, the environment can be set for a single call to the following | ||
functions: | ||
|
||
- :py:mod:`state.apply <salt.modules.state.apply>` | ||
- :py:mod:`state.highstate <salt.modules.state.highstate>` | ||
- :py:mod:`state.sls <salt.modules.state.sls>` | ||
- :py:mod:`state.top <salt.modules.state.top>` | ||
|
||
.. note:: | ||
When the ``saltenv`` parameter is used to trigger a :ref:`highstate | ||
<running-highstate>` using either :py:mod:`state.apply | ||
<salt.modules.state.apply>` or :py:mod:`state.highstate | ||
<salt.modules.state.highstate>`, only states from that environment will be | ||
applied. | ||
|
||
On a Per-State Basis | ||
-------------------- | ||
|
||
Within an individual state, there are two ways of specifying the environment. | ||
The first is to add a ``saltenv`` argument to the state. This example will pull | ||
the file from the ``config`` environment: | ||
|
||
.. code-block:: yaml | ||
/etc/foo/bar.conf: | ||
file.managed: | ||
- source: salt://foo/bar.conf | ||
- user: foo | ||
- mode: 600 | ||
- saltenv: config | ||
Another way of doing the same thing is to use the :ref:`querystring syntax | ||
<querystring-syntax>` described above: | ||
|
||
.. code-block:: yaml | ||
/etc/foo/bar.conf: | ||
file.managed: | ||
- source: salt://foo/bar.conf?saltenv=config | ||
- user: foo | ||
- mode: 600 | ||
.. note:: | ||
Specifying the environment using either of the above methods is only | ||
necessary in cases where a state from one environment needs to access files | ||
from another environment. If the SLS file containing this state was in the | ||
``config`` environment, then it would look in that environment by default. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.