blob: fd0706180f0472b73cc3587ea9c4356be27a03aa [file] [log] [blame]
{% from 'cookied-bm-dpdk-pipeline/underlay.yaml' import HOSTNAME_CFG01 with context %}
{% import 'shared-salt.yaml' as SHARED with context %}
- description: "Give each node root access with key from cfg01"
cmd: |
set -e;
set -x;
key=$(ssh-keygen -y -f /root/.ssh/id_rsa);
salt '*' cmd.run "echo $key >> /root/.ssh/authorized_keys";
salt '*' cmd.run "service sshd restart"
node_name: {{ HOSTNAME_CFG01 }}
retry: {count: 1, delay: 5}
skip_fail: true
- description: temp WR
cmd: salt --hard-crash --state-output=mixed --state-verbose=False 'cmp*' cmd.run
'ifdown br-prv; ifup br-prv'
node_name: {{ HOSTNAME_CFG01 }}
retry: {count: 1, delay: 30}
skip_fail: false
- description: Create net04_external
cmd: salt --hard-crash --state-output=mixed --state-verbose=False 'ctl01*' cmd.run
'. /root/keystonercv3; neutron net-create net04_ext --router:external True --provider:physical_network physnet1 --provider:network_type flat'
node_name: {{ HOSTNAME_CFG01 }}
retry: {count: 1, delay: 30}
skip_fail: false
- description: Create subnet_external
cmd: salt --hard-crash --state-output=mixed --state-verbose=False 'ctl01*' cmd.run
'. /root/keystonercv3; neutron subnet-create net04_ext 172.17.42.128/26 --name net04_ext__subnet --disable-dhcp --allocation-pool start=172.17.42.130,end=172.17.42.180 --gateway 172.17.42.129'
node_name: {{ HOSTNAME_CFG01 }}
retry: {count: 1, delay: 30}
skip_fail: false
- description: Create net04
cmd: salt --hard-crash --state-output=mixed --state-verbose=False 'ctl01*' cmd.run
'. /root/keystonercv3; neutron net-create net04 --provider:network_type flat'
node_name: {{ HOSTNAME_CFG01 }}
retry: {count: 1, delay: 30}
skip_fail: false
- description: Create subnet_net04
cmd: salt --hard-crash --state-output=mixed --state-verbose=False 'ctl01*' cmd.run
'. /root/keystonercv3; neutron subnet-create net04 192.168.1.0/24 --name net04__subnet --allocation-pool start=192.168.1.150,end=192.168.1.240'
node_name: {{ HOSTNAME_CFG01 }}
retry: {count: 1, delay: 30}
skip_fail: false
- description: Create router
cmd: salt --hard-crash --state-output=mixed --state-verbose=False 'ctl01*' cmd.run
'. /root/keystonercv3; neutron router-create net04_router01 --ha False'
node_name: {{ HOSTNAME_CFG01 }}
retry: {count: 1, delay: 30}
skip_fail: false
- description: Set geteway
cmd: salt --hard-crash --state-output=mixed --state-verbose=False 'ctl01*' cmd.run
'. /root/keystonercv3; neutron router-gateway-set net04_router01 net04_ext'
node_name: {{ HOSTNAME_CFG01 }}
retry: {count: 1, delay: 30}
skip_fail: false
- description: Add interface
cmd: salt --hard-crash --state-output=mixed --state-verbose=False 'ctl01*' cmd.run
'. /root/keystonercv3; neutron router-interface-add net04_router01 net04__subnet'
node_name: {{ HOSTNAME_CFG01 }}
retry: {count: 1, delay: 30}
skip_fail: false
{{ SHARED.INSTALL_DOCKER_ON_GTW() }}