Bladeren bron

fix mass install of formula pkgs

Previous approach fails when all of formulas are installed from git.

Change-Id: I0622461ee6469c59c1fd3ad4a23cdaeaeee1b444
pull/31/merge
Tomáš Kukrál 7 jaren geleden
bovenliggende
commit
04aa7b4bc7
1 gewijzigde bestanden met toevoegingen van 13 en 4 verwijderingen
  1. +13
    -4
      salt/master/env.sls

+ 13
- 4
salt/master/env.sls Bestand weergeven

@@ -135,15 +135,24 @@ salt_env_{{ environment_name }}_dirs:

{%- endif %}

salt_master_{{ environment_name }}_pkg_formulas:
pkg.latest:
- pkgs:
{%- set _formula_pkgs = [] %}
{%- for formula_name, formula in environment.get('formula', {}).iteritems() %}
{%- if formula.source == 'pkg' %}
- {{ formula.name }}
{%- do _formula_pkgs.append(formula.name) %}
{%- endif %}
{%- endfor %}

{% if _formula_pkgs|length > 1 %}

salt_master_{{ environment_name }}_pkg_formulas:
pkg.latest:
- pkgs:
{%- for pkg in _formula_pkgs %}
- {{ pkg }}
{%- endfor %}

{% endif %}

{%- for formula_name, formula in environment.get('formula', {}).iteritems() %}

{%- if formula.source == 'git' %}

Laden…
Annuleren
Opslaan