blob: 745b97c5da0460bf4dda374bb78601c8548aefc3 [file] [log] [blame]
sgudza133b8e2019-05-10 14:32:08 +03001{% set HOSTNAME_CFG01='cfg01.heat-cicd-k8s-calico-sl.local' %}
2{% set LAB_CONFIG_NAME='heat-cicd-k8s-calico-sl' %}
3{% set DOMAIN_NAME='heat-cicd-k8s-calico-sl.local' %}
4{% set SALT_MODELS_REPOSITORY = os_env('SALT_MODELS_REPOSITORY','https://gerrit.mcp.mirantis.com/salt-models/mcp-virtual-lab') %}
5# Other salt model repository parameters see in shared-salt.yaml
6
7{% import 'shared-salt.yaml' as SHARED with context %}
8
9{{ SHARED.MACRO_INSTALL_SALT_MINIONS() }}
10
11{{SHARED.MACRO_CHECK_SALT_VERSION_SERVICES_ON_CFG()}}
12
13{{SHARED.MACRO_CHECK_SALT_VERSION_ON_NODES()}}
14
15- description: "Share custom key from cfg to give each node acces with key from cfg01"
16 cmd: |
17 set -e;
18 set -x;
19 key=$(ssh-keygen -y -f /root/.ssh/id_rsa);
20 salt '*' cmd.run "echo $key >> /root/.ssh/authorized_keys";
21 node_name: {{ HOSTNAME_CFG01 }}
22 retry: {count: 1, delay: 5}
23 skip_fail: true