mirror of
https://github.com/saltstack/salt.git
synced 2025-04-17 10:10:20 +00:00
Merge pull request #35833 from terminalmage/2015.8-top-file-merging-docs
One more tweak to top file merging docs
This commit is contained in:
commit
b12c6577d2
2 changed files with 14 additions and 9 deletions
|
@ -1024,8 +1024,6 @@ enabled and can be disabled by changing this value to ``False``.
|
|||
``environment``
|
||||
---------------
|
||||
|
||||
Default: ``None``
|
||||
|
||||
Normally the minion is not isolated to any single environment on the master
|
||||
when running states, but the environment can be isolated on the minion side
|
||||
by statically setting it. Remember that the recommended way to manage
|
||||
|
@ -1040,14 +1038,22 @@ environments is to isolate via the top file.
|
|||
``state_top_saltenv``
|
||||
---------------------
|
||||
|
||||
Default: not set
|
||||
This option has no default value. Set it to an environment name to ensure that
|
||||
*only* the top file from that environment is considered during a
|
||||
:ref:`highstate <running-highstate>`.
|
||||
|
||||
Set this option to an environment name, to ensure that *only* the top file from
|
||||
that environment is considered during a :ref:`highstate <running-highstate>`.
|
||||
.. note::
|
||||
Using this value does not change the merging strategy. For instance, if
|
||||
:conf_minion:`top_file_merging_strategy` is left at its default, and
|
||||
:conf_minion:`state_top_saltenv` is set to ``foo``, then any sections for
|
||||
environments other than ``foo`` in the top file for the ``foo`` environment
|
||||
will be ignored. With :conf_minion:`top_file_merging_strategy` set to
|
||||
``base``, all states from all environments in the ``base`` top file will
|
||||
be applied, while all other top files are ignored.
|
||||
|
||||
.. code-block:: yaml
|
||||
|
||||
state_top_saltenv: base
|
||||
state_top_saltenv: dev
|
||||
|
||||
.. conf_minion:: top_file_merging_strategy
|
||||
|
||||
|
|
|
@ -437,9 +437,8 @@ Scenario 2 - No Environment Specified, :conf_minion:`top_file_merging_strategy`
|
|||
In this scenario, assuming that the ``base`` environment's top file was
|
||||
evaluated first, the ``base1``, ``dev1``, and ``qa1`` states would be applied
|
||||
to all minions. If, for instance, the ``qa`` environment is not defined in
|
||||
**/srv/salt/base/top.sls**, then the ``qa`` section in
|
||||
**/srv/salt/dev/top.sls** would be used and the ``qa2`` states would be applied
|
||||
to all minions.
|
||||
**/srv/salt/base/top.sls**, then because there is no top file for the ``qa``
|
||||
environment, no states from the ``qa`` environment would be applied.
|
||||
|
||||
Scenario 3 - No Environment Specified, :conf_minion:`top_file_merging_strategy` is "same"
|
||||
-----------------------------------------------------------------------------------------
|
||||
|
|
Loading…
Add table
Reference in a new issue