浏览代码

implementing retro-compatible behavior

Using the old salt.engines pillar and merging it with the new
salt.[master|minion].engines pillar.
This way, it doesn't break previous behavior and permits to define
common engines on master and minion.
In the merge, the salt.[master|minion].engines pillar takes precedence
if conflict as it's the more specific pillar.
master
carpenti 8 年前
父节点
当前提交
08d10376ab
共有 2 个文件被更改,包括 4 次插入2 次删除
  1. +2
    -1
      salt/files/master.d/engine.conf
  2. +2
    -1
      salt/files/minion.d/engine.conf

+ 2
- 1
salt/files/master.d/engine.conf 查看文件

@@ -1,7 +1,8 @@
#
# This file is managed by Salt! Do not edit by hand!
#
{%- set engines = salt['pillar.get']('salt:master:engines') -%}
{%- set engines = salt['pillar.get']('salt:engines') -%}
{%- set engines = salt['pillar.get']('salt:master:engines', default=engines, merge=True) -%}
{%- if engines %}
engines:
{{ engines | yaml(False) | indent(2) }}

+ 2
- 1
salt/files/minion.d/engine.conf 查看文件

@@ -1,7 +1,8 @@
#
# This file is managed by Salt! Do not edit by hand!
#
{%- set engines = salt['pillar.get']('salt:minion:engines') -%}
{%- set engines = salt['pillar.get']('salt:engines') -%}
{%- set engines = salt['pillar.get']('salt:minion:engines', default=engines, merge=True) -%}
{%- if engines %}
engines:
{{ engines | yaml(False) | indent(2) }}

正在加载...
取消
保存