Browse Source

Pillar from salt, tests metadata

tags/0.4
Ales Komarek 8 years ago
parent
commit
9bc205c5ae
3 changed files with 17 additions and 3 deletions
  1. +5
    -3
      salt/master/pillar.sls
  2. +6
    -0
      tests/pillar/master_single.sls
  3. +6
    -0
      tests/pillar/minion_local.sls

+ 5
- 3
salt/master/pillar.sls View File

@@ -15,12 +15,16 @@ include:
- file: /srv/salt/env
- pkg: git_packages

{%- if master.system is defined %}

/srv/salt/env/{{ master.system.environment }}/top.sls:
file.symlink:
- target: /srv/salt/pillar/files_top.sls
- require:
- file: /srv/salt/env/{{ master.system.environment }}

{%- endif %}

{%- elif master.pillar.engine == 'reclass' %}

include:
@@ -29,7 +33,6 @@ include:
/srv/salt/reclass/classes/service:
file.directory


{%- if master.system is defined %}

{%- for formula_name, formula in master.system.get('formula', {}).iteritems() %}
@@ -68,8 +71,7 @@ include:

{%- endfor %}

{%-endif %}

{%- endif %}

{%- endif %}


+ 6
- 0
tests/pillar/master_single.sls View File

@@ -10,6 +10,12 @@ salt:
command_timeout: 5
worker_threads: 2
base_environment: prd
pillar:
engine: salt
source:
engine: git
address: 'git@repo.domain.com:salt/pillar-demo.git'
branch: 'master'
environment:
prd:
formula:

+ 6
- 0
tests/pillar/minion_local.sls View File

@@ -2,3 +2,9 @@ salt:
minion:
enabled: true
local: true
pillar:
engine: salt
source:
engine: git
address: 'git@repo.domain.com:salt/pillar-demo.git'
branch: 'master'

Loading…
Cancel
Save