
This patch implements the following: - scripts-library.sh which includes commonly used functions, variables and other preparation commands for all other scripts - bootstrap-ansible.sh which only deploys a selected version of ansible and ensures that any other requirements are prepared on the deployment host - bootstrap-aio.sh which runs all host preparation actions for an all-in-one build - gate-check-lint.sh which runs a lint and syntax check - gate-check-commit.sh which runs all actions required for a gate commit check, utilising the other scripts where required - run-smoke-test.sh which runs tempest from inside the utility container - run-playbooks.sh which runs the playbooks - the existing conf.d/swift.yml is renamed to be an example configuration - the example configurations can be used as documentation - etc/network/interfaces.d/aio_interfaces.cfg, etc/rpc_deploy/conf.d/swift.yml and etc/rpc_deploy/rpc_user_config.yml are now configurations used for the AIO deployment - a workaround for https://bugs.launchpad.net/bugs/1244589 to ensure that DHCP checksums are implemented by the host which is required for the smoke tests to work - the removal of the rpc heat templates as they're unusable in their current state - setting MAX_RETRIES to 0, ensuring that any failures cause an immediate commit check failure in the gate - this prevents the masking of failures by retry attempts DocImpact Co-Authored-By: Kevin Carter <kevin.carter@rackspace.com> Closes-Bug: #1415883 Closes-Bug: #1417999 Closes-Bug: #1419807 Change-Id: I95242d48ad0fb055f16510803c8aa14dc183ac17
108 lines
3.0 KiB
YAML
108 lines
3.0 KiB
YAML
---
|
|
# Copyright 2014, 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.
|
|
|
|
- name: Ensure service tenant
|
|
keystone: >
|
|
command=ensure_tenant
|
|
token="{{ auth_admin_token }}"
|
|
endpoint="{{ auth_admin_uri }}"
|
|
tenant_name=service
|
|
description="Service Tenant"
|
|
tags:
|
|
- neutron_config
|
|
|
|
- name: Get nova admin endpoint
|
|
shell: |
|
|
. /root/openrc
|
|
SERVICE_ID="$(keystone service-list | grep -w 'compute' | awk '{print $2}')"
|
|
keystone endpoint-list | grep -w "$SERVICE_ID" | awk '{print $10}'
|
|
register: novaendpoint
|
|
changed_when: false
|
|
failed_when: novaendpoint.rc != 0
|
|
tags:
|
|
- neutron_config
|
|
|
|
- name: Get nova admin user
|
|
shell: |
|
|
. /root/openrc
|
|
keystone service-list | grep -w compute | awk '{print $4}'
|
|
register: novauser
|
|
changed_when: false
|
|
failed_when: novauser.rc != 0
|
|
tags:
|
|
- neutron_config
|
|
|
|
- name: Set variable data
|
|
set_fact:
|
|
nova_admin_username: "{{ novauser.stdout }}"
|
|
nova_admin_tenant_id: "{{ keystone_facts['id'] }}"
|
|
nova_service_adminurl: "{{ novaendpoint.stdout|replace('/$(tenant_id)s', '') }}"
|
|
nova_admin_password: "{{ nova_service_password }}"
|
|
nova_admin_auth_url: "{{ auth_identity_uri }}"
|
|
tags:
|
|
- neutron_config
|
|
|
|
- name: Setup Neutron Config
|
|
template: >
|
|
src={{ item }}
|
|
dest=/etc/neutron/{{ item }}
|
|
owner={{ system_group }}
|
|
group={{ system_user }}
|
|
with_items:
|
|
- neutron.conf
|
|
- metadata_agent.ini
|
|
- l3_agent.ini
|
|
- dhcp_agent.ini
|
|
- api-paste.ini
|
|
- policy.json
|
|
- dnsmasq-neutron.conf
|
|
- rootwrap.conf
|
|
- plugins/ml2/ml2_conf.ini
|
|
- rootwrap.d/debug.filters
|
|
- rootwrap.d/dhcp.filters
|
|
- rootwrap.d/iptables-firewall.filters
|
|
- rootwrap.d/l3.filters
|
|
- rootwrap.d/lbaas-haproxy.filters
|
|
- rootwrap.d/linuxbridge-plugin.filters
|
|
- rootwrap.d/nec-plugin.filters
|
|
- rootwrap.d/openvswitch-plugin.filters
|
|
- rootwrap.d/ryu-plugin.filters
|
|
- rootwrap.d/vpnaas.filters
|
|
- rootwrap.d/ipset-firewall.filters
|
|
notify: Restart os service
|
|
tags:
|
|
- neutron_config
|
|
|
|
- name: Drop iptables checksum fix
|
|
copy:
|
|
src: "post-up-checksum-rules.sh"
|
|
dest: "/etc/network/if-up.d/post-up-checksum-rules.sh"
|
|
owner: "root"
|
|
group: "root"
|
|
mode: "0755"
|
|
when: >
|
|
inventory_hostname in groups['neutron_linuxbridge_agent']
|
|
tags:
|
|
- neutron_config
|
|
- neutron_checksum_fix
|
|
|
|
- name: Run iptables checksum fix
|
|
command: /etc/network/if-up.d/post-up-checksum-rules.sh
|
|
when: >
|
|
inventory_hostname in groups['neutron_linuxbridge_agent']
|
|
tags:
|
|
- neutron_config
|
|
- neutron_checksum_fix
|