64 lines
2.1 KiB
Cheetah
64 lines
2.1 KiB
Cheetah
#set controllers = $getVar('controller', [])
|
|
#set computes = $getVar('compute', [])
|
|
#set has = $getVar('ha', [])
|
|
#set odls = $getVar('odl', [])
|
|
#set onoss = $getVar('onos', [])
|
|
#set cephs = $getVar('ceph',[])
|
|
#if not $isinstance($controllers, list)
|
|
#set controllers = [$controllers]
|
|
#end if
|
|
#if not $isinstance($computes, list)
|
|
#set computes = [$computes]
|
|
#end if
|
|
#if not $isinstance(has, list)
|
|
#set has = [has]
|
|
#end if
|
|
#if not $isinstance(odls, list)
|
|
#set odls = [odls]
|
|
#end if
|
|
#if not $isinstance(onoss, list)
|
|
#set onoss = [onoss]
|
|
#end if
|
|
#if not $isinstance(cephs, list)
|
|
#set cephs = [cephs]
|
|
#end if
|
|
#set credentials = $getVar('server_credentials', {})
|
|
#set username = $credentials.get('username', 'root')
|
|
#set password = $credentials.get('password', 'root')
|
|
[controller]
|
|
#for controller in $controllers
|
|
#set controller_ip = $controller.install.ip
|
|
#set controller_hostname = $controller.hostname
|
|
$controller_hostname ansible_ssh_host=$controller_ip ansible_ssh_user=$username ansible_ssh_password=$password
|
|
#end for
|
|
[compute]
|
|
#for compute in $computes
|
|
#set compute_ip = $compute.install.ip
|
|
#set compute_hostname = $compute.hostname
|
|
$compute_hostname ansible_ssh_host=$compute_ip ansible_ssh_user=$username ansible_ssh_password=$password
|
|
#end for
|
|
[ha]
|
|
#for ha in $has
|
|
#set ha_ip = $ha.install.ip
|
|
#set ha_hostname = $ha.hostname
|
|
$ha_hostname ansible_ssh_host=$ha_ip ansible_ssh_user=$username ansible_ssh_password=$password
|
|
#end for
|
|
[odl]
|
|
#for odl in $odls
|
|
#set odl_ip = $odl.install.ip
|
|
#set odl_hostname = $odl.hostname
|
|
$odl_hostname ansible_ssh_host=$odl_ip ansible_ssh_user=$username ansible_ssh_password=$password
|
|
#end for
|
|
[onos]
|
|
#for onos in $onoss
|
|
#set onos_ip = $onos.install.ip
|
|
#set onos_hostname = $onos.hostname
|
|
$onos_hostname ansible_ssh_host=$onos_ip ansible_ssh_user=$username ansible_ssh_password=$password
|
|
#end for
|
|
[ceph]
|
|
#for ceph in $cephs
|
|
#set ceph_ip = $ceph.install.ip
|
|
#set ceph_hostname = $ceph.hostname
|
|
$ceph_hostname ansible_ssh_host=$ceph_ip ansible_ssh_user=$username ansible_ssh_password=$password
|
|
#end for
|