Execution
Date
14 Dec 2025 10:02:53 +0000
Duration
00:01:37.94
Controller
np02505b6944e64
User
root
Versions
Ansible
2.18.6
ara
1.7.4 / 1.7.4
Python
3.13.5
Summary
1
Hosts
154
Tasks
154
Results
1
Plays
22
Files
0
Records
File: /home/zuul/src/opendev.org/openstack/openstack-ansible/tests/roles/bootstrap-host/vars/main.yml
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 | --- # Copyright 2017, Rackspace US, Inc. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in writing, software # distributed under the License is distributed on an "AS IS" BASIS, # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. # See the License for the specific language governing permissions and # limitations under the License. bootstrap_host_scenarios: "{{ (bootstrap_host_scenario.split('_') | reject('equalto', '')) | list }}" _lxc_container_backing_store: |- {% if 'zfs' in bootstrap_host_scenarios %} {% set store = 'zfs' %} {% elif 'btrfs' in bootstrap_host_scenarios %} {% set store = 'btrfs' %} {% elif 'dir' in bootstrap_host_scenarios %} {% set store = 'dir' %} {% elif 'lvm' in bootstrap_host_scenarios %} {% set store = 'lvm' %} {% elif 'overlayfs' in bootstrap_host_scenarios %} {% set store = 'overlayfs' %} {% else %} {% set store = 'dir' %} {% endif %} {{ store }} # Expand the scenario list to include specific services that are being deployed # as part of the scenario bootstrap_host_scenarios_expanded: |- {# Keystone is included in every scenario #} {% set scenario_list = bootstrap_host_scenarios + ['keystone', 'haproxy'] %} {% if ['aio', 'translations'] | intersect(bootstrap_host_scenarios) | length > 0 %} {# Base services deployed with aio and translations scenarios #} {% set _ = scenario_list.extend(['cinder', 'glance', 'neutron', 'nova', 'placement', 'horizon']) %} {% endif %} {# Service additions based on scenario presence #} {% if 'cloudkitty' in bootstrap_host_scenarios %} {% set _ = scenario_list.extend(['ceilometer', 'gnocchi']) %} {% endif %} {% if 'designate' in bootstrap_host_scenarios or ('validate' in bootstrap_host_scenarios and ('integrated' in bootstrap_host_scenarios or 'plugins' in bootstrap_host_scenarios)) %} {% set _ = scenario_list.extend(['zookeeper']) %} {% endif %} {% if 'ironic' in bootstrap_host_scenarios %} {% set _ = scenario_list.extend(['swift']) %} {% endif %} {% if ('magnum' in bootstrap_host_scenarios) %} {% set _ = scenario_list.extend(['heat']) %} {% endif %} {% if 'manila' in bootstrap_host_scenarios %} {% set _ = scenario_list.extend(['ceph']) %} {% endif %} {% if ['telemetry', 'aodh', 'ceilometer', 'gnocchi'] | intersect(bootstrap_host_scenarios) | length > 0 %} {% set _ = scenario_list.extend(['aodh', 'ceilometer', 'gnocchi', 'zookeeper']) %} {% endif %} {% if 'translations' in bootstrap_host_scenarios %} {% set _ = scenario_list.extend(['designate', 'heat', 'magnum', 'swift', 'trove']) %} {% endif %} {{ (scenario_list | unique) | sort }} _neutron_plugin_driver: |- {% if 'ovs' in bootstrap_host_scenarios_expanded %} {% set plugin = 'ml2.ovs' %} {% else %} {% set plugin = 'ml2.ovn' %} {% endif %} {{ plugin }} _loopback_device_data: |- {% set data = {'sparse': [], 'fs': [], 'mounts': [], 'services': [], 'lvm': []} %} {% if bootstrap_host_loopback_nova | bool %} {% set _ = data['sparse'].append({'size': bootstrap_host_loopback_nova_size, 'path': '/openstack/nova.img'}) %} {% set _ = data['fs'].append({'fstype': 'xfs', 'opts': bootstrap_host_format_options['xfs'], 'path': '/openstack/nova.img'}) %} {% set _ = data['mounts'].append({ 'what': '/openstack/nova.img', 'where': '/var/lib/nova/instances', 'type': 'xfs', 'options': 'loop,' ~ bootstrap_host_data_mount_options['xfs'], 'enabled': true, 'state': 'started', }) %} {% endif %} {% if bootstrap_host_loopback_cinder | bool %} {% set _ = data['sparse'].append({'size': bootstrap_host_loopback_cinder_size, 'path': '/openstack/cinder.img'}) %} {% set _ = data['services'].append({ 'name': 'loop-cinder', 'execstarts': [ '/bin/bash -c "/sbin/losetup /dev/loop6 /openstack/cinder.img"', '/sbin/pvscan' ], 'execstops': ['/bin/bash -c "losetup -d /dev/loop6"'], }) %} {% set _ = data['lvm'].append({ 'vg': 'cinder-volumes', 'pvs': '/dev/loop6', }) %} {% endif %} {% if bootstrap_host_loopback_manila | bool %} {% set _ = data['sparse'].append({'size': bootstrap_host_loopback_manila_size, 'path': '/openstack/manila.img'}) %} {% set _ = data['services'].append({ 'name': 'loop-manila', 'execstarts': [ '/bin/bash -c "/sbin/losetup /dev/loop7 /openstack/manila.img"', '/sbin/pvscan' ], 'execstops': ['/bin/bash -c "losetup -d /dev/loop7"'], }) %} {% set _ = data['lvm'].append({ 'vg': 'manila-shares', 'pvs': '/dev/loop7', }) %} {% endif %} {% if bootstrap_host_ceph | bool %} {% for image in ceph_osd_images %} {% set device = '/dev/loop' ~ (10 + loop.index) %} {% set _ = data['sparse'].append({'size': bootstrap_host_loopback_ceph_size, 'path': '/openstack/' ~ image ~ '.img'}) %} {% set _ = data['services'].append({ 'name': 'loop-' ~ image, 'execstarts': [ '/bin/bash -c "/sbin/losetup '~ device ~' /openstack/' ~ image ~ '.img"', '/sbin/pvscan' ], 'execstops': ['/bin/bash -c "losetup -d ' ~ device ~ '"'] }) %} {% set _ = data['lvm'].append({ 'lv': 'lv-' ~ image, 'vg': 'vg-' ~ image, 'pvs': device, }) %} {% endfor %} {% endif %} {% if bootstrap_host_loopback_swift | bool %} {% for image in ['swift1', 'swift2', 'swift3'] %} {% set _ = data['sparse'].append({'size': bootstrap_host_loopback_swift_size, 'path': '/openstack/' ~ image ~ '.img'}) %} {% set _ = data['fs'].append({'fstype': 'xfs', 'opts': bootstrap_host_format_options['xfs'], 'path': '/openstack/' ~ image ~ '.img'}) %} {% set _ = data['mounts'].append({ 'what': '/openstack/' ~ image ~ '.img', 'where': '/srv/' ~ image ~ '.img', 'type': 'xfs', 'options': 'loop,' ~ bootstrap_host_data_mount_options['xfs'], 'enabled': true, 'state': 'started', }) %} {% endfor %} {% endif %} {% if bootstrap_host_loopback_btrfs | bool and bootstrap_host_data_disk_device == None and _lxc_container_backing_store == 'btrfs'%} {% set _ = data['sparse'].append({'size': bootstrap_host_loopback_btrfs_size, 'path': '/openstack/lxc-btrfs.img'}) %} {% set _ = data['fs'].append({'fstype': 'btrfs', 'opts': bootstrap_host_format_options['btrfs'], 'path': '/openstack/lxc-btrfs.img'}) %} {% set _ = data['mounts'].append({ 'what': '/openstack/lxc-btrfs.img', 'where': '/var/lib/lxc', 'type': 'btrfs', 'options': 'loop,' ~ bootstrap_host_data_mount_options['btrfs'], 'enabled': true, 'state': 'started', }) %} {% endif %} {% if bootstrap_host_loopback_btrfs | bool and bootstrap_host_data_disk_device == None and _lxc_container_backing_store == 'zfs'%} {% set _ = data['sparse'].append({'size': bootstrap_host_loopback_zfs_size, 'path': '/openstack/lxc-zfs.img'}) %} {% endif %} {% if bootstrap_host_nfs | bool %} {% set _ = data['sparse'].append({'size': bootstrap_host_loopback_nfs_size, 'path': '/openstack/nfs.img'}) %} {% set _ = data['fs'].append({'fstype': 'xfs', 'opts': bootstrap_host_format_options['xfs'], 'path': '/openstack/nfs.img'}) %} {% set _ = data['mounts'].append({ 'what': '/openstack/nfs.img', 'where': '/srv/nfs', 'type': 'xfs', 'options': 'loop,' ~ bootstrap_host_data_mount_options['xfs'], 'enabled': true, 'state': 'started', }) %} {% endif %} {% if bootstrap_host_loopback_swap | bool and ansible_facts['swaptotal_mb'] < 1 %} {% set _ = data['sparse'].append({'size': bootstrap_host_loopback_swap_size, 'path': '/openstack/swap.img'}) %} {% set _ = data['fs'].append({'fstype': 'swap', 'path': '/openstack/swap.img'}) %} {% set _ = data['mounts'].append({ 'what': '/openstack/swap.img', 'priority': 0, 'type': 'swap', 'options': bootstrap_host_data_mount_options['swap'], 'enabled': true, 'state': 'started', }) %} {% endif %} {{ data }} |