Use MACRO_INSTALL_FORMULAS for model generators
Change-Id: I91ff0664c819e4fc49d334473231d387063f9910
diff --git a/tcp_tests/templates/cookied-model-generator/salt_cookied-bm-mcp-ocata-contrail.yaml b/tcp_tests/templates/cookied-model-generator/salt_cookied-bm-mcp-ocata-contrail.yaml
index c5681be..0915547 100644
--- a/tcp_tests/templates/cookied-model-generator/salt_cookied-bm-mcp-ocata-contrail.yaml
+++ b/tcp_tests/templates/cookied-model-generator/salt_cookied-bm-mcp-ocata-contrail.yaml
@@ -13,30 +13,8 @@
{% import 'shared-salt.yaml' as SHARED with context %}
{{ SHARED.MACRO_INSTALL_PACKAGES_ON_NODES(HOSTNAME_CFG01) }}
-- description: Re-install all the fromulas
- cmd: |
- set -e;
- apt-get install -y salt-formula-*
- node_name: {{ HOSTNAME_CFG01 }}
- retry: {count: 1, delay: 1}
- skip_fail: false
-- description: Sync formulas to service
- cmd: |
- set -e;
- RECLASS_ROOT=${RECLASS_ROOT:-/srv/salt/reclass/};
- FORMULAS_PATH=${FORMULAS_PATH:-/usr/share/salt-formulas};
- [ ! -d ${RECLASS_ROOT}/classes/service ] && mkdir -p ${RECLASS_ROOT}/classes/service;
- for formula_service in $(ls /usr/share/salt-formulas/reclass/service/); do
- #Since some salt formula names contain "-" and in symlinks they should contain "_" adding replacement;
- formula_service=${formula_service//-/$'_'};
- if [ ! -L "${RECLASS_ROOT}/classes/service/${formula_service}" ]; then
- ln -sf ${FORMULAS_PATH}/reclass/service/${formula_service} ${RECLASS_ROOT}/classes/service/${formula_service};
- fi;
- done
- node_name: {{ HOSTNAME_CFG01 }}
- retry: {count: 1, delay: 1}
- skip_fail: false
+{{ SHARED.MACRO_INSTALL_FORMULAS('\*') }}
{{ SHARED.MACRO_GENERATE_COOKIECUTTER_MODEL(CONTROL_VLAN=CONTROL_VLAN, TENANT_VLAN=TENANT_VLAN) }}