blob: 4ea0035e60e1f662db2cea567c066aeda52073bd [file] [log] [blame]
sgudzc97385a2018-11-29 17:01:53 +02001{% from 'cookied-cicd-bm-os-contrail40-maas/underlay.yaml' import HOSTNAME_CFG01 with context %}
2{% from 'cookied-cicd-bm-os-contrail40-maas/underlay.yaml' import LAB_CONFIG_NAME with context %}
3{% from 'cookied-cicd-bm-os-contrail40-maas/underlay.yaml' import DOMAIN_NAME with context %}
4
5# Other salt model repository parameters see in shared-salt.yaml
6
7{% import 'shared-salt.yaml' as SHARED with context %}
8
9- description: Wait for salt-master is ready after configdrive user-data
10 cmd: |
11 timeout 120 salt-call test.ping
12 node_name: {{ HOSTNAME_CFG01 }}
13 retry: {count: 2, delay: 5}
14 skip_fail: false
15
16{{ SHARED.MACRO_INSTALL_SALT_MINIONS() }}
17
18{{SHARED.MACRO_CHECK_SALT_VERSION_SERVICES_ON_CFG()}}
19
20{{SHARED.MACRO_CHECK_SALT_VERSION_ON_NODES()}}
21
Dennis Dmitriev74cda482018-12-14 13:01:32 +020022- description: Generate a public key for machines in MAAS
23 cmd: |
24 ssh-keygen -y -f ~root/.ssh/id_rsa > ~root/.ssh/id_rsa.pub
25 maas mirantis sshkeys create key="$(cat ~root/.ssh/id_rsa.pub)"
26 node_name: {{ HOSTNAME_CFG01 }}
27 retry: {count: 1, delay: 5}
28 skip_fail: false
29
sgudzc97385a2018-11-29 17:01:53 +020030- description: Run comissioning of BM nodes
31 cmd: |
32 salt-call maas.process_machines
33 node_name: {{ HOSTNAME_CFG01 }}
34 retry: {count: 1, delay: 5}
35 skip_fail: false
36
37- description: Wait for machines ready
38 cmd: |
39 salt-call maas.machines_status && timeout 120 salt-call state.sls maas.machines.wait_for_ready
40 node_name: {{ HOSTNAME_CFG01 }}
41 retry: {count: 7, delay: 5}
42 skip_fail: false
43
44- description: Enforce the interfaces configuration defined in the model for servers
45 cmd: |
46 salt-call state.sls maas.machines.assign_ip;
47 node_name: {{ HOSTNAME_CFG01 }}
48 retry: {count: 1, delay: 5}
49 skip_fail: false
50
51- description: provision the automatically commissioned physical nodes through MAAS
52 cmd: |
53 salt-call maas.deploy_machines;
54 node_name: {{ HOSTNAME_CFG01 }}
55 retry: {count: 3, delay: 5}
56 skip_fail: false
57
58- description: Wait for machines deployed
59 cmd: |
60 salt-call maas.machines_status && timeout 300 salt-call state.sls maas.machines.wait_for_deployed
61 node_name: {{ HOSTNAME_CFG01 }}
62 retry: {count: 6, delay: 5}
63 skip_fail: false