From 5ac7114665bf1f511d6702a870db78c35d384269 Mon Sep 17 00:00:00 2001 From: Mark Goddard Date: Tue, 12 Oct 2021 17:07:01 +0100 Subject: [PATCH 01/33] A multiverse from nothing, with Ceph --- etc/kayobe/ansible/ceph-config.yml | 88 +++ etc/kayobe/environments/aufn-ceph/cephadm.yml | 14 + .../aufn-ceph/configure-local-networking.sh | 80 +++ etc/kayobe/environments/aufn-ceph/globals.yml | 58 ++ .../environments/aufn-ceph/init-runonce.sh | 19 + .../group_vars/compute/network-interfaces | 17 + .../group_vars/controllers/network-interfaces | 27 + .../overcloud/ansible-python-interpreter | 3 + .../ansible-python-interpreter | 3 + .../seed-hypervisor/network-interfaces | 16 + .../seed/ansible-python-interpreter | 3 + .../group_vars/seed/network-interfaces | 13 + .../group_vars/storage/network-interfaces | 17 + .../environments/aufn-ceph/inventory/groups | 106 ++++ .../environments/aufn-ceph/inventory/hosts | 27 + etc/kayobe/environments/aufn-ceph/ipa.yml | 138 +++++ etc/kayobe/environments/aufn-ceph/kolla.yml | 482 +++++++++++++++ .../kolla/config/bifrost/bifrost.yml | 12 + .../aufn-ceph/kolla/config/neutron.conf | 2 + .../kolla/config/neutron/ml2_conf.ini | 2 + .../environments/aufn-ceph/kolla/globals.yml | 17 + .../kolla/inventory/overcloud-services.j2 | 561 ++++++++++++++++++ .../aufn-ceph/kolla/kolla-build.conf | 4 + .../aufn-ceph/network-allocation.yml | 12 + .../environments/aufn-ceph/networks.yml | 173 ++++++ .../environments/aufn-ceph/overcloud.yml | 34 ++ .../aufn-ceph/seed-hypervisor.yml | 112 ++++ etc/kayobe/environments/aufn-ceph/seed-vm.yml | 59 ++ .../environments/aufn-ceph/stackhpc.yml | 35 ++ etc/kayobe/environments/aufn-ceph/storage.yml | 126 ++++ etc/kayobe/environments/aufn-ceph/tenks.yml | 89 +++ etc/kayobe/inventory/groups | 2 +- 32 files changed, 2350 insertions(+), 1 deletion(-) create mode 100644 etc/kayobe/ansible/ceph-config.yml create mode 100644 etc/kayobe/environments/aufn-ceph/cephadm.yml create mode 100755 etc/kayobe/environments/aufn-ceph/configure-local-networking.sh create mode 100644 etc/kayobe/environments/aufn-ceph/globals.yml create mode 100755 etc/kayobe/environments/aufn-ceph/init-runonce.sh create mode 100644 etc/kayobe/environments/aufn-ceph/inventory/group_vars/compute/network-interfaces create mode 100644 etc/kayobe/environments/aufn-ceph/inventory/group_vars/controllers/network-interfaces create mode 100644 etc/kayobe/environments/aufn-ceph/inventory/group_vars/overcloud/ansible-python-interpreter create mode 100644 etc/kayobe/environments/aufn-ceph/inventory/group_vars/seed-hypervisor/ansible-python-interpreter create mode 100644 etc/kayobe/environments/aufn-ceph/inventory/group_vars/seed-hypervisor/network-interfaces create mode 100644 etc/kayobe/environments/aufn-ceph/inventory/group_vars/seed/ansible-python-interpreter create mode 100644 etc/kayobe/environments/aufn-ceph/inventory/group_vars/seed/network-interfaces create mode 100644 etc/kayobe/environments/aufn-ceph/inventory/group_vars/storage/network-interfaces create mode 100644 etc/kayobe/environments/aufn-ceph/inventory/groups create mode 100644 etc/kayobe/environments/aufn-ceph/inventory/hosts create mode 100644 etc/kayobe/environments/aufn-ceph/ipa.yml create mode 100644 etc/kayobe/environments/aufn-ceph/kolla.yml create mode 100644 etc/kayobe/environments/aufn-ceph/kolla/config/bifrost/bifrost.yml create mode 100644 etc/kayobe/environments/aufn-ceph/kolla/config/neutron.conf create mode 100644 etc/kayobe/environments/aufn-ceph/kolla/config/neutron/ml2_conf.ini create mode 100644 etc/kayobe/environments/aufn-ceph/kolla/globals.yml create mode 100644 etc/kayobe/environments/aufn-ceph/kolla/inventory/overcloud-services.j2 create mode 100644 etc/kayobe/environments/aufn-ceph/kolla/kolla-build.conf create mode 100644 etc/kayobe/environments/aufn-ceph/network-allocation.yml create mode 100644 etc/kayobe/environments/aufn-ceph/networks.yml create mode 100644 etc/kayobe/environments/aufn-ceph/overcloud.yml create mode 100644 etc/kayobe/environments/aufn-ceph/seed-hypervisor.yml create mode 100644 etc/kayobe/environments/aufn-ceph/seed-vm.yml create mode 100644 etc/kayobe/environments/aufn-ceph/stackhpc.yml create mode 100644 etc/kayobe/environments/aufn-ceph/storage.yml create mode 100644 etc/kayobe/environments/aufn-ceph/tenks.yml diff --git a/etc/kayobe/ansible/ceph-config.yml b/etc/kayobe/ansible/ceph-config.yml new file mode 100644 index 000000000..8c165445d --- /dev/null +++ b/etc/kayobe/ansible/ceph-config.yml @@ -0,0 +1,88 @@ +--- +- name: Configure Ceph + any_errors_fatal: True + gather_facts: True + hosts: storage + vars: + cephadm_ceph_pools: + - backup + - images + - vms + - volumes + cephadm_ceph_users: + - client.glance mon 'profile rbd' osd 'profile rbd pool=images' mgr 'profile rbd pool=images' -o /var/run/ceph/ceph.client.glance.keyring + - client.cinder mon 'profile rbd' osd 'profile rbd pool=volumes, profile rbd pool=vms, profile rbd-read-only pool=images' mgr 'profile rbd pool=volumes, profile rbd pool=vms' -o /var/run/ceph/ceph.client.cinder.keyring + - client.cinder-backup mon 'profile rbd' osd 'profile rbd pool=backups' mgr 'profile rbd pool=backups' -o /var/run/ceph/ceph.client.cinder-backup.keyring + cephadm_kolla_ceph_services: + - { name: "cinder/cinder-volume", keyring: "ceph.client.cinder.keyring" } + - { name: "cinder/cinder-backup", keyring: "ceph.client.cinder.keyring" } + - { name: "cinder/cinder-backup", keyring: "ceph.client.cinder-backup.keyring" } + - { name: "glance", keyring: "ceph.client.glance.keyring" } + - { name: "nova", keyring: "ceph.client.cinder.keyring" } + tasks: + - block: + # Create pools and users. + - name: Create and initialise pools for OpenStack services + command: + cmd: > + cephadm shell -- + ceph osd pool create {{ item }} + with_items: "{{ cephadm_ceph_pools }}" + become: true + + - name: Create users for OpenStack services + command: + cmd: > + cephadm shell -- + ceph auth get-or-create {{ item }} + become: true + with_items: "{{ cephadm_ceph_users }}" + + - name: Check ceph health + command: + cmd: cephadm shell -- ceph health detail + become: True + changed_when: false + + # Create config files. + - name: Ensure required kolla config directories exist + file: + state: directory + name: "{{ kayobe_env_config_path }}/kolla/config/{{ item.name }}" + mode: 0755 + with_items: "{{ cephadm_kolla_ceph_services }}" + delegate_to: localhost + + - name: copy ceph.conf to enabled services + fetch: + src: "/etc/ceph/ceph.conf" + dest: "{{ kayobe_env_config_path }}/kolla/config/{{ item.name }}/ceph.conf" + flat: true + with_items: "{{ cephadm_kolla_ceph_services }}" + + - name: remove tabs in ceph.conf + replace: + path: "{{ kayobe_env_config_path }}/kolla/config/{{ item.name }}/ceph.conf" + regexp: "^\t" + with_items: "{{ cephadm_kolla_ceph_services }}" + delegate_to: localhost + + - name: Get cluster fsid + command: + cmd: "cephadm shell -- ceph fsid" + become: true + register: cephadm_fsid_current + changed_when: false + + - name: copy keyrings to enabled services + fetch: + src: "/var/run/ceph/{{ cephadm_fsid_current.stdout }}/{{ item.keyring }}" + dest: "{{ kayobe_env_config_path }}/kolla/config/{{ item.name }}/{{ item.keyring }}" + owner: "{{ lookup('env', 'USER') }}" + group: "{{ lookup('env', 'USER') }}" + flat: true + with_items: "{{ cephadm_kolla_ceph_services }}" + become: true + + run_once: true + delegate_to: "{{ groups['mons'][0] }}" diff --git a/etc/kayobe/environments/aufn-ceph/cephadm.yml b/etc/kayobe/environments/aufn-ceph/cephadm.yml new file mode 100644 index 000000000..80006c4dc --- /dev/null +++ b/etc/kayobe/environments/aufn-ceph/cephadm.yml @@ -0,0 +1,14 @@ +--- +# Networking +cephadm_public_interface: "{{ storage_net_name | net_interface }}" +cephadm_public_network: "{{ storage_net_name | net_cidr }}" +cephadm_cluster_interface: "{{ storage_mgmt_net_name | net_interface }}" +cephadm_cluster_network: "{{ storage_mgmt_net_name | net_cidr }}" +# OSDs +cephadm_osd_spec: + service_type: osd + service_id: osd_spec_default + placement: + host_pattern: "*" + data_devices: + all: true diff --git a/etc/kayobe/environments/aufn-ceph/configure-local-networking.sh b/etc/kayobe/environments/aufn-ceph/configure-local-networking.sh new file mode 100755 index 000000000..e38ca1d69 --- /dev/null +++ b/etc/kayobe/environments/aufn-ceph/configure-local-networking.sh @@ -0,0 +1,80 @@ +#!/bin/bash + +set -e +set -o pipefail + +# This should be run on the seed hypervisor. + +# IP addresses on the all-in-one Kayobe cloud network. +# These IP addresses map to those statically configured in +# etc/kayobe/network-allocation.yml and etc/kayobe/networks.yml. +controller_vip=192.168.39.2 +seed_hv_ip=192.168.33.4 + +iface=$(ip route | awk '$1 == "default" {print $5; exit}') + +# Private IP address by which the seed hypervisor is accessible in the cloud +# hosting the VM. +seed_hv_private_ip=$(ip a show dev $iface | awk '$1 == "inet" { gsub(/\/[0-9]*/,"",$2); print $2; exit }') + +# Forward the following ports to the controller. +# 80: Horizon +# 6080: VNC console +forwarded_ports="80 6080" + +# IP of the seed hypervisor on the OpenStack 'public' network created by init-runonce.sh. +public_ip="10.0.2.1" + +# Install iptables. +if $(which dnf >/dev/null 2>&1); then + sudo dnf -y install iptables +fi + +# Configure local networking. +# Add bridges for the Kayobe networks. +if ! sudo ip l show brprov >/dev/null 2>&1; then + sudo ip l add brprov type bridge + sudo ip l set brprov up + sudo ip a add $seed_hv_ip/24 dev brprov +fi + +if ! sudo ip l show brcloud >/dev/null 2>&1; then + sudo ip l add brcloud type bridge + sudo ip l set brcloud up +fi + +# Configure an IP on the 'public' network to allow access to/from the cloud. +if ! sudo ip a show dev brcloud | grep $public_ip/24 >/dev/null 2>&1; then + sudo ip a add $public_ip/24 dev brcloud +fi + +# On CentOS 8, bridges without a port are DOWN, which causes network +# configuration to fail. Add a dummy interface and plug it into the bridge. +for i in mgmt prov cloud; do + if ! sudo ip l show dummy-$i >/dev/null 2>&1; then + sudo ip l add dummy-$i type dummy + fi +done + +# Configure IP routing and NAT to allow the seed VM and overcloud hosts to +# route via this route to the outside world. +sudo iptables -A POSTROUTING -t nat -o $iface -j MASQUERADE +sudo sysctl -w net.ipv4.conf.all.forwarding=1 + +# Configure port forwarding from the hypervisor to the Horizon GUI on the +# controller. +sudo iptables -A FORWARD -i $iface -o brprov -m conntrack --ctstate ESTABLISHED,RELATED -j ACCEPT +sudo iptables -A FORWARD -i brprov -o $iface -m conntrack --ctstate ESTABLISHED,RELATED -j ACCEPT +for port in $forwarded_ports; do + # Allow new connections. + sudo iptables -A FORWARD -i $iface -o brcloud -p tcp --syn --dport $port -m conntrack --ctstate NEW -j ACCEPT + # Destination NAT. + sudo iptables -t nat -A PREROUTING -i $iface -p tcp --dport $port -j DNAT --to-destination $controller_vip + # Source NAT. + sudo iptables -t nat -A POSTROUTING -o brcloud -p tcp --dport $port -d $controller_vip -j SNAT --to-source $seed_hv_private_ip +done + +echo +echo "NOTE: The network configuration applied by this script is not" +echo "persistent across reboots." +echo "If you reboot the system, please re-run this script." diff --git a/etc/kayobe/environments/aufn-ceph/globals.yml b/etc/kayobe/environments/aufn-ceph/globals.yml new file mode 100644 index 000000000..9b17a9c05 --- /dev/null +++ b/etc/kayobe/environments/aufn-ceph/globals.yml @@ -0,0 +1,58 @@ +--- +# Kayobe global configuration. + +############################################################################### +# Local path configuration (Ansible control host). + +# Path to Kayobe configuration directory on Ansible control host, with an +# environment path appended if kayobe_environment is set. +#kayobe_config_path: + +# Name of Kayobe environment to use. Default is $KAYOBE_ENVIRONMENT, or an +# empty string if $KAYOBE_ENVIRONMENT is not set. Can also be set via the +# --environment argument when invoking kayobe. +#kayobe_environment: + +# Path to Kayobe configuration directory on Ansible control host with an +# environment path appended if kayobe_environment is set. +#kayobe_env_config_path: + +############################################################################### +# Remote path configuration (seed, seed-hypervisor and overcloud hosts). + +# Base path for kayobe state on remote hosts. +#base_path: + +# Path in which to store configuration on remote hosts. +#config_path: + +# Path in which to cache downloaded images on remote hosts. +#image_cache_path: + +# Path on which to checkout source code repositories on remote hosts. +#source_checkout_path: + +# Path on which to create python virtualenvs on remote hosts. +#virtualenv_path: + +############################################################################### +# User configuration. + +# User with which to access remote hosts. This user will be created if it does +# not exist. +#kayobe_ansible_user: + +############################################################################### +# OS distribution. + +# OS distribution name. Valid options are "centos", "ubuntu". Default is +# "centos". +os_distribution: "{{ lookup('pipe', '. /etc/os-release && echo $ID') | trim }}" + +# OS release. Valid options are "8-stream" when os_distribution is "centos", or +# "focal" when os_distribution is "ubuntu". +#os_release: + +############################################################################### +# Dummy variable to allow Ansible to accept this file. +workaround_ansible_issue_8743: yes diff --git a/etc/kayobe/environments/aufn-ceph/init-runonce.sh b/etc/kayobe/environments/aufn-ceph/init-runonce.sh new file mode 100755 index 000000000..2f66704c1 --- /dev/null +++ b/etc/kayobe/environments/aufn-ceph/init-runonce.sh @@ -0,0 +1,19 @@ +#!/bin/bash + +set -e + +if [[ ! -d ~/os-venv ]]; then + virtualenv ~/os-venv +fi +~/os-venv/bin/pip install -U pip +~/os-venv/bin/pip install python-openstackclient -c https://releases.openstack.org/constraints/upper/master + +parent="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" +init_runonce=$parent/../../../../../kolla-ansible/tools/init-runonce +if [[ ! -f $init_runonce ]]; then + echo "Unable to find kolla-ansible repo" + exit 1 +fi + +source ~/os-venv/bin/activate +$init_runonce diff --git a/etc/kayobe/environments/aufn-ceph/inventory/group_vars/compute/network-interfaces b/etc/kayobe/environments/aufn-ceph/inventory/group_vars/compute/network-interfaces new file mode 100644 index 000000000..a6944527f --- /dev/null +++ b/etc/kayobe/environments/aufn-ceph/inventory/group_vars/compute/network-interfaces @@ -0,0 +1,17 @@ +--- +############################################################################### +# Network interface definitions for the compute group. + +provision_oc_interface: "{{ 'ens2' if os_distribution == 'ubuntu' else 'eth0' }}" +# Route via the seed-hypervisor to the outside world. +provision_oc_gateway: 192.168.33.4 + +internal_interface: "{{ 'ens3' if os_distribution == 'ubuntu' else 'eth1' }}.{{ internal_vlan }}" + +storage_interface: "{{ 'ens3' if os_distribution == 'ubuntu' else 'eth1' }}.{{ storage_vlan }}" + +tunnel_interface: "{{ 'ens3' if os_distribution == 'ubuntu' else 'eth1' }}.{{ tunnel_vlan }}" + +############################################################################### +# Dummy variable to allow Ansible to accept this file. +workaround_ansible_issue_8743: yes diff --git a/etc/kayobe/environments/aufn-ceph/inventory/group_vars/controllers/network-interfaces b/etc/kayobe/environments/aufn-ceph/inventory/group_vars/controllers/network-interfaces new file mode 100644 index 000000000..d608a62e7 --- /dev/null +++ b/etc/kayobe/environments/aufn-ceph/inventory/group_vars/controllers/network-interfaces @@ -0,0 +1,27 @@ +--- +############################################################################### +# Network interface definitions for the controller group. + +provision_oc_interface: "{{ 'ens2' if os_distribution == 'ubuntu' else 'eth0' }}" +# Route via the seed-hypervisor to the outside world. +provision_oc_gateway: 192.168.33.4 + +mgmt_interface: "{{ 'ens3' if os_distribution == 'ubuntu' else 'eth1' }}" + +provision_wl_interface: "br{{ 'ens4' if os_distribution == 'ubuntu' else 'eth2' }}" +provision_wl_bridge_ports: + - "{{ 'ens4' if os_distribution == 'ubuntu' else 'eth2' }}" + +internal_interface: "{{ 'ens4' if os_distribution == 'ubuntu' else 'eth2' }}.{{ internal_vlan }}" + +external_interface: "br{{ 'ens4' if os_distribution == 'ubuntu' else 'eth2' }}.{{ external_vlan }}" + +public_interface: "{{ 'ens4' if os_distribution == 'ubuntu' else 'eth2' }}.{{ public_vlan }}" + +storage_interface: "{{ 'ens4' if os_distribution == 'ubuntu' else 'eth2' }}.{{ storage_vlan }}" + +tunnel_interface: "{{ 'ens4' if os_distribution == 'ubuntu' else 'eth2' }}.{{ tunnel_vlan }}" + +############################################################################### +# Dummy variable to allow Ansible to accept this file. +workaround_ansible_issue_8743: yes diff --git a/etc/kayobe/environments/aufn-ceph/inventory/group_vars/overcloud/ansible-python-interpreter b/etc/kayobe/environments/aufn-ceph/inventory/group_vars/overcloud/ansible-python-interpreter new file mode 100644 index 000000000..54abbf23c --- /dev/null +++ b/etc/kayobe/environments/aufn-ceph/inventory/group_vars/overcloud/ansible-python-interpreter @@ -0,0 +1,3 @@ +--- +# Use a virtual environment for remote operations. +ansible_python_interpreter: "{{ virtualenv_path }}/kayobe/bin/python" diff --git a/etc/kayobe/environments/aufn-ceph/inventory/group_vars/seed-hypervisor/ansible-python-interpreter b/etc/kayobe/environments/aufn-ceph/inventory/group_vars/seed-hypervisor/ansible-python-interpreter new file mode 100644 index 000000000..54abbf23c --- /dev/null +++ b/etc/kayobe/environments/aufn-ceph/inventory/group_vars/seed-hypervisor/ansible-python-interpreter @@ -0,0 +1,3 @@ +--- +# Use a virtual environment for remote operations. +ansible_python_interpreter: "{{ virtualenv_path }}/kayobe/bin/python" diff --git a/etc/kayobe/environments/aufn-ceph/inventory/group_vars/seed-hypervisor/network-interfaces b/etc/kayobe/environments/aufn-ceph/inventory/group_vars/seed-hypervisor/network-interfaces new file mode 100644 index 000000000..01406f3a6 --- /dev/null +++ b/etc/kayobe/environments/aufn-ceph/inventory/group_vars/seed-hypervisor/network-interfaces @@ -0,0 +1,16 @@ +--- +mgmt_interface: brmgmt +mgmt_bridge_ports: + - dummy-mgmt + +provision_oc_interface: brprov +provision_oc_bridge_ports: + - dummy-prov + +provision_wl_interface: brcloud +provision_wl_bridge_ports: + - dummy-cloud + +internal_interface: "{{ provision_wl_interface }}.{{ internal_vlan }}" + +public_interface: "{{ provision_wl_interface }}.{{ public_vlan }}" diff --git a/etc/kayobe/environments/aufn-ceph/inventory/group_vars/seed/ansible-python-interpreter b/etc/kayobe/environments/aufn-ceph/inventory/group_vars/seed/ansible-python-interpreter new file mode 100644 index 000000000..54abbf23c --- /dev/null +++ b/etc/kayobe/environments/aufn-ceph/inventory/group_vars/seed/ansible-python-interpreter @@ -0,0 +1,3 @@ +--- +# Use a virtual environment for remote operations. +ansible_python_interpreter: "{{ virtualenv_path }}/kayobe/bin/python" diff --git a/etc/kayobe/environments/aufn-ceph/inventory/group_vars/seed/network-interfaces b/etc/kayobe/environments/aufn-ceph/inventory/group_vars/seed/network-interfaces new file mode 100644 index 000000000..ca04864d4 --- /dev/null +++ b/etc/kayobe/environments/aufn-ceph/inventory/group_vars/seed/network-interfaces @@ -0,0 +1,13 @@ +--- +############################################################################### +# Network interface definitions for the seed group. + +mgmt_interface: "{{ 'ens2' if os_distribution == 'ubuntu' else 'eth0' }}" + +provision_oc_interface: "{{ 'ens3' if os_distribution == 'ubuntu' else 'eth1' }}" +# Route via the seed-hypervisor to the outside world. +provision_oc_gateway: 192.168.33.4 + +############################################################################### +# Dummy variable to allow Ansible to accept this file. +workaround_ansible_issue_8743: yes diff --git a/etc/kayobe/environments/aufn-ceph/inventory/group_vars/storage/network-interfaces b/etc/kayobe/environments/aufn-ceph/inventory/group_vars/storage/network-interfaces new file mode 100644 index 000000000..c2b0dac84 --- /dev/null +++ b/etc/kayobe/environments/aufn-ceph/inventory/group_vars/storage/network-interfaces @@ -0,0 +1,17 @@ +--- +############################################################################### +# Network interface definitions for the compute group. + +provision_oc_interface: "{{ 'ens2' if os_distribution == 'ubuntu' else 'eth0' }}" +# Route via the seed-hypervisor to the outside world. +provision_oc_gateway: 192.168.33.4 + +internal_interface: "{{ 'ens3' if os_distribution == 'ubuntu' else 'eth1' }}.{{ internal_vlan }}" + +storage_interface: "{{ 'ens3' if os_distribution == 'ubuntu' else 'eth1' }}.{{ storage_vlan }}" + +storage_mgmt_interface: "{{ 'ens3' if os_distribution == 'ubuntu' else 'eth1' }}.{{ storage_mgmt_vlan }}" + +############################################################################### +# Dummy variable to allow Ansible to accept this file. +workaround_ansible_issue_8743: yes diff --git a/etc/kayobe/environments/aufn-ceph/inventory/groups b/etc/kayobe/environments/aufn-ceph/inventory/groups new file mode 100644 index 000000000..0485b6ea9 --- /dev/null +++ b/etc/kayobe/environments/aufn-ceph/inventory/groups @@ -0,0 +1,106 @@ +# Kayobe groups inventory file. This file should generally not be modified. +# If declares the top-level groups and sub-groups. + +############################################################################### +# Seed groups. + +[seed] +# Empty group to provide declaration of seed group. + +[seed-hypervisor] +# Empty group to provide declaration of seed-hypervisor group. + +[container-image-builders:children] +# Build container images on the seed by default. +seed + +############################################################################### +# Overcloud groups. + +[controllers] +# Empty group to provide declaration of controllers group. + +[network:children] +# Add controllers to network group by default for backwards compatibility, +# although they could be separate hosts. +controllers + +[monitoring] +# Empty group to provide declaration of monitoring group. + +[storage] +# Empty group to provide declaration of storage group. + +[compute] +# Empty group to provide declaration of compute group. + +[overcloud:children] +controllers +network +monitoring +storage +compute + +############################################################################### +# Service groups. + +[docker:children] +# Hosts in this group will have Docker installed. +seed +controllers +network +monitoring +compute + +[docker-registry:children] +# Hosts in this group will have a Docker Registry deployed. This group should +# generally contain only a single host, to avoid deploying multiple independent +# registries which may become unsynchronized. +seed + +[ntp:children] +# Kayobe will configure Chrony on members of this group. +seed +seed-hypervisor +overcloud + +############################################################################### +# Baremetal compute node groups. + +[baremetal-compute] +# Empty group to provide declaration of baremetal-compute group. + +############################################################################### +# Networking groups. + +[mgmt-switches] +# Empty group to provide declaration of mgmt-switches group. + +[ctl-switches] +# Empty group to provide declaration of ctl-switches group. + +[hs-switches] +# Empty group to provide declaration of hs-switches group. + +[switches:children] +mgmt-switches +ctl-switches +hs-switches + +############################################################################### +# Ceph groups + +[ceph:children] +storage + +[mons:children] +storage + +[mgrs:children] +storage + +[osds:children] +storage + +[rgws:children] +storage diff --git a/etc/kayobe/environments/aufn-ceph/inventory/hosts b/etc/kayobe/environments/aufn-ceph/inventory/hosts new file mode 100644 index 000000000..c0d1b51fd --- /dev/null +++ b/etc/kayobe/environments/aufn-ceph/inventory/hosts @@ -0,0 +1,27 @@ +# This host acts as the configuration management Ansible control host. This must be +# localhost. +localhost ansible_connection=local + +[seed-hypervisor] +seed-hypervisor + +[seed] +seed + +[controllers] +#controller0 + +[compute:children] +#controllers + +[baremetal-compute] +# Add baremetal compute nodes here if required. + +[mgmt-switches] +# Add management network switches here if required. + +[ctl-switches] +# Add control and provisioning switches here if required. + +[hs-switches] +# Add high speed switches here if required. diff --git a/etc/kayobe/environments/aufn-ceph/ipa.yml b/etc/kayobe/environments/aufn-ceph/ipa.yml new file mode 100644 index 000000000..dd42736e8 --- /dev/null +++ b/etc/kayobe/environments/aufn-ceph/ipa.yml @@ -0,0 +1,138 @@ +--- +# Ironic Python Agent (IPA) configuration. + +############################################################################### +# Ironic Python Agent (IPA) image build configuration. + +# Whether to build IPA images from source. +#ipa_build_images: + +# URL of IPA source repository. +#ipa_build_source_url: + +# Version of IPA source repository. Default is {{ openstack_branch }}. +#ipa_build_source_version: + +# URL of IPA builder source repository. +#ipa_builder_source_url: + +# Version of IPA builder source repository. Default is master. +#ipa_build_source_version: + +# List of default Diskimage Builder (DIB) elements to use when building IPA +# images. Default is ["centos", "enable-serial-console", +# "ironic-python-agent-ramdisk"]. +#ipa_build_dib_elements_default: + +# List of additional Diskimage Builder (DIB) elements to use when building IPA +# images. Default is none. +#ipa_build_dib_elements_extra: + +# List of Diskimage Builder (DIB) elements to use when building IPA images. +# Default is combination of ipa_build_dib_elements_default and +# ipa_build_dib_elements_extra. +#ipa_build_dib_elements: + +# Dictionary of default environment variables to provide to Diskimage Builder +# (DIB) during IPA image build. +#ipa_build_dib_env_default: + +# Dictionary of additional environment variables to provide to Diskimage +# Builder (DIB) during IPA image build. +#ipa_build_dib_env_extra: + +# Dictionary of environment variables to provide to Diskimage Builder (DIB) +# during IPA image build. +#ipa_build_dib_env: + +# List of default git repositories containing Diskimage Builder (DIB) elements. +# See stackhpc.os-images role for usage. Default is one item for IPA builder. +#ipa_build_dib_git_elements_default: + +# List of additional git repositories containing Diskimage Builder (DIB) +# elements. See stackhpc.os-images role for usage. Default is empty. +#ipa_build_dib_git_elements_extra: + +# List of git repositories containing Diskimage Builder (DIB) elements. See +# stackhpc.os-images role for usage. Default is a combination of +# ipa_build_dib_git_elements_default and ipa_build_dib_git_elements_extra. +#ipa_build_dib_git_elements: + +# List of DIB packages to install. Default is none. +#ipa_build_dib_packages: + +# Upper constraints file for installing packages in the virtual environment +# used for building IPA images. Default is {{ pip_upper_constraints_file }}. +#ipa_build_upper_constraints_file: + +############################################################################### +# Ironic Python Agent (IPA) images configuration. + +# Suffix of upstream Ironic deployment image files. Default is based on +# {{ openstack_branch }}. +#ipa_images_upstream_url_suffix: + +# Name of Ironic deployment kernel image to register in Glance. +#ipa_images_kernel_name: + +# URL of Ironic deployment kernel image to download. +# yamllint disable-line rule:line-length +ipa_kernel_upstream_url: "https://tarballs.openstack.org/ironic-python-agent/tinyipa/files/tinyipa{{ ipa_images_upstream_url_suffix }}.vmlinuz" + +# URL of checksum of Ironic deployment kernel image. +#ipa_kernel_checksum_url: + +# Algorithm of checksum of Ironic deployment kernel image. +#ipa_kernel_checksum_algorithm: + +# Name of Ironic deployment ramdisk image to register in Glance. +#ipa_images_ramdisk_name: + +# URL of Ironic deployment ramdisk image to download. +# yamllint disable-line rule:line-length +ipa_ramdisk_upstream_url: "https://tarballs.openstack.org/ironic-python-agent/tinyipa/files/tinyipa{{ ipa_images_upstream_url_suffix }}.gz" + +# URL of checksum of Ironic deployment ramdisk image. +#ipa_ramdisk_checksum_url: + +# Algorithm of checksum of Ironic deployment ramdisk image. +#ipa_ramdisk_checksum_algorithm: + +############################################################################### +# Ironic Python Agent (IPA) deployment configuration. + +# Whether to enable collection of LLDP TLVs. +#ipa_collect_lldp: + +# List of default inspection collectors to run. +# NOTE: extra-hardware is not currently included as it requires a ramdisk +# with the hardware python module installed. +#ipa_collectors_default: + +# List of additional inspection collectors to run. +#ipa_collectors_extra: + +# List of inspection collectors to run. +#ipa_collectors: + +# List of default inspection benchmarks to run. +#ipa_benchmarks_default: + +# List of extra inspection benchmarks to run. +#ipa_benchmarks_extra: + +# List of inspection benchmarks to run. +#ipa_benchmarks: + +# List of default kernel parameters for Ironic python agent. +#ipa_kernel_options_default: + +# List of additional kernel parameters for Ironic python agent. +#ipa_kernel_options_extra: + +# List of kernel parameters for Ironic python agent. +#ipa_kernel_options: + +############################################################################### +# Dummy variable to allow Ansible to accept this file. +workaround_ansible_issue_8743: yes diff --git a/etc/kayobe/environments/aufn-ceph/kolla.yml b/etc/kayobe/environments/aufn-ceph/kolla.yml new file mode 100644 index 000000000..6d31f78f1 --- /dev/null +++ b/etc/kayobe/environments/aufn-ceph/kolla.yml @@ -0,0 +1,482 @@ +--- +# Kayobe Kolla configuration. + +############################################################################### +# Kolla installation. + +# Type of Kolla control installation. One of 'binary' or 'source'. +#kolla_ctl_install_type: + +# Path to directory for kolla source code checkout. +#kolla_source_path: + +# URL of Kolla source code repository if type is 'source'. +#kolla_source_url: + +# Version (branch, tag, etc.) of Kolla source code repository if type is +# 'source'. Default is {{ openstack_branch }}. +#kolla_source_version: + +# Path to virtualenv in which to install kolla. +#kolla_venv: + +# Path in which to generate kolla configuration. +#kolla_build_config_path: + +############################################################################### +# Kolla-ansible installation. + +# Type of Kolla-ansible control installation. One of 'binary' or 'source'. +# Default is 'source'. +#kolla_ansible_ctl_install_type: + +# Path to directory for kolla-ansible source code checkout. +# Default is $KOLLA_SOURCE_PATH, or $PWD/src/kolla-ansible if +# $KOLLA_SOURCE_PATH is not set. +#kolla_ansible_source_path: + +# URL of Kolla Ansible source code repository if type is 'source'. Default is +# https://opendev.org/openstack/kolla-ansible. +#kolla_ansible_source_url: + +# Version (branch, tag, etc.) of Kolla Ansible source code repository if type +# is 'source'. Default is {{ openstack_branch }}. +#kolla_ansible_source_version: + +# Path to virtualenv in which to install kolla-ansible. Default is +# $KOLLA_VENV_PATH or $PWD/venvs/kolla-ansible if $KOLLA_VENV_PATH is not set. +#kolla_ansible_venv: + +# Extra requirements to install inside the kolla-ansible virtualenv. +#kolla_ansible_venv_extra_requirements: + +# Path to Kolla-ansible configuration directory. Default is $KOLLA_CONFIG_PATH +# or /etc/kolla if $KOLLA_CONFIG_PATH is not set. +#kolla_config_path: + +# Path to Kolla-ansible node custom configuration directory. Default is +# {{ kolla_config_path }}/config. +#kolla_node_custom_config_path: + +############################################################################### +# Kolla configuration. + +# Kolla base container image distribution. Options are "centos", "debian", +# "ubuntu". Default is {{ os_distribution }}. +#kolla_base_distro: + +# Kolla container image type: binary or source. Default is 'binary'. +#kolla_install_type: + +# URL of docker registry to use for Kolla images. Default is not set, in which +# case Dockerhub will be used. +#kolla_docker_registry: + +# Docker namespace to use for Kolla images. Default is 'kolla'. +#kolla_docker_namespace: + +# Username to use to access a docker registry. Default is not set, in which +# case the registry will be used without authentication. +#kolla_docker_registry_username: "{{ stackhpc_docker_registry_username }}" + +# Password to use to access a docker registry. Default is not set, in which +# case the registry will be used without authentication. +#kolla_docker_registry_password: "{{ stackhpc_docker_registry_password }}" + +# Kolla OpenStack release version. This should be a Docker image tag. +# Default is {{ openstack_release }}. +#kolla_openstack_release: + +# Docker tag applied to built container images. Default is +# {{ kolla_openstack_release }}. +#kolla_tag: + +# Dict mapping names of sources to their definitions for +# kolla_install_type=source. See kolla.common.config for details. +# Example: +# kolla_sources: +# ironic-base: +# type: git +# location: https://github.com/openstack/ironic +# reference: master +#kolla_sources: + +############################################################################### +# Kolla image build configuration. + +# Dict mapping Jinja2 block names in kolla's Docker images to their contents. +#kolla_build_blocks: + +# Dict mapping image customization variable names to their values. +# Each variable takes the form: +# __ +# Hyphens in the image name must be replaced with underscores. The +# customization is most commonly packages. The operation should be one of +# override, append or remove. The value should be a list. +#kolla_build_customizations: + +############################################################################### +# Kolla-ansible inventory configuration. + +# Full custom seed inventory contents. +#kolla_seed_inventory_custom: + +# List of names of default host variables to pass through from kayobe hosts to +# the kolla-ansible seed host, if set. See also +# kolla_seed_inventory_pass_through_host_vars_map. +#kolla_seed_inventory_pass_through_host_vars_default: + +# List of names of additional host variables to pass through from kayobe hosts +# to the kolla-ansible seed host, if set. See also +# kolla_seed_inventory_pass_through_host_vars_map. +#kolla_seed_inventory_pass_through_host_vars_extra: + +# List of names of host variables to pass through from kayobe hosts to +# the kolla-ansible seed host, if set. See also +# kolla_seed_inventory_pass_through_host_vars_map. +#kolla_seed_inventory_pass_through_host_vars: + +# Dict mapping names of default variables in +# kolla_seed_inventory_pass_through_host_vars to the variable to use in +# kolla-ansible. If a variable name is not in this mapping the kayobe name is +# used. +#kolla_seed_inventory_pass_through_host_vars_map_default: + +# Dict mapping names of extra variables in +# kolla_seed_inventory_pass_through_host_vars to the variable to use in +# kolla-ansible. If a variable name is not in this mapping the kayobe name is +# used. +#kolla_seed_inventory_pass_through_host_vars_map_extra: + +# Dict mapping names of variables in +# kolla_seed_inventory_pass_through_host_vars to the variable to use in +# kolla-ansible. If a variable name is not in this mapping the kayobe name is +# used. +#kolla_seed_inventory_pass_through_host_vars_map: + +# Custom overcloud inventory containing a mapping from top level groups to +# hosts. +#kolla_overcloud_inventory_custom_top_level: + +# Custom overcloud inventory containing a mapping from components to top level +# groups. +#kolla_overcloud_inventory_custom_components: + +# Custom overcloud inventory containing a mapping from services to components. +kolla_overcloud_inventory_custom_services: "{{ lookup('template', kayobe_env_config_path ~ '/kolla/inventory/overcloud-services.j2') }}" + +# Full custom overcloud inventory contents. By default this will be the +# concatenation of the top level, component, and service inventories. +#kolla_overcloud_inventory_custom: + +# Don't give storage nodes to kolla-ansible - we're using Ceph-ansible. +kolla_overcloud_inventory_storage_groups: [] + +# Dict mapping from kolla-ansible groups to kayobe groups and variables. Each +# item is a dict with the following items: +# * groups: A list of kayobe ansible groups to map to this kolla-ansible group. +# * vars: A dict mapping variable names to values for hosts in this +# kolla-ansible group. +#kolla_overcloud_inventory_top_level_group_map: + +# List of names of top level kolla-ansible groups. Any of these groups which +# have no hosts mapped to them will be provided with an empty group definition. +#kolla_overcloud_inventory_kolla_top_level_groups: + +# List of names of default host variables to pass through from kayobe hosts to +# kolla-ansible hosts, if set. See also +# kolla_overcloud_inventory_pass_through_host_vars_map. +#kolla_overcloud_inventory_pass_through_host_vars_default: + +# List of names of additional host variables to pass through from kayobe hosts +# to kolla-ansible hosts, if set. See also +# kolla_overcloud_inventory_pass_through_host_vars_map. +#kolla_overcloud_inventory_pass_through_host_vars_extra: + +# List of names of host variables to pass through from kayobe hosts to +# kolla-ansible hosts, if set. See also +# kolla_overcloud_inventory_pass_through_host_vars_map. +#kolla_overcloud_inventory_pass_through_host_vars: + +# Dict mapping names of default variables in +# kolla_overcloud_inventory_pass_through_host_vars to the variable to use in +# kolla-ansible. If a variable name is not in this mapping the kayobe name is +# used. +#kolla_overcloud_inventory_pass_through_host_vars_map_default: + +# Dict mapping names of additional variables in +# kolla_overcloud_inventory_pass_through_host_vars to the variable to use in +# kolla-ansible. If a variable name is not in this mapping the kayobe name is +# used. +#kolla_overcloud_inventory_pass_through_host_vars_map_extra: + +# Dict mapping names of variables in +# kolla_overcloud_inventory_pass_through_host_vars to the variable to use in +# kolla-ansible. If a variable name is not in this mapping the kayobe name is +# used. +#kolla_overcloud_inventory_pass_through_host_vars_map: + +############################################################################### +# Kolla-ansible configuration. + +# Virtualenv directory where Kolla-ansible's ansible modules will execute +# remotely on the target nodes. If None, no virtualenv will be used. +#kolla_ansible_target_venv: + +# Whether TLS is enabled for the external API endpoints. Default is 'no'. +#kolla_enable_tls_external: + +# Whether TLS is enabled for the internal API endpoints. Default is 'no'. +#kolla_enable_tls_internal: + +# Whether debug logging is enabled. Default is 'false'. +#kolla_openstack_logging_debug: + +# Upper constraints file for installation of Kolla. +# Default value is {{ pip_upper_constraints_file }}. +#kolla_upper_constraints_file: + +# User account to use for Kolla SSH access. Default is 'kolla'. +#kolla_ansible_user: + +# Primary group of Kolla SSH user. Default is 'kolla'. +#kolla_ansible_group: + +# Whether to use privilege escalation for all operations performed via Kolla +# Ansible. Default is 'false'. +#kolla_ansible_become: + +# Whether to create a user account, configure passwordless sudo and authorise +# an SSH key for Kolla Ansible. Default is 'true'. +#kolla_ansible_create_user: + +############################################################################### +# Kolla feature flag configuration. + +#kolla_enable_aodh: +#kolla_enable_barbican: +#kolla_enable_blazar: +#kolla_enable_ceilometer: +#kolla_enable_ceilometer_horizon_policy_file: +#kolla_enable_ceilometer_ipmi: +#kolla_enable_cells: +#kolla_enable_central_logging: +#kolla_enable_chrony: +kolla_enable_cinder: true +#kolla_enable_cinder_backend_hnas_nfs: +#kolla_enable_cinder_backend_iscsi: +#kolla_enable_cinder_backend_lvm: +#kolla_enable_cinder_backend_nfs: +#kolla_enable_cinder_backend_quobyte: +#kolla_enable_cinder_backend_zfssa_iscsi: +#kolla_enable_cinder_backup: +#kolla_enable_cinder_horizon_policy_file: +#kolla_enable_cloudkitty: +#kolla_enable_collectd: +#kolla_enable_container_healthchecks: +#kolla_enable_cyborg: +#kolla_enable_designate: +#kolla_enable_destroy_images: +#kolla_enable_elasticsearch: +#kolla_enable_elasticsearch_curator: +#kolla_enable_etcd: +#kolla_enable_external_mariadb_load_balancer: +#kolla_enable_fluentd: +#kolla_enable_freezer: +#kolla_enable_glance: +#kolla_enable_glance_horizon_policy_file: +#kolla_enable_glance_image_cache: +#kolla_enable_gnocchi: +#kolla_enable_gnocchi_statsd: +#kolla_enable_grafana: +#kolla_enable_hacluster: +#kolla_enable_haproxy: +#kolla_enable_haproxy_memcached: +#kolla_enable_heat: +#kolla_enable_heat_horizon_policy_file: +#kolla_enable_horizon: +#kolla_enable_horizon_blazar: +#kolla_enable_horizon_cloudkitty: +#kolla_enable_horizon_designate: +#kolla_enable_horizon_freezer: +#kolla_enable_horizon_heat: +#kolla_enable_horizon_ironic: +#kolla_enable_horizon_magnum: +#kolla_enable_horizon_manila: +#kolla_enable_horizon_masakari: +#kolla_enable_horizon_mistral: +#kolla_enable_horizon_monasca: +#kolla_enable_horizon_murano: +#kolla_enable_horizon_neutron_vpnaas: +#kolla_enable_horizon_octavia: +#kolla_enable_horizon_sahara: +#kolla_enable_horizon_senlin: +#kolla_enable_horizon_solum: +#kolla_enable_horizon_tacker: +#kolla_enable_horizon_trove: +#kolla_enable_horizon_vitrage: +#kolla_enable_horizon_watcher: +#kolla_enable_horizon_zun: +#kolla_enable_influxdb: +#kolla_enable_ironic: +#kolla_enable_ironic_ipxe: +#kolla_enable_ironic_neutron_agent: +#kolla_enable_ironic_pxe_uefi: +#kolla_enable_iscsid: +#kolla_enable_kafka: +#kolla_enable_keepalived: +#kolla_enable_keystone: +#kolla_enable_keystone_federation: +#kolla_enable_keystone_horizon_policy_file: +#kolla_enable_kibana: +#kolla_enable_kuryr: +#kolla_enable_magnum: +#kolla_enable_manila: +#kolla_enable_manila_backend_cephfs_native: +#kolla_enable_manila_backend_cephfs_nfs: +#kolla_enable_manila_backend_generic: +#kolla_enable_manila_backend_glusterfs_nfs: +#kolla_enable_manila_backend_hnas: +#kolla_enable_mariabackup: +#kolla_enable_mariadb: +#kolla_enable_masakari: +#kolla_enable_memcached: +#kolla_enable_mistral: +#kolla_enable_monasca: +#kolla_enable_multipathd: +#kolla_enable_murano: +#kolla_enable_neutron: +#kolla_enable_neutron_agent_ha: +#kolla_enable_neutron_bgp_dragent: +#kolla_enable_neutron_dvr: +#kolla_enable_neutron_horizon_policy_file: +#kolla_enable_neutron_infoblox_ipam_agent: +#kolla_enable_neutron_metering: +#kolla_enable_neutron_mlnx: +#kolla_enable_neutron_port_forwarding: +#kolla_enable_neutron_provider_networks: +#kolla_enable_neutron_qos: +#kolla_enable_neutron_segments: +#kolla_enable_neutron_sfc: +#kolla_enable_neutron_sriov: +#kolla_enable_neutron_trunk: +#kolla_enable_neutron_vpnaas: +#kolla_enable_nova: +#kolla_enable_nova_fake: +#kolla_enable_nova_horizon_policy_file: +#kolla_enable_nova_serialconsole_proxy: +#kolla_enable_nova_ssh: +#kolla_enable_octavia: +#kolla_enable_octavia_driver_agent: +#kolla_enable_openstack_core: +#kolla_enable_openvswitch: +#kolla_enable_osprofiler: +#kolla_enable_outward_rabbitmq: +kolla_enable_ovn: true +#kolla_enable_ovs_dpdk: +#kolla_enable_panko: +#kolla_enable_placement: +#kolla_enable_prometheus: +#kolla_enable_prometheus_alertmanager: +#kolla_enable_prometheus_blackbox_exporter: +#kolla_enable_prometheus_cadvisor: +#kolla_enable_prometheus_ceph_mgr_exporter: +#kolla_enable_prometheus_elasticsearch_exporter: +#kolla_enable_prometheus_haproxy_exporter: +#kolla_enable_prometheus_memcached_exporter: +#kolla_enable_prometheus_mysqld_exporter: +#kolla_enable_prometheus_node_exporter: +#kolla_enable_prometheus_openstack_exporter: +#kolla_enable_prometheus_rabbitmq_exporter: +#kolla_enable_prometheus_server: +#kolla_enable_qdrouterd: +#kolla_enable_rabbitmq: +#kolla_enable_rally: +#kolla_enable_redis: +#kolla_enable_sahara: +#kolla_enable_senlin: +#kolla_enable_skydive: +#kolla_enable_solum: +#kolla_enable_storm: +#kolla_enable_swift: +#kolla_enable_swift_recon: +#kolla_enable_swift_s3api: +#kolla_enable_tacker: +#kolla_enable_telegraf: +#kolla_enable_tempest: +#kolla_enable_trove: +#kolla_enable_trove_singletenant: +#kolla_enable_vitrage: +#kolla_enable_vitrage_prometheus_datasource: +#kolla_enable_vmtp: +#kolla_enable_watcher: +#kolla_enable_zookeeper: +#kolla_enable_zun: + +############################################################################### +# Passwords and credentials. + +# Dictionary containing default custom passwords to add or override in the +# Kolla passwords file. +#kolla_ansible_default_custom_passwords: + +# Dictionary containing custom passwords to add or override in the Kolla +# passwords file. +#kolla_ansible_custom_passwords: + +############################################################################### +# OpenStack API addresses. + +# Virtual IP address of OpenStack internal API. Default is the vip_address +# attribute of the internal network. +#kolla_internal_vip_address: + +# Fully Qualified Domain Name (FQDN) of OpenStack internal API. Default is the +# fqdn attribute of the internal network if set, otherwise +# kolla_internal_vip_address. +#kolla_internal_fqdn: + +# Virtual IP address of OpenStack external API. Default is the vip_address +# attribute of the external network. +#kolla_external_vip_address: + +# Fully Qualified Domain Name (FQDN) of OpenStack external API. Default is the +# fqdn attribute of the external network if set, otherwise +# kolla_external_vip_address. +#kolla_external_fqdn: + +############################################################################### +# TLS certificate bundle management + +# External API certificate bundle. +# +# When kolla_enable_tls_external is true, this should contain an X.509 +# certificate bundle for the external API. +# +# Note that this should be formatted as a literal style block scalar. +# +# NOTE: kolla_tls_cert has been renamed to kolla_external_tls_cert. Support for +# the deprecated name kolla_tls_cert will be removed in a future release. +#kolla_external_tls_cert: + +# Path to a CA certificate file to use for the OS_CACERT environment variable +# in public-openrc.sh file when TLS is enabled, instead of Kolla-Ansible's +# default. +#kolla_external_fqdn_cacert: + +# Internal API certificate bundle. +# +# When kolla_enable_tls_internal is true, this should contain an X.509 +# certificate bundle for the internal API. +# +# Note that this should be formatted as a literal style block scalar. +#kolla_internal_tls_cert: + +# Path to a CA certificate file to use for the OS_CACERT environment variable +# in admin-openrc.sh file when TLS is enabled, instead of Kolla-Ansible's +# default. +#kolla_internal_fqdn_cacert: + +############################################################################### +# Dummy variable to allow Ansible to accept this file. +workaround_ansible_issue_8743: yes diff --git a/etc/kayobe/environments/aufn-ceph/kolla/config/bifrost/bifrost.yml b/etc/kayobe/environments/aufn-ceph/kolla/config/bifrost/bifrost.yml new file mode 100644 index 000000000..78ea4bf9b --- /dev/null +++ b/etc/kayobe/environments/aufn-ceph/kolla/config/bifrost/bifrost.yml @@ -0,0 +1,12 @@ +--- +# Don't build an IPA deployment image, instead download upstream images. +create_ipa_image: false +download_ipa: true + +# Use a locally hosted CentOS8 cloud image. +use_cirros: true +{% if os_distribution == 'ubuntu' %} +cirros_deploy_image_upstream_url: "https://cloud-images.ubuntu.com/focal/current/focal-server-cloudimg-amd64.img" +{% else %} +cirros_deploy_image_upstream_url: "https://cloud.centos.org/centos/8-stream/x86_64/images/CentOS-Stream-GenericCloud-8-20210210.0.x86_64.qcow2" +{% endif %} diff --git a/etc/kayobe/environments/aufn-ceph/kolla/config/neutron.conf b/etc/kayobe/environments/aufn-ceph/kolla/config/neutron.conf new file mode 100644 index 000000000..1014e6730 --- /dev/null +++ b/etc/kayobe/environments/aufn-ceph/kolla/config/neutron.conf @@ -0,0 +1,2 @@ +[DEFAULT] +global_physnet_mtu = {{ tunnel_net_name | net_mtu }} diff --git a/etc/kayobe/environments/aufn-ceph/kolla/config/neutron/ml2_conf.ini b/etc/kayobe/environments/aufn-ceph/kolla/config/neutron/ml2_conf.ini new file mode 100644 index 000000000..7695e792b --- /dev/null +++ b/etc/kayobe/environments/aufn-ceph/kolla/config/neutron/ml2_conf.ini @@ -0,0 +1,2 @@ +[ml2] +path_mtu = {{ tunnel_net_name | net_mtu }} diff --git a/etc/kayobe/environments/aufn-ceph/kolla/globals.yml b/etc/kayobe/environments/aufn-ceph/kolla/globals.yml new file mode 100644 index 000000000..79b09e0b1 --- /dev/null +++ b/etc/kayobe/environments/aufn-ceph/kolla/globals.yml @@ -0,0 +1,17 @@ +--- +# Most development environments will use nested virtualisation, and we can't +# guarantee that nested KVM support is available. Use QEMU as a lowest common +# denominator. +nova_compute_virt_type: qemu + +# Reduce the control plane's memory footprint by limiting the number of worker +# processes to one per-service. +openstack_service_workers: "1" + +# Prevent Docker from manipulating iptables. Docker changes the default policy +# on the FORWARD chain, which prevents traffic from reaching instances. +docker_disable_default_iptables_rules: true + +glance_backend_ceph: "yes" +cinder_backend_ceph: "yes" +nova_backend_ceph: "yes" diff --git a/etc/kayobe/environments/aufn-ceph/kolla/inventory/overcloud-services.j2 b/etc/kayobe/environments/aufn-ceph/kolla/inventory/overcloud-services.j2 new file mode 100644 index 000000000..4572d6af9 --- /dev/null +++ b/etc/kayobe/environments/aufn-ceph/kolla/inventory/overcloud-services.j2 @@ -0,0 +1,561 @@ +# This inventory section provides a mapping of services to components. +# +# Top level groups define the roles of hosts, e.g. controller or compute. +# Components define groups of services, e.g. nova or ironic. +# Services define single containers, e.g. nova-compute or ironic-api. + +# Additional control implemented here. These groups allow you to control which +# services run on which hosts at a per-service level. +# +# Word of caution: Some services are required to run on the same host to +# function appropriately. For example, neutron-metadata-agent must run on the +# same host as the l3-agent and (depending on configuration) the dhcp-agent. + +# Common +[cron:children] +common + +[fluentd:children] +common + +[kolla-logs:children] +common + +[kolla-toolbox:children] +common + +# Elasticsearch Curator +[elasticsearch-curator:children] +elasticsearch + +# Glance +[glance-api:children] +glance + +# Nova +[nova-api:children] +nova + +[nova-conductor:children] +{% if 'cell-control' in kolla_overcloud_inventory_top_level_group_map %} +cell-control +{% else %} +nova +{% endif %} + +[nova-super-conductor:children] +nova + +[nova-novncproxy:children] +{% if 'cell-control' in kolla_overcloud_inventory_top_level_group_map %} +cell-control +{% else %} +nova +{% endif %} + +[nova-scheduler:children] +nova + +[nova-spicehtml5proxy:children] +{% if 'cell-control' in kolla_overcloud_inventory_top_level_group_map %} +cell-control +{% else %} +nova +{% endif %} + +# NOTE: HA for nova-compute services with ironic is still an experimental +# feature. Provide the option to use a single compute host, even when multiple +# controllers are in use. +{% if kolla_nova_compute_ironic_host is not none %} +[nova-compute-ironic] +{{ kolla_nova_compute_ironic_host }} +{% else %} +[nova-compute-ironic:children] +nova +{% endif %} + +[nova-serialproxy:children] +{% if 'cell-control' in kolla_overcloud_inventory_top_level_group_map %} +cell-control +{% else %} +nova +{% endif %} + +# Neutron +[neutron-server:children] +control + +[neutron-dhcp-agent:children] +neutron + +[neutron-l3-agent:children] +neutron + +[neutron-metadata-agent:children] +neutron + +[neutron-ovn-metadata-agent:children] +compute + +[neutron-bgp-dragent:children] +neutron + +[neutron-infoblox-ipam-agent:children] +neutron + +[neutron-metering-agent:children] +neutron + +[ironic-neutron-agent:children] +neutron + +# Cinder +[cinder-api:children] +cinder + +[cinder-backup:children] +storage + +[cinder-scheduler:children] +cinder + +[cinder-volume:children] +cinder + +# Cloudkitty +[cloudkitty-api:children] +cloudkitty + +[cloudkitty-processor:children] +cloudkitty + +# Freezer +[freezer-api:children] +freezer + +[freezer-scheduler:children] +freezer + +# iSCSI +[iscsid:children] +compute +storage +ironic + +[tgtd:children] +storage + +# Manila +[manila-api:children] +manila + +[manila-scheduler:children] +manila + +[manila-share:children] +network + +[manila-data:children] +manila + +# Swift +[swift-proxy-server:children] +swift + +[swift-account-server:children] +storage + +[swift-container-server:children] +storage + +[swift-object-server:children] +storage + +# Barbican +[barbican-api:children] +barbican + +[barbican-keystone-listener:children] +barbican + +[barbican-worker:children] +barbican + +# Heat +[heat-api:children] +heat + +[heat-api-cfn:children] +heat + +[heat-engine:children] +heat + +# Murano +[murano-api:children] +murano + +[murano-engine:children] +murano + +# Monasca +[monasca-agent-collector:children] +monasca-agent + +[monasca-agent-forwarder:children] +monasca-agent + +[monasca-agent-statsd:children] +monasca-agent + +[monasca-api:children] +monasca + +[monasca-grafana:children] +monasca + +[monasca-log-transformer:children] +monasca + +[monasca-log-persister:children] +monasca + +[monasca-log-metrics:children] +monasca + +[monasca-thresh:children] +monasca + +[monasca-notification:children] +monasca + +[monasca-persister:children] +monasca + +# Storm +[storm-worker:children] +storm + +[storm-nimbus:children] +storm + +# Ironic +[ironic-api:children] +ironic + +[ironic-conductor:children] +ironic + +#[ironic-inspector:children] +#ironic + +[ironic-inspector] +# FIXME: Ideally we wouldn't reference controllers in here directly, but only +# one inspector service should exist, and groups can't be indexed in an +# inventory (e.g. ironic[0]). +{% if groups.get('controllers', []) | length > 0 %} +{{ groups['controllers'][0] }} +{% endif %} + +[ironic-pxe:children] +ironic + +[ironic-ipxe:children] +ironic + +# Magnum +[magnum-api:children] +magnum + +[magnum-conductor:children] +magnum + +# Sahara +[sahara-api:children] +sahara + +[sahara-engine:children] +sahara + +# Solum +[solum-api:children] +solum + +[solum-worker:children] +solum + +[solum-deployer:children] +solum + +[solum-conductor:children] +solum + +[solum-application-deployment:children] +solum + +[solum-image-builder:children] +solum + +# Mistral +[mistral-api:children] +mistral + +[mistral-executor:children] +mistral + +[mistral-engine:children] +mistral + +[mistral-event-engine:children] +mistral + +# Ceilometer +[ceilometer-central:children] +ceilometer + +[ceilometer-notification:children] +ceilometer + +[ceilometer-compute:children] +compute + +[ceilometer-ipmi:children] +compute + +# Aodh +[aodh-api:children] +aodh + +[aodh-evaluator:children] +aodh + +[aodh-listener:children] +aodh + +[aodh-notifier:children] +aodh + +# Cyborg +[cyborg-api:children] +cyborg + +[cyborg-agent:children] +compute + +[cyborg-conductor:children] +cyborg + +# Panko +[panko-api:children] +panko + +# Gnocchi +[gnocchi-api:children] +gnocchi + +[gnocchi-statsd:children] +gnocchi + +[gnocchi-metricd:children] +gnocchi + +# Trove +[trove-api:children] +trove + +[trove-conductor:children] +trove + +[trove-taskmanager:children] +trove + +# Multipathd +[multipathd:children] +compute +storage + +# Watcher +[watcher-api:children] +watcher + +[watcher-engine:children] +watcher + +[watcher-applier:children] +watcher + +# Senlin +[senlin-api:children] +senlin + +[senlin-conductor:children] +senlin + +[senlin-engine:children] +senlin + +[senlin-health-manager:children] +senlin + +# Octavia +[octavia-api:children] +octavia + +[octavia-driver-agent:children] +octavia + +[octavia-health-manager:children] +octavia + +[octavia-housekeeping:children] +octavia + +[octavia-worker:children] +octavia + +# Designate +[designate-api:children] +designate + +[designate-central:children] +designate + +[designate-producer:children] +designate + +[designate-mdns:children] +network + +[designate-worker:children] +designate + +[designate-sink:children] +designate + +[designate-backend-bind9:children] +designate + +# Placement +[placement-api:children] +placement + +# Zun +[zun-api:children] +zun + +[zun-wsproxy:children] +zun + +[zun-compute:children] +compute + +[zun-cni-daemon:children] +compute + +# Skydive +[skydive-analyzer:children] +skydive + +[skydive-agent:children] +compute +network + +# Tacker +[tacker-server:children] +tacker + +[tacker-conductor:children] +tacker + +# Vitrage +[vitrage-api:children] +vitrage + +[vitrage-notifier:children] +vitrage + +[vitrage-graph:children] +vitrage + +[vitrage-ml:children] +vitrage + +[vitrage-persistor:children] +vitrage + +# Blazar +[blazar-api:children] +blazar + +[blazar-manager:children] +blazar + +# Prometheus +[prometheus-node-exporter:children] +monitoring +control +compute +network +storage + +[prometheus-mysqld-exporter:children] +mariadb + +[prometheus-haproxy-exporter:children] +haproxy + +[prometheus-memcached-exporter:children] +memcached + +[prometheus-cadvisor:children] +monitoring +control +compute +network +storage + +[prometheus-alertmanager:children] +monitoring + +[prometheus-openstack-exporter:children] +monitoring + +[prometheus-elasticsearch-exporter:children] +elasticsearch + +[prometheus-blackbox-exporter:children] +monitoring + +[masakari-api:children] +control + +[masakari-engine:children] +control + +[masakari-hostmonitor:children] +control + +[masakari-instancemonitor:children] +compute + +[ovn-controller:children] +ovn-controller-compute +ovn-controller-network + +[ovn-controller-compute:children] +compute + +[ovn-controller-network:children] +network + +[ovn-database:children] +control + +[ovn-northd:children] +ovn-database + +[ovn-nb-db:children] +ovn-database + +[ovn-sb-db:children] +ovn-database diff --git a/etc/kayobe/environments/aufn-ceph/kolla/kolla-build.conf b/etc/kayobe/environments/aufn-ceph/kolla/kolla-build.conf new file mode 100644 index 000000000..0a665e1bd --- /dev/null +++ b/etc/kayobe/environments/aufn-ceph/kolla/kolla-build.conf @@ -0,0 +1,4 @@ +[DEFAULT] +# This is necessary for network connectivity of kolla-build, when Docker +# default iptables rules are disabled. +network_mode = host diff --git a/etc/kayobe/environments/aufn-ceph/network-allocation.yml b/etc/kayobe/environments/aufn-ceph/network-allocation.yml new file mode 100644 index 000000000..8d6c826fa --- /dev/null +++ b/etc/kayobe/environments/aufn-ceph/network-allocation.yml @@ -0,0 +1,12 @@ +provision_oc_ips: + compute0: 192.168.33.6 + compute1: 192.168.33.7 + compute2: 192.168.33.8 + controller0: 192.168.33.3 + controller1: 192.168.33.9 + controller2: 192.168.33.10 + seed: 192.168.33.5 + seed-hypervisor: 192.168.33.4 + storage0: 192.168.33.11 + storage1: 192.168.33.12 + storage2: 192.168.33.13 diff --git a/etc/kayobe/environments/aufn-ceph/networks.yml b/etc/kayobe/environments/aufn-ceph/networks.yml new file mode 100644 index 000000000..44fb4e192 --- /dev/null +++ b/etc/kayobe/environments/aufn-ceph/networks.yml @@ -0,0 +1,173 @@ +--- +# Kayobe network configuration. + +############################################################################### +# Network role to network mappings. + +# Map all networks to the all-in-one network. + +# Name of the network used for admin access to the overcloud +#admin_oc_net_name: + +# Name of the network used by the seed to manage the bare metal overcloud +# hosts via their out-of-band management controllers. +#oob_oc_net_name: +oob_oc_net_name: mgmt + +# Name of the network used by the seed to provision the bare metal overcloud +# hosts. +#provision_oc_net_name: +provision_oc_net_name: provision_oc + +# Name of the network used by the overcloud hosts to manage the bare metal +# compute hosts via their out-of-band management controllers. +#oob_wl_net_name: +oob_wl_net_name: mgmt + +# Name of the network used by the overcloud hosts to provision the bare metal +# workload hosts. +#provision_wl_net_name: +provision_wl_net_name: provision_wl + +# Name of the network used to expose the internal OpenStack API endpoints. +#internal_net_name: +internal_net_name: internal + +# List of names of networks used to provide external network access via +# Neutron. +# Deprecated name: external_net_name +# If external_net_name is defined, external_net_names will default to a list +# containing one item, external_net_name. +#external_net_names: +external_net_names: + - external + +# Name of the network used to expose the public OpenStack API endpoints. +#public_net_name: +public_net_name: public + +# Name of the network used by Neutron to carry tenant overlay network traffic. +#tunnel_net_name: +tunnel_net_name: tunnel + +# Name of the network used to carry storage data traffic. +#storage_net_name: +storage_net_name: storage + +# Name of the network used to carry storage management traffic. +#storage_mgmt_net_name: +storage_mgmt_net_name: storage_mgmt + +# Name of the network used to carry swift storage data traffic. +#swift_storage_net_name: + +# Name of the network used to carry swift storage replication traffic. +#swift_storage_replication_net_name: + +# Name of the network used to perform hardware introspection on the bare metal +# workload hosts. +#inspection_net_name: +inspection_net_name: provision_wl + +# Name of the network used to perform cleaning on the bare metal workload +# hosts +#cleaning_net_name: +cleaning_net_name: provision_wl + +############################################################################### +# Network definitions. + +mgmt_cidr: 192.168.35.0/24 +mgmt_mtu: 1450 +# Native VLAN +mgmt_physical_network: mgmt + +#admin_cidr: 192.168.34.0/24 +#admin_mtu: 1450 +#admin_vlan: 100 +#admin_physical_network: provision + +provision_oc_cidr: 192.168.33.0/24 +provision_oc_mtu: 1450 +provision_oc_inspection_allocation_pool_start: 192.168.33.128 +provision_oc_inspection_allocation_pool_end: 192.168.33.254 +# Native VLAN +provision_oc_physical_network: provision + +provision_wl_cidr: 192.168.36.0/24 +provision_wl_mtu: 1450 +provision_wl_inspection_allocation_pool_start: 192.168.36.128 +provision_wl_inspection_allocation_pool_end: 192.168.36.254 +provision_wl_neutron_allocation_pool_start: 192.168.36.2 +provision_wl_neutron_allocation_pool_end: 192.168.36.127 +# Native VLAN +provision_wl_physical_network: cloud + +internal_cidr: 192.168.37.0/24 +internal_mtu: 1450 +internal_allocation_pool_start: 192.168.37.3 +internal_allocation_pool_end: 192.168.37.254 +internal_vip_address: 192.168.37.2 +internal_vlan: 101 +internal_physical_network: cloud + +external_cidr: 192.168.38.0/24 +external_mtu: 1450 +external_vlan: 102 +external_physical_network: cloud + +public_cidr: 192.168.39.0/24 +public_mtu: 1450 +public_allocation_pool_start: 192.168.39.3 +public_allocation_pool_end: 192.168.39.254 +public_vip_address: 192.168.39.2 +public_vlan: 103 +public_physical_network: cloud + +tunnel_cidr: 192.168.40.0/24 +tunnel_mtu: 1450 +tunnel_vlan: 104 +tunnel_physical_network: cloud + +storage_cidr: 192.168.41.0/24 +storage_mtu: 1450 +storage_vlan: 105 +storage_physical_network: cloud + +storage_mgmt_cidr: 192.168.42.0/24 +storage_mgmt_mtu: 1450 +storage_mgmt_vlan: 106 +storage_mgmt_physical_network: cloud + +############################################################################### +# Network virtual patch link configuration. + +# Suffix for Open vSwitch bridge names. +#network_bridge_suffix_ovs: + +# Prefix for virtual patch interface names. +#network_patch_prefix: + +# Suffix for virtual patch link interface names when connected towards the +# physical interface. +#network_patch_suffix_phy: + +# Suffix for virtual patch link interface names when connected towards the +# OVS bridge. +#network_patch_suffix_ovs: + +############################################################################### +# Network routing table configuration. + +# List of IP routing tables. Each item should be a dict containing 'id' and +# 'name' items. These tables will be added to /etc/iproute2/rt_tables. +#network_route_tables: + +############################################################################### +# MichaelRigart interfaces configuration. + +interfaces_pause_time: 5 + +############################################################################### +# Dummy variable to allow Ansible to accept this file. +workaround_ansible_issue_8743: yes diff --git a/etc/kayobe/environments/aufn-ceph/overcloud.yml b/etc/kayobe/environments/aufn-ceph/overcloud.yml new file mode 100644 index 000000000..1414c3a4e --- /dev/null +++ b/etc/kayobe/environments/aufn-ceph/overcloud.yml @@ -0,0 +1,34 @@ +--- +############################################################################### +# Overcloud configuration. + +# Default Ansible group for overcloud hosts. +#overcloud_group_default: + +# List of names of Ansible groups for overcloud hosts. +#overcloud_groups: + +# Dict mapping overcloud Ansible group names to lists of hosts in the group. +# As a special case, the group 'ignore' can be used to specify hosts that +# should not be added to the inventory. +#overcloud_group_hosts_map: +overcloud_group_hosts_map: + controllers: + - controller0 + - controller1 + - controller2 + compute: + - compute0 + - compute1 + - compute2 + storage: + - storage0 + - storage1 + - storage2 + +# To prevent some network issues you can choose to disable cloud-init +#disable_cloud_init: + +############################################################################### +# Dummy variable to allow Ansible to accept this file. +workaround_ansible_issue_8743: yes diff --git a/etc/kayobe/environments/aufn-ceph/seed-hypervisor.yml b/etc/kayobe/environments/aufn-ceph/seed-hypervisor.yml new file mode 100644 index 000000000..3392f0a24 --- /dev/null +++ b/etc/kayobe/environments/aufn-ceph/seed-hypervisor.yml @@ -0,0 +1,112 @@ +--- +############################################################################### +# Seed hypervisor node configuration. + +# User with which to access the seed hypervisor via SSH during bootstrap, in +# order to setup the Kayobe user account. Default is {{ os_distribution }}. +#seed_hypervisor_bootstrap_user: + +############################################################################### +# Seed hypervisor network interface configuration. + +# List of networks to which seed hypervisor nodes are attached. +#seed_hypervisor_network_interfaces: + +# List of default networks to which seed hypervisor nodes are attached. +#seed_hypervisor_default_network_interfaces: + +# List of extra networks to which seed hypervisor nodes are attached. +seed_hypervisor_extra_network_interfaces: + - "{{ provision_wl_net_name }}" + - "{{ internal_net_name }}" + - "{{ public_net_name }}" + +############################################################################### +# Seed hypervisor node software RAID configuration. + +# List of software RAID arrays. See mrlesmithjr.mdadm role for format. +#seed_hypervisor_mdadm_arrays: + +############################################################################### +# Seed hypervisor node encryption configuration. + +# List of block devices to encrypt. See stackhpc.luks role for format. +#seed_hypervisor_luks_devices: + +############################################################################### +# Seed hypervisor node LVM configuration. + +# List of seed hypervisor volume groups. See mrlesmithjr.manage-lvm role for +# format. Set to "{{ seed_hypervisor_lvm_groups_with_data }}" to create a +# volume group for libvirt storage. +#seed_hypervisor_lvm_groups: + +# Suggested list of seed hypervisor volume groups for libvirt. Not used by +# default. +#seed_hypervisor_lvm_groups_with_data: + +# Seed LVM volume group for data. See mrlesmithjr.manage-lvm role for format. +#seed_hypervisor_lvm_group_data: + +# List of disks for use by seed hypervisor LVM data volume group. Default to an +# invalid value to require configuration. +#seed_hypervisor_lvm_group_data_disks: + +# List of LVM logical volumes for the data volume group. +#seed_hypervisor_lvm_group_data_lvs: + +# Libvirt storage LVM backing volume. +#seed_hypervisor_lvm_group_data_lv_libvirt_storage: + +# Size of libvirt storage LVM backing volume. +#seed_hypervisor_lvm_group_data_lv_libvirt_storage_size: + +# Filesystem for libvirt storage LVM backing volume. ext4 allows for shrinking. +#seed_hypervisor_lvm_group_data_lv_libvirt_storage_fs: + +############################################################################### +# Seed hypervisor libvirt storage pool configuration. + +# List of libvirt storage pools for the seed hypervisor. +#seed_hypervisor_libvirt_pools: + +# Libvirt storage pool for the seed VM. +#seed_hypervisor_libvirt_pool: + +# Name of the libvirt storage pool for the seed VM. +#seed_hypervisor_libvirt_pool_name: + +# Directory path of the libvirt storage pool for the seed VM. +#seed_hypervisor_libvirt_pool_path: + +# Directory mode of the libvirt storage pool for the seed VM. +#seed_hypervisor_libvirt_pool_mode: + +# Directory owner of the libvirt storage pool for the seed VM. +#seed_hypervisor_libvirt_pool_owner: + +# Directory group of the libvirt storage pool for the seed VM. +#seed_hypervisor_libvirt_pool_group: + +############################################################################### +# Seed hypervisor libvirt network configuration. + +# List of libvirt networks for the seed hypervisor. +#seed_hypervisor_libvirt_networks: + +############################################################################### +# Seed hypervisor sysctl configuration. + +# Dict of sysctl parameters to set. +#seed_hypervisor_sysctl_parameters: + +############################################################################### +# Seed hypervisor user configuration. + +# List of users to create. This should be in a format accepted by the +# singleplatform-eng.users role. +#seed_hypervisor_users: + +############################################################################### +# Dummy variable to allow Ansible to accept this file. +workaround_ansible_issue_8743: yes diff --git a/etc/kayobe/environments/aufn-ceph/seed-vm.yml b/etc/kayobe/environments/aufn-ceph/seed-vm.yml new file mode 100644 index 000000000..3254aa58e --- /dev/null +++ b/etc/kayobe/environments/aufn-ceph/seed-vm.yml @@ -0,0 +1,59 @@ +--- +############################################################################### +# Seed node VM configuration. + +# Name of the seed VM. +#seed_vm_name: + +# Memory in MB. +#seed_vm_memory_mb: +seed_vm_memory_mb: "{{ 4 * 1024 }}" + +# Number of vCPUs. +#seed_vm_vcpus: +seed_vm_vcpus: 1 + +# List of volumes. +#seed_vm_volumes: + +# Name of the storage pool for the seed VM volumes. +#seed_vm_pool: + +# Capacity of the seed VM root volume. +#seed_vm_root_capacity: + +# Format of the seed VM root volume. +#seed_vm_root_format: + +# Base image for the seed VM root volume. Default is +# "https://cloud-images.ubuntu.com/focal/current/focal-server-cloudimg-amd64.img" +# when os_distribution is "ubuntu", or +# "https://cloud.centos.org/centos/8-stream/x86_64/images/CentOS-Stream-GenericCloud-8-20210210.0.x86_64.qcow2" +# otherwise. +#seed_vm_root_image: + +# Capacity of the seed VM data volume. +#seed_vm_data_capacity: + +# Format of the seed VM data volume. +#seed_vm_data_format: + +# List of network interfaces to attach to the seed VM. Format is as accepted by +# the stackhpc.libvirt-vm role's libvirt_vms.interfaces variable. Default is +# one interface for each network in 'network_interfaces'. +# +# Example with one interface connected to a libvirt network called +# 'libvirt-net', and another interface directly plugged into a host device +# called 'eth1': +# +# seed_vm_interfaces: +# - network: libvirt-net +# - type: direct +# source: +# dev: eth1 +# +#seed_vm_interfaces: + +############################################################################### +# Dummy variable to allow Ansible to accept this file. +workaround_ansible_issue_8743: yes diff --git a/etc/kayobe/environments/aufn-ceph/stackhpc.yml b/etc/kayobe/environments/aufn-ceph/stackhpc.yml new file mode 100644 index 000000000..11b28ca6c --- /dev/null +++ b/etc/kayobe/environments/aufn-ceph/stackhpc.yml @@ -0,0 +1,35 @@ +--- +############################################################################### +# Kolla configuration. +# +# Docker namespace to use for Kolla images. Default is 'kolla'. +kolla_docker_namespace: stackhpc-dev + +############################################################################### +# Network configuration. + +# FIXME: SMS lab slurps DNS queries, so we need to use the Neutron internal DNS +# server. +resolv_nameservers: + - 10.209.0.3 + +############################################################################### +# Seed configuration. + +# Using a Pulp container on the seed-hypervisor. +seed_pulp_container_enabled: false + +############################################################################### +# StackHPC configuration. + +# Base URL of the StackHPC Test Pulp service. +stackhpc_release_pulp_url: "http://pulp-server.internal.sms-cloud:8080" + +# No client certs required to access Test Pulp. +stackhpc_release_pulp_client_cert: +stackhpc_release_pulp_client_key: + +pulp_url: http://192.168.33.4:8080 #"http://{{ admin_oc_net_name | net_ip(groups['seed-hypervisor'][0]) }}:80" +pulp_username: admin +# NOTE: must match deploy-pulp.sh +pulp_password: 9e4bfa04-9d9d-493d-9473-ba92e4361dae diff --git a/etc/kayobe/environments/aufn-ceph/storage.yml b/etc/kayobe/environments/aufn-ceph/storage.yml new file mode 100644 index 000000000..5b4ab8670 --- /dev/null +++ b/etc/kayobe/environments/aufn-ceph/storage.yml @@ -0,0 +1,126 @@ +--- +############################################################################### +# Storage node configuration. + +# User with which to access the storages via SSH during bootstrap, in order +# to setup the Kayobe user account. Default is {{ os_distribution }}. +#storage_bootstrap_user: + +############################################################################### +# Storage network interface configuration. + +# List of networks to which storage nodes are attached. +#storage_network_interfaces: + +# List of default networks to which storage nodes are attached. +#storage_default_network_interfaces: + +# List of extra networks to which storage nodes are attached. +#storage_extra_network_interfaces: + +# Whether this host requires access to Swift networks. +#storage_needs_swift_network: + +#storage_needs_swift_replication_network: + +############################################################################### +# Storage node BIOS configuration. + +# Dict of storage BIOS options. Format is same as that used by stackhpc.drac +# role. +#storage_bios_config: + +# Dict of default storage BIOS options. Format is same as that used by +# stackhpc.drac role. +#storage_bios_config_default: + +# Dict of additional storage BIOS options. Format is same as that used by +# stackhpc.drac role. +#storage_bios_config_extra: + +############################################################################### +# Storage node RAID configuration. + +# List of storage RAID volumes. Format is same as that used by stackhpc.drac +# role. +#storage_raid_config: + +# List of default storage RAID volumes. Format is same as that used by +# stackhpc.drac role. +#storage_raid_config_default: + +# List of additional storage RAID volumes. Format is same as that used by +# stackhpc.drac role. +#storage_raid_config_extra: + +############################################################################### +# Storage node software RAID configuration. + +# List of software RAID arrays. See mrlesmithjr.mdadm role for format. +#storage_mdadm_arrays: + +############################################################################### +# Storage node encryption configuration. + +# List of block devices to encrypt. See stackhpc.luks role for format. +#storage_luks_devices: + +############################################################################### +# Storage node LVM configuration. + +# List of storage volume groups. See mrlesmithjr.manage-lvm role for +# format. +#storage_lvm_groups: +storage_lvm_groups: [] + +# Default list of storage volume groups. See mrlesmithjr.manage-lvm role for +# format. +#storage_lvm_groups_default: + +# Additional list of storage volume groups. See mrlesmithjr.manage-lvm role +# for format. +#storage_lvm_groups_extra: + +# Whether a 'data' LVM volume group should exist on storage hosts. By default +# this contains a 'docker-volumes' logical volume for Docker volume storage. It +# will also be used for Docker container and image storage if +# 'docker_storage_driver' is set to 'devicemapper'. Default is true if +# 'docker_storage_driver' is set to 'devicemapper', or false otherwise. +#storage_lvm_group_data_enabled: + +# Storage LVM volume group for data. See mrlesmithjr.manage-lvm role for +# format. +#storage_lvm_group_data: + +# List of disks for use by storage LVM data volume group. Default to an +# invalid value to require configuration. +#storage_lvm_group_data_disks: + +# List of LVM logical volumes for the data volume group. +#storage_lvm_group_data_lvs: + +# Docker volumes LVM backing volume. +#storage_lvm_group_data_lv_docker_volumes: + +# Size of docker volumes LVM backing volume. +#storage_lvm_group_data_lv_docker_volumes_size: + +# Filesystem for docker volumes LVM backing volume. ext4 allows for shrinking. +#storage_lvm_group_data_lv_docker_volumes_fs: + +############################################################################### +# Storage node sysctl configuration. + +# Dict of sysctl parameters to set. +#storage_sysctl_parameters: + +############################################################################### +# Storage node user configuration. + +# List of users to create. This should be in a format accepted by the +# singleplatform-eng.users role. +#storage_users: + +############################################################################### +# Dummy variable to allow Ansible to accept this file. +workaround_ansible_issue_8743: yes diff --git a/etc/kayobe/environments/aufn-ceph/tenks.yml b/etc/kayobe/environments/aufn-ceph/tenks.yml new file mode 100644 index 000000000..56ead9402 --- /dev/null +++ b/etc/kayobe/environments/aufn-ceph/tenks.yml @@ -0,0 +1,89 @@ +--- +# This file holds the config given to Tenks when running `tenks-deploy.sh`. It +# assumes the existence of the bridges `brmgmt` and `brcloud`. + +node_types: + controller: + memory_mb: 8192 + vcpus: 4 + volumes: + # There is a minimum disk space capacity requirement of 4GiB when using Ironic Python Agent: + # https://github.com/openstack/ironic-python-agent/blob/master/ironic_python_agent/utils.py#L290 + - capacity: 20GiB + physical_networks: + - provision-net + - mgmt-net + - cloud-net + console_log_enabled: true + storage: + memory_mb: 8192 + vcpus: 4 + volumes: + # There is a minimum disk space capacity requirement of 4GiB when using Ironic Python Agent: + # https://github.com/openstack/ironic-python-agent/blob/master/ironic_python_agent/utils.py#L290 + - capacity: 10GiB + # Ceph volume + - capacity: 10GiB + physical_networks: + - provision-net + - cloud-net + console_log_enabled: true + compute: + memory_mb: 8192 + vcpus: 4 + volumes: + # There is a minimum disk space capacity requirement of 4GiB when using Ironic Python Agent: + # https://github.com/openstack/ironic-python-agent/blob/master/ironic_python_agent/utils.py#L290 + - capacity: 10GiB + physical_networks: + - provision-net + - cloud-net + console_log_enabled: true + baremetal: + memory_mb: 4096 + vcpus: 1 + volumes: + # There is a minimum disk space capacity requirement of 4GiB when using Ironic Python Agent: + # https://github.com/openstack/ironic-python-agent/blob/master/ironic_python_agent/utils.py#L290 + - capacity: 5GiB + physical_networks: + - cloud-net + console_log_enabled: true + +specs: + - type: controller + count: 3 + node_name_prefix: controller + ironic_config: + resource_class: test-rc + network_interface: noop + - type: storage + count: 1 + node_name_prefix: storage + ironic_config: + resource_class: test-rc + network_interface: noop + - type: compute + count: 3 + node_name_prefix: compute + ironic_config: + resource_class: test-rc + network_interface: noop + - type: baremetal + count: 1 + node_name_prefix: baremetal + +ipmi_address: 192.168.33.4 +ipmi_port_range_end: 6250 + +nova_flavors: [] + +physnet_mappings: + mgmt-net: brmgmt + provision-net: brprov + cloud-net: brcloud + +bridge_type: linuxbridge + +# No placement service. +wait_for_placement: false diff --git a/etc/kayobe/inventory/groups b/etc/kayobe/inventory/groups index e51195309..e87ce82c4 100644 --- a/etc/kayobe/inventory/groups +++ b/etc/kayobe/inventory/groups @@ -60,7 +60,7 @@ seed controllers network monitoring -storage +#storage compute [docker-registry:children] From eb5a26fd68bb3baf3aa9d205cc2012e58219f066 Mon Sep 17 00:00:00 2001 From: Mark Goddard Date: Thu, 14 Oct 2021 12:38:54 +0000 Subject: [PATCH 02/33] aufn: add script to deploy pulp --- .../environments/aufn-ceph/deploy-pulp.sh | 51 +++++++++++++++++++ 1 file changed, 51 insertions(+) create mode 100755 etc/kayobe/environments/aufn-ceph/deploy-pulp.sh diff --git a/etc/kayobe/environments/aufn-ceph/deploy-pulp.sh b/etc/kayobe/environments/aufn-ceph/deploy-pulp.sh new file mode 100755 index 000000000..970dd299c --- /dev/null +++ b/etc/kayobe/environments/aufn-ceph/deploy-pulp.sh @@ -0,0 +1,51 @@ +#!/bin/bash + +set -e + +# Seed hypervisor provision_oc IP. +pulp_ip=192.168.33.4 + +if $(which dnf >/dev/null 2>&1); then + CONTAINER=podman + if ! type podman > /dev/null 2>&1; then + sudo dnf -y install podman + fi +else + CONTAINER="sudo docker" + if ! type docker > /dev/null 2>&1; then + sudo apt update + sudo apt -y install docker.io + fi +fi + +if $CONTAINER container inspect pulp > /dev/null 2>&1; then + echo "Pulp already deployed" + exit +fi + +mkdir -p ~/pulp +cd ~/pulp + +mkdir -p settings pulp_storage pgsql containers +echo "CONTENT_ORIGIN='http://${pulp_ip}:8080' +ANSIBLE_API_HOSTNAME='http://${pulp_ip}:8080' +ANSIBLE_CONTENT_HOSTNAME='http://${pulp_ip}:8080/pulp/content' +TOKEN_AUTH_DISABLED=True" > settings/settings.py + +$CONTAINER run --detach \ + --publish 8080:80 \ + --name pulp \ + --volume "$(pwd)/settings":/etc/pulp:Z \ + --volume "$(pwd)/pulp_storage":/var/lib/pulp:Z \ + --volume "$(pwd)/pgsql":/var/lib/pgsql:Z \ + --volume "$(pwd)/containers":/var/lib/containers:Z \ + --device /dev/fuse \ + --add-host pulp-server.internal.sms-cloud:10.205.3.187 \ + docker.io/pulp/pulp + +until curl --fail http://localhost:8080/pulp/api/v3/status/ > /dev/null 2>&1; do + sleep 2 +done + +$CONTAINER exec pulp pulpcore-manager reset-admin-password --password 9e4bfa04-9d9d-493d-9473-ba92e4361dae +echo "Pulp successfully deployed" From 6c1184ab178225b034bf09a2c717df6ea5ffd391 Mon Sep 17 00:00:00 2001 From: Mark Goddard Date: Fri, 22 Oct 2021 15:59:58 +0000 Subject: [PATCH 03/33] Add a-universe-from-nothing.sh script --- .../aufn-ceph/a-universe-from-nothing.sh | 132 ++++++++++++++++++ .../aufn-ceph/configure-local-networking.sh | 5 + .../environments/aufn-ceph/init-runonce.sh | 3 +- 3 files changed, 138 insertions(+), 2 deletions(-) create mode 100755 etc/kayobe/environments/aufn-ceph/a-universe-from-nothing.sh diff --git a/etc/kayobe/environments/aufn-ceph/a-universe-from-nothing.sh b/etc/kayobe/environments/aufn-ceph/a-universe-from-nothing.sh new file mode 100755 index 000000000..36712f229 --- /dev/null +++ b/etc/kayobe/environments/aufn-ceph/a-universe-from-nothing.sh @@ -0,0 +1,132 @@ +#!/bin/bash + +# Cheat script for a full deployment. +# This should be used for testing only. + +set -eu + +BASE_PATH=~ +KAYOBE_BRANCH=stackhpc/wallaby +KAYOBE_CONFIG_BRANCH=stackhpc/wallaby +KAYOBE_ENVIRONMENT=aufn-ceph + +# FIXME: Work around lack of DNS on SMS lab. +cat << EOF | sudo tee -a /etc/hosts +10.0.0.34 pelican pelican.service.compute.sms-lab.cloud +10.205.3.187 pulp-server pulp-server.internal.sms-cloud +EOF + +# Install git and tmux. +if $(which dnf 2>/dev/null >/dev/null); then + sudo dnf -y install git tmux python3-virtualenv +else + sudo apt update + sudo apt -y install git tmux gcc libffi-dev python3-dev python-is-python3 python3-virtualenv +fi + +# Disable the firewall. +sudo systemctl is-enabled firewalld && sudo systemctl stop firewalld && sudo systemctl disable firewalld + +# Disable SELinux both immediately and permanently. +if $(which setenforce 2>/dev/null >/dev/null); then + sudo setenforce 0 + sudo sed -i 's/^SELINUX=enforcing/SELINUX=disabled/' /etc/selinux/config +fi + +# Prevent sudo from performing DNS queries. +echo 'Defaults !fqdn' | sudo tee /etc/sudoers.d/no-fqdn + +# Clone repositories +cd $BASE_PATH +mkdir -p src +pushd src +[[ -d kayobe ]] || git clone https://github.com/stackhpc/kayobe.git -b $KAYOBE_BRANCH +[[ -d kayobe-config ]] || git clone https://github.com/stackhpc/stackhpc-kayobe-config kayobe-config -b $KAYOBE_CONFIG_BRANCH +[[ -d kayobe/tenks ]] || (cd kayobe && git clone https://opendev.org/openstack/tenks.git) +popd + +# Create Kayobe virtualenv +mkdir -p venvs +pushd venvs +if [[ ! -d kayobe ]]; then + virtualenv kayobe +fi +# NOTE: Virtualenv's activate and deactivate scripts reference an +# unbound variable. +set +u +source kayobe/bin/activate +set -u +pip install -U pip +pip install ../src/kayobe +popd + +# Activate environment +pushd $BASE_PATH/src/kayobe-config +source kayobe-env --environment $KAYOBE_ENVIRONMENT + +# Configure host networking (bridge, routes & firewall) +$KAYOBE_CONFIG_PATH/environments/$KAYOBE_ENVIRONMENT/configure-local-networking.sh + +# Deploy Pulp +$KAYOBE_CONFIG_PATH/environments/$KAYOBE_ENVIRONMENT/deploy-pulp.sh + +# Bootstrap the Ansible control host. +kayobe control host bootstrap + +# Sync package & container repositories. +kayobe playbook run $KAYOBE_CONFIG_PATH/ansible/pulp-repo-sync.yml +kayobe playbook run $KAYOBE_CONFIG_PATH/ansible/pulp-repo-publish.yml + +# NOTE: Building Ubuntu containers locally for now. +if $(which dnf 2>/dev/null >/dev/null); then + kayobe playbook run $KAYOBE_CONFIG_PATH/ansible/pulp-container-sync.yml + kayobe playbook run $KAYOBE_CONFIG_PATH/ansible/pulp-container-publish.yml +fi + +# Configure the seed hypervisor host. +kayobe seed hypervisor host configure + +# Provision the seed VM. +kayobe seed vm provision + +# Configure the seed host, and deploy a local registry. +kayobe seed host configure + +# NOTE: Building Ubuntu containers locally for now. +if ! $(which dnf 2>/dev/null >/dev/null); then + kayobe seed container image build --push + kayobe overcloud container image build --push +fi + +# Deploy the seed services. +kayobe seed service deploy + +# Deploying the seed restarts networking interface, +# run configure-local-networking.sh again to re-add routes. +$KAYOBE_CONFIG_PATH/environments/$KAYOBE_ENVIRONMENT/configure-local-networking.sh + +# NOTE: Make sure to use ./tenks, since just ‘tenks’ will install via PyPI. +(export TENKS_CONFIG_PATH=$KAYOBE_CONFIG_PATH/environments/$KAYOBE_ENVIRONMENT/tenks.yml && \ + export KAYOBE_CONFIG_SOURCE_PATH=$BASE_PATH/src/kayobe-config && \ + export KAYOBE_VENV_PATH=$BASE_PATH/venvs/kayobe && \ + cd $BASE_PATH/src/kayobe && \ + ./dev/tenks-deploy-overcloud.sh ./tenks) + +# Inspect and provision the overcloud hardware: +kayobe overcloud inventory discover +kayobe overcloud hardware inspect +kayobe overcloud provision +kayobe overcloud host configure +kayobe playbook run $KAYOBE_CONFIG_PATH/ansible/cephadm.yml +kayobe playbook run $KAYOBE_CONFIG_PATH/ansible/ceph-config.yml +kayobe overcloud container image pull +kayobe overcloud service deploy +source $KOLLA_CONFIG_PATH/public-openrc.sh +kayobe overcloud post configure +source $KOLLA_CONFIG_PATH/public-openrc.sh +$KAYOBE_CONFIG_PATH/environments/$KAYOBE_ENVIRONMENT/init-runonce.sh + +(export KAYOBE_CONFIG_SOURCE_PATH=$BASE_PATH/src/kayobe-config && \ + export KAYOBE_VENV_PATH=$BASE_PATH/venvs/kayobe && \ + cd $BASE_PATH/src/kayobe && \ + ./dev/overcloud-test-vm.sh) diff --git a/etc/kayobe/environments/aufn-ceph/configure-local-networking.sh b/etc/kayobe/environments/aufn-ceph/configure-local-networking.sh index e38ca1d69..a50e7b144 100755 --- a/etc/kayobe/environments/aufn-ceph/configure-local-networking.sh +++ b/etc/kayobe/environments/aufn-ceph/configure-local-networking.sh @@ -61,6 +61,11 @@ done sudo iptables -A POSTROUTING -t nat -o $iface -j MASQUERADE sudo sysctl -w net.ipv4.conf.all.forwarding=1 +# FIXME: IP MASQUERADE from control plane fails without this on Ubuntu. +if ! $(which dnf >/dev/null 2>&1); then + echo 0 | sudo tee /proc/sys/net/bridge/bridge-nf-call-iptables +fi + # Configure port forwarding from the hypervisor to the Horizon GUI on the # controller. sudo iptables -A FORWARD -i $iface -o brprov -m conntrack --ctstate ESTABLISHED,RELATED -j ACCEPT diff --git a/etc/kayobe/environments/aufn-ceph/init-runonce.sh b/etc/kayobe/environments/aufn-ceph/init-runonce.sh index 2f66704c1..44e6a5e28 100755 --- a/etc/kayobe/environments/aufn-ceph/init-runonce.sh +++ b/etc/kayobe/environments/aufn-ceph/init-runonce.sh @@ -8,8 +8,7 @@ fi ~/os-venv/bin/pip install -U pip ~/os-venv/bin/pip install python-openstackclient -c https://releases.openstack.org/constraints/upper/master -parent="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" -init_runonce=$parent/../../../../../kolla-ansible/tools/init-runonce +init_runonce=$KOLLA_SOURCE_PATH/tools/init-runonce if [[ ! -f $init_runonce ]]; then echo "Unable to find kolla-ansible repo" exit 1 From 05aa01b3d23177475b8b3fb8d498637b09358d87 Mon Sep 17 00:00:00 2001 From: Mark Goddard Date: Mon, 25 Jul 2022 12:30:17 +0100 Subject: [PATCH 04/33] Revert SMS lab DNS workaround --- etc/kayobe/environments/aufn-ceph/stackhpc.yml | 8 -------- 1 file changed, 8 deletions(-) diff --git a/etc/kayobe/environments/aufn-ceph/stackhpc.yml b/etc/kayobe/environments/aufn-ceph/stackhpc.yml index 11b28ca6c..88dc1302b 100644 --- a/etc/kayobe/environments/aufn-ceph/stackhpc.yml +++ b/etc/kayobe/environments/aufn-ceph/stackhpc.yml @@ -5,14 +5,6 @@ # Docker namespace to use for Kolla images. Default is 'kolla'. kolla_docker_namespace: stackhpc-dev -############################################################################### -# Network configuration. - -# FIXME: SMS lab slurps DNS queries, so we need to use the Neutron internal DNS -# server. -resolv_nameservers: - - 10.209.0.3 - ############################################################################### # Seed configuration. From 7c9b29b7d49712fb08d939d84520136e3b1eefbe Mon Sep 17 00:00:00 2001 From: Scott Davidson Date: Thu, 17 Nov 2022 10:45:52 +0000 Subject: [PATCH 05/33] Remove local Ubuntu image building workaround --- .../aufn-ceph/a-universe-from-nothing.sh | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/etc/kayobe/environments/aufn-ceph/a-universe-from-nothing.sh b/etc/kayobe/environments/aufn-ceph/a-universe-from-nothing.sh index 36712f229..af5c993d7 100755 --- a/etc/kayobe/environments/aufn-ceph/a-universe-from-nothing.sh +++ b/etc/kayobe/environments/aufn-ceph/a-universe-from-nothing.sh @@ -78,10 +78,10 @@ kayobe playbook run $KAYOBE_CONFIG_PATH/ansible/pulp-repo-sync.yml kayobe playbook run $KAYOBE_CONFIG_PATH/ansible/pulp-repo-publish.yml # NOTE: Building Ubuntu containers locally for now. -if $(which dnf 2>/dev/null >/dev/null); then - kayobe playbook run $KAYOBE_CONFIG_PATH/ansible/pulp-container-sync.yml - kayobe playbook run $KAYOBE_CONFIG_PATH/ansible/pulp-container-publish.yml -fi +# if $(which dnf 2>/dev/null >/dev/null); then +kayobe playbook run $KAYOBE_CONFIG_PATH/ansible/pulp-container-sync.yml +kayobe playbook run $KAYOBE_CONFIG_PATH/ansible/pulp-container-publish.yml +# fi # Configure the seed hypervisor host. kayobe seed hypervisor host configure @@ -93,10 +93,10 @@ kayobe seed vm provision kayobe seed host configure # NOTE: Building Ubuntu containers locally for now. -if ! $(which dnf 2>/dev/null >/dev/null); then - kayobe seed container image build --push - kayobe overcloud container image build --push -fi +# if ! $(which dnf 2>/dev/null >/dev/null); then +# kayobe seed container image build --push +# kayobe overcloud container image build --push +# fi # Deploy the seed services. kayobe seed service deploy From 80daa7fc015592220471553998bf4ee562c07b6c Mon Sep 17 00:00:00 2001 From: Scott Davidson Date: Thu, 17 Nov 2022 10:46:07 +0000 Subject: [PATCH 06/33] Remove unused config sections --- etc/kayobe/environments/aufn-ceph/globals.yml | 44 ---- etc/kayobe/environments/aufn-ceph/ipa.yml | 103 --------- etc/kayobe/environments/aufn-ceph/kolla.yml | 215 ------------------ .../environments/aufn-ceph/networks.yml | 17 -- .../aufn-ceph/seed-hypervisor.yml | 89 -------- etc/kayobe/environments/aufn-ceph/seed-vm.yml | 4 - etc/kayobe/environments/aufn-ceph/storage.yml | 82 ------- 7 files changed, 554 deletions(-) diff --git a/etc/kayobe/environments/aufn-ceph/globals.yml b/etc/kayobe/environments/aufn-ceph/globals.yml index 9b17a9c05..feab452ca 100644 --- a/etc/kayobe/environments/aufn-ceph/globals.yml +++ b/etc/kayobe/environments/aufn-ceph/globals.yml @@ -1,47 +1,6 @@ --- # Kayobe global configuration. -############################################################################### -# Local path configuration (Ansible control host). - -# Path to Kayobe configuration directory on Ansible control host, with an -# environment path appended if kayobe_environment is set. -#kayobe_config_path: - -# Name of Kayobe environment to use. Default is $KAYOBE_ENVIRONMENT, or an -# empty string if $KAYOBE_ENVIRONMENT is not set. Can also be set via the -# --environment argument when invoking kayobe. -#kayobe_environment: - -# Path to Kayobe configuration directory on Ansible control host with an -# environment path appended if kayobe_environment is set. -#kayobe_env_config_path: - -############################################################################### -# Remote path configuration (seed, seed-hypervisor and overcloud hosts). - -# Base path for kayobe state on remote hosts. -#base_path: - -# Path in which to store configuration on remote hosts. -#config_path: - -# Path in which to cache downloaded images on remote hosts. -#image_cache_path: - -# Path on which to checkout source code repositories on remote hosts. -#source_checkout_path: - -# Path on which to create python virtualenvs on remote hosts. -#virtualenv_path: - -############################################################################### -# User configuration. - -# User with which to access remote hosts. This user will be created if it does -# not exist. -#kayobe_ansible_user: - ############################################################################### # OS distribution. @@ -53,6 +12,3 @@ os_distribution: "{{ lookup('pipe', '. /etc/os-release && echo $ID') | trim }}" # "focal" when os_distribution is "ubuntu". #os_release: -############################################################################### -# Dummy variable to allow Ansible to accept this file. -workaround_ansible_issue_8743: yes diff --git a/etc/kayobe/environments/aufn-ceph/ipa.yml b/etc/kayobe/environments/aufn-ceph/ipa.yml index dd42736e8..6aef4f7b7 100644 --- a/etc/kayobe/environments/aufn-ceph/ipa.yml +++ b/etc/kayobe/environments/aufn-ceph/ipa.yml @@ -1,70 +1,6 @@ --- # Ironic Python Agent (IPA) configuration. -############################################################################### -# Ironic Python Agent (IPA) image build configuration. - -# Whether to build IPA images from source. -#ipa_build_images: - -# URL of IPA source repository. -#ipa_build_source_url: - -# Version of IPA source repository. Default is {{ openstack_branch }}. -#ipa_build_source_version: - -# URL of IPA builder source repository. -#ipa_builder_source_url: - -# Version of IPA builder source repository. Default is master. -#ipa_build_source_version: - -# List of default Diskimage Builder (DIB) elements to use when building IPA -# images. Default is ["centos", "enable-serial-console", -# "ironic-python-agent-ramdisk"]. -#ipa_build_dib_elements_default: - -# List of additional Diskimage Builder (DIB) elements to use when building IPA -# images. Default is none. -#ipa_build_dib_elements_extra: - -# List of Diskimage Builder (DIB) elements to use when building IPA images. -# Default is combination of ipa_build_dib_elements_default and -# ipa_build_dib_elements_extra. -#ipa_build_dib_elements: - -# Dictionary of default environment variables to provide to Diskimage Builder -# (DIB) during IPA image build. -#ipa_build_dib_env_default: - -# Dictionary of additional environment variables to provide to Diskimage -# Builder (DIB) during IPA image build. -#ipa_build_dib_env_extra: - -# Dictionary of environment variables to provide to Diskimage Builder (DIB) -# during IPA image build. -#ipa_build_dib_env: - -# List of default git repositories containing Diskimage Builder (DIB) elements. -# See stackhpc.os-images role for usage. Default is one item for IPA builder. -#ipa_build_dib_git_elements_default: - -# List of additional git repositories containing Diskimage Builder (DIB) -# elements. See stackhpc.os-images role for usage. Default is empty. -#ipa_build_dib_git_elements_extra: - -# List of git repositories containing Diskimage Builder (DIB) elements. See -# stackhpc.os-images role for usage. Default is a combination of -# ipa_build_dib_git_elements_default and ipa_build_dib_git_elements_extra. -#ipa_build_dib_git_elements: - -# List of DIB packages to install. Default is none. -#ipa_build_dib_packages: - -# Upper constraints file for installing packages in the virtual environment -# used for building IPA images. Default is {{ pip_upper_constraints_file }}. -#ipa_build_upper_constraints_file: - ############################################################################### # Ironic Python Agent (IPA) images configuration. @@ -97,42 +33,3 @@ ipa_ramdisk_upstream_url: "https://tarballs.openstack.org/ironic-python-agent/ti # Algorithm of checksum of Ironic deployment ramdisk image. #ipa_ramdisk_checksum_algorithm: - -############################################################################### -# Ironic Python Agent (IPA) deployment configuration. - -# Whether to enable collection of LLDP TLVs. -#ipa_collect_lldp: - -# List of default inspection collectors to run. -# NOTE: extra-hardware is not currently included as it requires a ramdisk -# with the hardware python module installed. -#ipa_collectors_default: - -# List of additional inspection collectors to run. -#ipa_collectors_extra: - -# List of inspection collectors to run. -#ipa_collectors: - -# List of default inspection benchmarks to run. -#ipa_benchmarks_default: - -# List of extra inspection benchmarks to run. -#ipa_benchmarks_extra: - -# List of inspection benchmarks to run. -#ipa_benchmarks: - -# List of default kernel parameters for Ironic python agent. -#ipa_kernel_options_default: - -# List of additional kernel parameters for Ironic python agent. -#ipa_kernel_options_extra: - -# List of kernel parameters for Ironic python agent. -#ipa_kernel_options: - -############################################################################### -# Dummy variable to allow Ansible to accept this file. -workaround_ansible_issue_8743: yes diff --git a/etc/kayobe/environments/aufn-ceph/kolla.yml b/etc/kayobe/environments/aufn-ceph/kolla.yml index 6d31f78f1..3d52dd3a1 100644 --- a/etc/kayobe/environments/aufn-ceph/kolla.yml +++ b/etc/kayobe/environments/aufn-ceph/kolla.yml @@ -1,120 +1,6 @@ --- # Kayobe Kolla configuration. -############################################################################### -# Kolla installation. - -# Type of Kolla control installation. One of 'binary' or 'source'. -#kolla_ctl_install_type: - -# Path to directory for kolla source code checkout. -#kolla_source_path: - -# URL of Kolla source code repository if type is 'source'. -#kolla_source_url: - -# Version (branch, tag, etc.) of Kolla source code repository if type is -# 'source'. Default is {{ openstack_branch }}. -#kolla_source_version: - -# Path to virtualenv in which to install kolla. -#kolla_venv: - -# Path in which to generate kolla configuration. -#kolla_build_config_path: - -############################################################################### -# Kolla-ansible installation. - -# Type of Kolla-ansible control installation. One of 'binary' or 'source'. -# Default is 'source'. -#kolla_ansible_ctl_install_type: - -# Path to directory for kolla-ansible source code checkout. -# Default is $KOLLA_SOURCE_PATH, or $PWD/src/kolla-ansible if -# $KOLLA_SOURCE_PATH is not set. -#kolla_ansible_source_path: - -# URL of Kolla Ansible source code repository if type is 'source'. Default is -# https://opendev.org/openstack/kolla-ansible. -#kolla_ansible_source_url: - -# Version (branch, tag, etc.) of Kolla Ansible source code repository if type -# is 'source'. Default is {{ openstack_branch }}. -#kolla_ansible_source_version: - -# Path to virtualenv in which to install kolla-ansible. Default is -# $KOLLA_VENV_PATH or $PWD/venvs/kolla-ansible if $KOLLA_VENV_PATH is not set. -#kolla_ansible_venv: - -# Extra requirements to install inside the kolla-ansible virtualenv. -#kolla_ansible_venv_extra_requirements: - -# Path to Kolla-ansible configuration directory. Default is $KOLLA_CONFIG_PATH -# or /etc/kolla if $KOLLA_CONFIG_PATH is not set. -#kolla_config_path: - -# Path to Kolla-ansible node custom configuration directory. Default is -# {{ kolla_config_path }}/config. -#kolla_node_custom_config_path: - -############################################################################### -# Kolla configuration. - -# Kolla base container image distribution. Options are "centos", "debian", -# "ubuntu". Default is {{ os_distribution }}. -#kolla_base_distro: - -# Kolla container image type: binary or source. Default is 'binary'. -#kolla_install_type: - -# URL of docker registry to use for Kolla images. Default is not set, in which -# case Dockerhub will be used. -#kolla_docker_registry: - -# Docker namespace to use for Kolla images. Default is 'kolla'. -#kolla_docker_namespace: - -# Username to use to access a docker registry. Default is not set, in which -# case the registry will be used without authentication. -#kolla_docker_registry_username: "{{ stackhpc_docker_registry_username }}" - -# Password to use to access a docker registry. Default is not set, in which -# case the registry will be used without authentication. -#kolla_docker_registry_password: "{{ stackhpc_docker_registry_password }}" - -# Kolla OpenStack release version. This should be a Docker image tag. -# Default is {{ openstack_release }}. -#kolla_openstack_release: - -# Docker tag applied to built container images. Default is -# {{ kolla_openstack_release }}. -#kolla_tag: - -# Dict mapping names of sources to their definitions for -# kolla_install_type=source. See kolla.common.config for details. -# Example: -# kolla_sources: -# ironic-base: -# type: git -# location: https://github.com/openstack/ironic -# reference: master -#kolla_sources: - -############################################################################### -# Kolla image build configuration. - -# Dict mapping Jinja2 block names in kolla's Docker images to their contents. -#kolla_build_blocks: - -# Dict mapping image customization variable names to their values. -# Each variable takes the form: -# __ -# Hyphens in the image name must be replaced with underscores. The -# customization is most commonly packages. The operation should be one of -# override, append or remove. The value should be a list. -#kolla_build_customizations: - ############################################################################### # Kolla-ansible inventory configuration. @@ -216,40 +102,6 @@ kolla_overcloud_inventory_storage_groups: [] # used. #kolla_overcloud_inventory_pass_through_host_vars_map: -############################################################################### -# Kolla-ansible configuration. - -# Virtualenv directory where Kolla-ansible's ansible modules will execute -# remotely on the target nodes. If None, no virtualenv will be used. -#kolla_ansible_target_venv: - -# Whether TLS is enabled for the external API endpoints. Default is 'no'. -#kolla_enable_tls_external: - -# Whether TLS is enabled for the internal API endpoints. Default is 'no'. -#kolla_enable_tls_internal: - -# Whether debug logging is enabled. Default is 'false'. -#kolla_openstack_logging_debug: - -# Upper constraints file for installation of Kolla. -# Default value is {{ pip_upper_constraints_file }}. -#kolla_upper_constraints_file: - -# User account to use for Kolla SSH access. Default is 'kolla'. -#kolla_ansible_user: - -# Primary group of Kolla SSH user. Default is 'kolla'. -#kolla_ansible_group: - -# Whether to use privilege escalation for all operations performed via Kolla -# Ansible. Default is 'false'. -#kolla_ansible_become: - -# Whether to create a user account, configure passwordless sudo and authorise -# an SSH key for Kolla Ansible. Default is 'true'. -#kolla_ansible_create_user: - ############################################################################### # Kolla feature flag configuration. @@ -413,70 +265,3 @@ kolla_enable_ovn: true #kolla_enable_zookeeper: #kolla_enable_zun: -############################################################################### -# Passwords and credentials. - -# Dictionary containing default custom passwords to add or override in the -# Kolla passwords file. -#kolla_ansible_default_custom_passwords: - -# Dictionary containing custom passwords to add or override in the Kolla -# passwords file. -#kolla_ansible_custom_passwords: - -############################################################################### -# OpenStack API addresses. - -# Virtual IP address of OpenStack internal API. Default is the vip_address -# attribute of the internal network. -#kolla_internal_vip_address: - -# Fully Qualified Domain Name (FQDN) of OpenStack internal API. Default is the -# fqdn attribute of the internal network if set, otherwise -# kolla_internal_vip_address. -#kolla_internal_fqdn: - -# Virtual IP address of OpenStack external API. Default is the vip_address -# attribute of the external network. -#kolla_external_vip_address: - -# Fully Qualified Domain Name (FQDN) of OpenStack external API. Default is the -# fqdn attribute of the external network if set, otherwise -# kolla_external_vip_address. -#kolla_external_fqdn: - -############################################################################### -# TLS certificate bundle management - -# External API certificate bundle. -# -# When kolla_enable_tls_external is true, this should contain an X.509 -# certificate bundle for the external API. -# -# Note that this should be formatted as a literal style block scalar. -# -# NOTE: kolla_tls_cert has been renamed to kolla_external_tls_cert. Support for -# the deprecated name kolla_tls_cert will be removed in a future release. -#kolla_external_tls_cert: - -# Path to a CA certificate file to use for the OS_CACERT environment variable -# in public-openrc.sh file when TLS is enabled, instead of Kolla-Ansible's -# default. -#kolla_external_fqdn_cacert: - -# Internal API certificate bundle. -# -# When kolla_enable_tls_internal is true, this should contain an X.509 -# certificate bundle for the internal API. -# -# Note that this should be formatted as a literal style block scalar. -#kolla_internal_tls_cert: - -# Path to a CA certificate file to use for the OS_CACERT environment variable -# in admin-openrc.sh file when TLS is enabled, instead of Kolla-Ansible's -# default. -#kolla_internal_fqdn_cacert: - -############################################################################### -# Dummy variable to allow Ansible to accept this file. -workaround_ansible_issue_8743: yes diff --git a/etc/kayobe/environments/aufn-ceph/networks.yml b/etc/kayobe/environments/aufn-ceph/networks.yml index 44fb4e192..6ef780d20 100644 --- a/etc/kayobe/environments/aufn-ceph/networks.yml +++ b/etc/kayobe/environments/aufn-ceph/networks.yml @@ -139,23 +139,6 @@ storage_mgmt_mtu: 1450 storage_mgmt_vlan: 106 storage_mgmt_physical_network: cloud -############################################################################### -# Network virtual patch link configuration. - -# Suffix for Open vSwitch bridge names. -#network_bridge_suffix_ovs: - -# Prefix for virtual patch interface names. -#network_patch_prefix: - -# Suffix for virtual patch link interface names when connected towards the -# physical interface. -#network_patch_suffix_phy: - -# Suffix for virtual patch link interface names when connected towards the -# OVS bridge. -#network_patch_suffix_ovs: - ############################################################################### # Network routing table configuration. diff --git a/etc/kayobe/environments/aufn-ceph/seed-hypervisor.yml b/etc/kayobe/environments/aufn-ceph/seed-hypervisor.yml index 3392f0a24..6b918ab60 100644 --- a/etc/kayobe/environments/aufn-ceph/seed-hypervisor.yml +++ b/etc/kayobe/environments/aufn-ceph/seed-hypervisor.yml @@ -21,92 +21,3 @@ seed_hypervisor_extra_network_interfaces: - "{{ internal_net_name }}" - "{{ public_net_name }}" -############################################################################### -# Seed hypervisor node software RAID configuration. - -# List of software RAID arrays. See mrlesmithjr.mdadm role for format. -#seed_hypervisor_mdadm_arrays: - -############################################################################### -# Seed hypervisor node encryption configuration. - -# List of block devices to encrypt. See stackhpc.luks role for format. -#seed_hypervisor_luks_devices: - -############################################################################### -# Seed hypervisor node LVM configuration. - -# List of seed hypervisor volume groups. See mrlesmithjr.manage-lvm role for -# format. Set to "{{ seed_hypervisor_lvm_groups_with_data }}" to create a -# volume group for libvirt storage. -#seed_hypervisor_lvm_groups: - -# Suggested list of seed hypervisor volume groups for libvirt. Not used by -# default. -#seed_hypervisor_lvm_groups_with_data: - -# Seed LVM volume group for data. See mrlesmithjr.manage-lvm role for format. -#seed_hypervisor_lvm_group_data: - -# List of disks for use by seed hypervisor LVM data volume group. Default to an -# invalid value to require configuration. -#seed_hypervisor_lvm_group_data_disks: - -# List of LVM logical volumes for the data volume group. -#seed_hypervisor_lvm_group_data_lvs: - -# Libvirt storage LVM backing volume. -#seed_hypervisor_lvm_group_data_lv_libvirt_storage: - -# Size of libvirt storage LVM backing volume. -#seed_hypervisor_lvm_group_data_lv_libvirt_storage_size: - -# Filesystem for libvirt storage LVM backing volume. ext4 allows for shrinking. -#seed_hypervisor_lvm_group_data_lv_libvirt_storage_fs: - -############################################################################### -# Seed hypervisor libvirt storage pool configuration. - -# List of libvirt storage pools for the seed hypervisor. -#seed_hypervisor_libvirt_pools: - -# Libvirt storage pool for the seed VM. -#seed_hypervisor_libvirt_pool: - -# Name of the libvirt storage pool for the seed VM. -#seed_hypervisor_libvirt_pool_name: - -# Directory path of the libvirt storage pool for the seed VM. -#seed_hypervisor_libvirt_pool_path: - -# Directory mode of the libvirt storage pool for the seed VM. -#seed_hypervisor_libvirt_pool_mode: - -# Directory owner of the libvirt storage pool for the seed VM. -#seed_hypervisor_libvirt_pool_owner: - -# Directory group of the libvirt storage pool for the seed VM. -#seed_hypervisor_libvirt_pool_group: - -############################################################################### -# Seed hypervisor libvirt network configuration. - -# List of libvirt networks for the seed hypervisor. -#seed_hypervisor_libvirt_networks: - -############################################################################### -# Seed hypervisor sysctl configuration. - -# Dict of sysctl parameters to set. -#seed_hypervisor_sysctl_parameters: - -############################################################################### -# Seed hypervisor user configuration. - -# List of users to create. This should be in a format accepted by the -# singleplatform-eng.users role. -#seed_hypervisor_users: - -############################################################################### -# Dummy variable to allow Ansible to accept this file. -workaround_ansible_issue_8743: yes diff --git a/etc/kayobe/environments/aufn-ceph/seed-vm.yml b/etc/kayobe/environments/aufn-ceph/seed-vm.yml index 3254aa58e..2b697f9af 100644 --- a/etc/kayobe/environments/aufn-ceph/seed-vm.yml +++ b/etc/kayobe/environments/aufn-ceph/seed-vm.yml @@ -53,7 +53,3 @@ seed_vm_vcpus: 1 # dev: eth1 # #seed_vm_interfaces: - -############################################################################### -# Dummy variable to allow Ansible to accept this file. -workaround_ansible_issue_8743: yes diff --git a/etc/kayobe/environments/aufn-ceph/storage.yml b/etc/kayobe/environments/aufn-ceph/storage.yml index 5b4ab8670..aa74fa1b1 100644 --- a/etc/kayobe/environments/aufn-ceph/storage.yml +++ b/etc/kayobe/environments/aufn-ceph/storage.yml @@ -1,69 +1,4 @@ --- -############################################################################### -# Storage node configuration. - -# User with which to access the storages via SSH during bootstrap, in order -# to setup the Kayobe user account. Default is {{ os_distribution }}. -#storage_bootstrap_user: - -############################################################################### -# Storage network interface configuration. - -# List of networks to which storage nodes are attached. -#storage_network_interfaces: - -# List of default networks to which storage nodes are attached. -#storage_default_network_interfaces: - -# List of extra networks to which storage nodes are attached. -#storage_extra_network_interfaces: - -# Whether this host requires access to Swift networks. -#storage_needs_swift_network: - -#storage_needs_swift_replication_network: - -############################################################################### -# Storage node BIOS configuration. - -# Dict of storage BIOS options. Format is same as that used by stackhpc.drac -# role. -#storage_bios_config: - -# Dict of default storage BIOS options. Format is same as that used by -# stackhpc.drac role. -#storage_bios_config_default: - -# Dict of additional storage BIOS options. Format is same as that used by -# stackhpc.drac role. -#storage_bios_config_extra: - -############################################################################### -# Storage node RAID configuration. - -# List of storage RAID volumes. Format is same as that used by stackhpc.drac -# role. -#storage_raid_config: - -# List of default storage RAID volumes. Format is same as that used by -# stackhpc.drac role. -#storage_raid_config_default: - -# List of additional storage RAID volumes. Format is same as that used by -# stackhpc.drac role. -#storage_raid_config_extra: - -############################################################################### -# Storage node software RAID configuration. - -# List of software RAID arrays. See mrlesmithjr.mdadm role for format. -#storage_mdadm_arrays: - -############################################################################### -# Storage node encryption configuration. - -# List of block devices to encrypt. See stackhpc.luks role for format. -#storage_luks_devices: ############################################################################### # Storage node LVM configuration. @@ -107,20 +42,3 @@ storage_lvm_groups: [] # Filesystem for docker volumes LVM backing volume. ext4 allows for shrinking. #storage_lvm_group_data_lv_docker_volumes_fs: - -############################################################################### -# Storage node sysctl configuration. - -# Dict of sysctl parameters to set. -#storage_sysctl_parameters: - -############################################################################### -# Storage node user configuration. - -# List of users to create. This should be in a format accepted by the -# singleplatform-eng.users role. -#storage_users: - -############################################################################### -# Dummy variable to allow Ansible to accept this file. -workaround_ansible_issue_8743: yes From d8e585d9865a188dbcfdb9923b549169f042f671 Mon Sep 17 00:00:00 2001 From: Scott Davidson Date: Thu, 17 Nov 2022 11:52:47 +0000 Subject: [PATCH 07/33] Update aufn env config --- etc/kayobe/ansible/ceph-config.yml | 88 ------ .../aufn-ceph/a-universe-from-nothing.sh | 18 +- etc/kayobe/environments/aufn-ceph/cephadm.yml | 59 +++- .../environments/aufn-ceph/deploy-pulp.sh | 51 ---- .../overcloud/ansible-python-interpreter | 3 - .../ansible-python-interpreter | 3 - .../seed/ansible-python-interpreter | 3 - .../environments/aufn-ceph/inventory/groups | 88 +----- etc/kayobe/environments/aufn-ceph/ipa.yml | 22 -- etc/kayobe/environments/aufn-ceph/kolla.yml | 255 +----------------- .../environments/aufn-ceph/kolla/globals.yml | 4 - .../environments/aufn-ceph/networks.yml | 39 +-- .../environments/aufn-ceph/overcloud.yml | 13 - .../aufn-ceph/seed-hypervisor.yml | 12 - etc/kayobe/environments/aufn-ceph/seed-vm.yml | 46 ---- .../environments/aufn-ceph/stackhpc.yml | 8 - etc/kayobe/inventory/groups | 2 +- 17 files changed, 60 insertions(+), 654 deletions(-) delete mode 100644 etc/kayobe/ansible/ceph-config.yml delete mode 100755 etc/kayobe/environments/aufn-ceph/deploy-pulp.sh delete mode 100644 etc/kayobe/environments/aufn-ceph/inventory/group_vars/overcloud/ansible-python-interpreter delete mode 100644 etc/kayobe/environments/aufn-ceph/inventory/group_vars/seed-hypervisor/ansible-python-interpreter delete mode 100644 etc/kayobe/environments/aufn-ceph/inventory/group_vars/seed/ansible-python-interpreter diff --git a/etc/kayobe/ansible/ceph-config.yml b/etc/kayobe/ansible/ceph-config.yml deleted file mode 100644 index 8c165445d..000000000 --- a/etc/kayobe/ansible/ceph-config.yml +++ /dev/null @@ -1,88 +0,0 @@ ---- -- name: Configure Ceph - any_errors_fatal: True - gather_facts: True - hosts: storage - vars: - cephadm_ceph_pools: - - backup - - images - - vms - - volumes - cephadm_ceph_users: - - client.glance mon 'profile rbd' osd 'profile rbd pool=images' mgr 'profile rbd pool=images' -o /var/run/ceph/ceph.client.glance.keyring - - client.cinder mon 'profile rbd' osd 'profile rbd pool=volumes, profile rbd pool=vms, profile rbd-read-only pool=images' mgr 'profile rbd pool=volumes, profile rbd pool=vms' -o /var/run/ceph/ceph.client.cinder.keyring - - client.cinder-backup mon 'profile rbd' osd 'profile rbd pool=backups' mgr 'profile rbd pool=backups' -o /var/run/ceph/ceph.client.cinder-backup.keyring - cephadm_kolla_ceph_services: - - { name: "cinder/cinder-volume", keyring: "ceph.client.cinder.keyring" } - - { name: "cinder/cinder-backup", keyring: "ceph.client.cinder.keyring" } - - { name: "cinder/cinder-backup", keyring: "ceph.client.cinder-backup.keyring" } - - { name: "glance", keyring: "ceph.client.glance.keyring" } - - { name: "nova", keyring: "ceph.client.cinder.keyring" } - tasks: - - block: - # Create pools and users. - - name: Create and initialise pools for OpenStack services - command: - cmd: > - cephadm shell -- - ceph osd pool create {{ item }} - with_items: "{{ cephadm_ceph_pools }}" - become: true - - - name: Create users for OpenStack services - command: - cmd: > - cephadm shell -- - ceph auth get-or-create {{ item }} - become: true - with_items: "{{ cephadm_ceph_users }}" - - - name: Check ceph health - command: - cmd: cephadm shell -- ceph health detail - become: True - changed_when: false - - # Create config files. - - name: Ensure required kolla config directories exist - file: - state: directory - name: "{{ kayobe_env_config_path }}/kolla/config/{{ item.name }}" - mode: 0755 - with_items: "{{ cephadm_kolla_ceph_services }}" - delegate_to: localhost - - - name: copy ceph.conf to enabled services - fetch: - src: "/etc/ceph/ceph.conf" - dest: "{{ kayobe_env_config_path }}/kolla/config/{{ item.name }}/ceph.conf" - flat: true - with_items: "{{ cephadm_kolla_ceph_services }}" - - - name: remove tabs in ceph.conf - replace: - path: "{{ kayobe_env_config_path }}/kolla/config/{{ item.name }}/ceph.conf" - regexp: "^\t" - with_items: "{{ cephadm_kolla_ceph_services }}" - delegate_to: localhost - - - name: Get cluster fsid - command: - cmd: "cephadm shell -- ceph fsid" - become: true - register: cephadm_fsid_current - changed_when: false - - - name: copy keyrings to enabled services - fetch: - src: "/var/run/ceph/{{ cephadm_fsid_current.stdout }}/{{ item.keyring }}" - dest: "{{ kayobe_env_config_path }}/kolla/config/{{ item.name }}/{{ item.keyring }}" - owner: "{{ lookup('env', 'USER') }}" - group: "{{ lookup('env', 'USER') }}" - flat: true - with_items: "{{ cephadm_kolla_ceph_services }}" - become: true - - run_once: true - delegate_to: "{{ groups['mons'][0] }}" diff --git a/etc/kayobe/environments/aufn-ceph/a-universe-from-nothing.sh b/etc/kayobe/environments/aufn-ceph/a-universe-from-nothing.sh index af5c993d7..89909b30c 100755 --- a/etc/kayobe/environments/aufn-ceph/a-universe-from-nothing.sh +++ b/etc/kayobe/environments/aufn-ceph/a-universe-from-nothing.sh @@ -6,8 +6,8 @@ set -eu BASE_PATH=~ -KAYOBE_BRANCH=stackhpc/wallaby -KAYOBE_CONFIG_BRANCH=stackhpc/wallaby +KAYOBE_BRANCH=stackhpc/yoga +KAYOBE_CONFIG_BRANCH=stackhpc/yoga KAYOBE_ENVIRONMENT=aufn-ceph # FIXME: Work around lack of DNS on SMS lab. @@ -67,21 +67,14 @@ source kayobe-env --environment $KAYOBE_ENVIRONMENT # Configure host networking (bridge, routes & firewall) $KAYOBE_CONFIG_PATH/environments/$KAYOBE_ENVIRONMENT/configure-local-networking.sh -# Deploy Pulp -$KAYOBE_CONFIG_PATH/environments/$KAYOBE_ENVIRONMENT/deploy-pulp.sh - # Bootstrap the Ansible control host. kayobe control host bootstrap # Sync package & container repositories. kayobe playbook run $KAYOBE_CONFIG_PATH/ansible/pulp-repo-sync.yml kayobe playbook run $KAYOBE_CONFIG_PATH/ansible/pulp-repo-publish.yml - -# NOTE: Building Ubuntu containers locally for now. -# if $(which dnf 2>/dev/null >/dev/null); then kayobe playbook run $KAYOBE_CONFIG_PATH/ansible/pulp-container-sync.yml kayobe playbook run $KAYOBE_CONFIG_PATH/ansible/pulp-container-publish.yml -# fi # Configure the seed hypervisor host. kayobe seed hypervisor host configure @@ -92,12 +85,6 @@ kayobe seed vm provision # Configure the seed host, and deploy a local registry. kayobe seed host configure -# NOTE: Building Ubuntu containers locally for now. -# if ! $(which dnf 2>/dev/null >/dev/null); then -# kayobe seed container image build --push -# kayobe overcloud container image build --push -# fi - # Deploy the seed services. kayobe seed service deploy @@ -118,7 +105,6 @@ kayobe overcloud hardware inspect kayobe overcloud provision kayobe overcloud host configure kayobe playbook run $KAYOBE_CONFIG_PATH/ansible/cephadm.yml -kayobe playbook run $KAYOBE_CONFIG_PATH/ansible/ceph-config.yml kayobe overcloud container image pull kayobe overcloud service deploy source $KOLLA_CONFIG_PATH/public-openrc.sh diff --git a/etc/kayobe/environments/aufn-ceph/cephadm.yml b/etc/kayobe/environments/aufn-ceph/cephadm.yml index 80006c4dc..b4cb2ca0d 100644 --- a/etc/kayobe/environments/aufn-ceph/cephadm.yml +++ b/etc/kayobe/environments/aufn-ceph/cephadm.yml @@ -1,10 +1,11 @@ --- -# Networking -cephadm_public_interface: "{{ storage_net_name | net_interface }}" -cephadm_public_network: "{{ storage_net_name | net_cidr }}" -cephadm_cluster_interface: "{{ storage_mgmt_net_name | net_interface }}" -cephadm_cluster_network: "{{ storage_mgmt_net_name | net_cidr }}" -# OSDs +############################################################################### +# Cephadm deployment configuration. + +# Ceph container image. +cephadm_image: "quay.io/ceph/ceph:v16.2.5" + +# Ceph OSD specification. cephadm_osd_spec: service_type: osd service_id: osd_spec_default @@ -12,3 +13,49 @@ cephadm_osd_spec: host_pattern: "*" data_devices: all: true + +############################################################################### +# Ceph post-deployment configuration. + +# List of Ceph erasure coding profiles. See stackhpc.cephadm.ec_profiles role +# for format. +cephadm_ec_profiles: [] + +# List of Ceph CRUSH rules. See stackhpc.cephadm.crush_rules role for format. +cephadm_crush_rules: [] + +# List of Ceph pools. See stackhpc.cephadm.pools role for format. +cephadm_pools: + - name: backups + application: rbd + state: present + - name: images + application: rbd + state: present + - name: volumes + application: rbd + state: present + - name: vms + application: rbd + state: present + +# List of Cephx keys. See stackhpc.cephadm.keys role for format. +cephadm_keys: + - name: client.cinder + caps: + mon: "profile rbd" + osd: "profile rbd pool=volumes, profile rbd pool=vms, profile rbd-read-only pool=images" + mgr: "profile rbd pool=volumes, profile rbd pool=vms" + state: present + - name: client.cinder-backup + caps: + mon: "profile rbd" + osd: "profile rbd pool=volumes, profile rbd pool=backups" + mgr: "profile rbd pool=volumes, profile rbd pool=backups" + state: present + - name: client.glance + caps: + mon: "profile rbd" + osd: "profile rbd pool=images" + mgr: "profile rbd pool=images" + state: present diff --git a/etc/kayobe/environments/aufn-ceph/deploy-pulp.sh b/etc/kayobe/environments/aufn-ceph/deploy-pulp.sh deleted file mode 100755 index 970dd299c..000000000 --- a/etc/kayobe/environments/aufn-ceph/deploy-pulp.sh +++ /dev/null @@ -1,51 +0,0 @@ -#!/bin/bash - -set -e - -# Seed hypervisor provision_oc IP. -pulp_ip=192.168.33.4 - -if $(which dnf >/dev/null 2>&1); then - CONTAINER=podman - if ! type podman > /dev/null 2>&1; then - sudo dnf -y install podman - fi -else - CONTAINER="sudo docker" - if ! type docker > /dev/null 2>&1; then - sudo apt update - sudo apt -y install docker.io - fi -fi - -if $CONTAINER container inspect pulp > /dev/null 2>&1; then - echo "Pulp already deployed" - exit -fi - -mkdir -p ~/pulp -cd ~/pulp - -mkdir -p settings pulp_storage pgsql containers -echo "CONTENT_ORIGIN='http://${pulp_ip}:8080' -ANSIBLE_API_HOSTNAME='http://${pulp_ip}:8080' -ANSIBLE_CONTENT_HOSTNAME='http://${pulp_ip}:8080/pulp/content' -TOKEN_AUTH_DISABLED=True" > settings/settings.py - -$CONTAINER run --detach \ - --publish 8080:80 \ - --name pulp \ - --volume "$(pwd)/settings":/etc/pulp:Z \ - --volume "$(pwd)/pulp_storage":/var/lib/pulp:Z \ - --volume "$(pwd)/pgsql":/var/lib/pgsql:Z \ - --volume "$(pwd)/containers":/var/lib/containers:Z \ - --device /dev/fuse \ - --add-host pulp-server.internal.sms-cloud:10.205.3.187 \ - docker.io/pulp/pulp - -until curl --fail http://localhost:8080/pulp/api/v3/status/ > /dev/null 2>&1; do - sleep 2 -done - -$CONTAINER exec pulp pulpcore-manager reset-admin-password --password 9e4bfa04-9d9d-493d-9473-ba92e4361dae -echo "Pulp successfully deployed" diff --git a/etc/kayobe/environments/aufn-ceph/inventory/group_vars/overcloud/ansible-python-interpreter b/etc/kayobe/environments/aufn-ceph/inventory/group_vars/overcloud/ansible-python-interpreter deleted file mode 100644 index 54abbf23c..000000000 --- a/etc/kayobe/environments/aufn-ceph/inventory/group_vars/overcloud/ansible-python-interpreter +++ /dev/null @@ -1,3 +0,0 @@ ---- -# Use a virtual environment for remote operations. -ansible_python_interpreter: "{{ virtualenv_path }}/kayobe/bin/python" diff --git a/etc/kayobe/environments/aufn-ceph/inventory/group_vars/seed-hypervisor/ansible-python-interpreter b/etc/kayobe/environments/aufn-ceph/inventory/group_vars/seed-hypervisor/ansible-python-interpreter deleted file mode 100644 index 54abbf23c..000000000 --- a/etc/kayobe/environments/aufn-ceph/inventory/group_vars/seed-hypervisor/ansible-python-interpreter +++ /dev/null @@ -1,3 +0,0 @@ ---- -# Use a virtual environment for remote operations. -ansible_python_interpreter: "{{ virtualenv_path }}/kayobe/bin/python" diff --git a/etc/kayobe/environments/aufn-ceph/inventory/group_vars/seed/ansible-python-interpreter b/etc/kayobe/environments/aufn-ceph/inventory/group_vars/seed/ansible-python-interpreter deleted file mode 100644 index 54abbf23c..000000000 --- a/etc/kayobe/environments/aufn-ceph/inventory/group_vars/seed/ansible-python-interpreter +++ /dev/null @@ -1,3 +0,0 @@ ---- -# Use a virtual environment for remote operations. -ansible_python_interpreter: "{{ virtualenv_path }}/kayobe/bin/python" diff --git a/etc/kayobe/environments/aufn-ceph/inventory/groups b/etc/kayobe/environments/aufn-ceph/inventory/groups index 0485b6ea9..526c117a0 100644 --- a/etc/kayobe/environments/aufn-ceph/inventory/groups +++ b/etc/kayobe/environments/aufn-ceph/inventory/groups @@ -1,91 +1,5 @@ # Kayobe groups inventory file. This file should generally not be modified. -# If declares the top-level groups and sub-groups. - -############################################################################### -# Seed groups. - -[seed] -# Empty group to provide declaration of seed group. - -[seed-hypervisor] -# Empty group to provide declaration of seed-hypervisor group. - -[container-image-builders:children] -# Build container images on the seed by default. -seed - -############################################################################### -# Overcloud groups. - -[controllers] -# Empty group to provide declaration of controllers group. - -[network:children] -# Add controllers to network group by default for backwards compatibility, -# although they could be separate hosts. -controllers - -[monitoring] -# Empty group to provide declaration of monitoring group. - -[storage] -# Empty group to provide declaration of storage group. - -[compute] -# Empty group to provide declaration of compute group. - -[overcloud:children] -controllers -network -monitoring -storage -compute - -############################################################################### -# Service groups. - -[docker:children] -# Hosts in this group will have Docker installed. -seed -controllers -network -monitoring -compute - -[docker-registry:children] -# Hosts in this group will have a Docker Registry deployed. This group should -# generally contain only a single host, to avoid deploying multiple independent -# registries which may become unsynchronized. -seed - -[ntp:children] -# Kayobe will configure Chrony on members of this group. -seed -seed-hypervisor -overcloud - -############################################################################### -# Baremetal compute node groups. - -[baremetal-compute] -# Empty group to provide declaration of baremetal-compute group. - -############################################################################### -# Networking groups. - -[mgmt-switches] -# Empty group to provide declaration of mgmt-switches group. - -[ctl-switches] -# Empty group to provide declaration of ctl-switches group. - -[hs-switches] -# Empty group to provide declaration of hs-switches group. - -[switches:children] -mgmt-switches -ctl-switches -hs-switches +# It declares the top-level groups and sub-groups. ############################################################################### # Ceph groups diff --git a/etc/kayobe/environments/aufn-ceph/ipa.yml b/etc/kayobe/environments/aufn-ceph/ipa.yml index 6aef4f7b7..65616cfe1 100644 --- a/etc/kayobe/environments/aufn-ceph/ipa.yml +++ b/etc/kayobe/environments/aufn-ceph/ipa.yml @@ -4,32 +4,10 @@ ############################################################################### # Ironic Python Agent (IPA) images configuration. -# Suffix of upstream Ironic deployment image files. Default is based on -# {{ openstack_branch }}. -#ipa_images_upstream_url_suffix: - -# Name of Ironic deployment kernel image to register in Glance. -#ipa_images_kernel_name: - # URL of Ironic deployment kernel image to download. # yamllint disable-line rule:line-length ipa_kernel_upstream_url: "https://tarballs.openstack.org/ironic-python-agent/tinyipa/files/tinyipa{{ ipa_images_upstream_url_suffix }}.vmlinuz" -# URL of checksum of Ironic deployment kernel image. -#ipa_kernel_checksum_url: - -# Algorithm of checksum of Ironic deployment kernel image. -#ipa_kernel_checksum_algorithm: - -# Name of Ironic deployment ramdisk image to register in Glance. -#ipa_images_ramdisk_name: - # URL of Ironic deployment ramdisk image to download. # yamllint disable-line rule:line-length ipa_ramdisk_upstream_url: "https://tarballs.openstack.org/ironic-python-agent/tinyipa/files/tinyipa{{ ipa_images_upstream_url_suffix }}.gz" - -# URL of checksum of Ironic deployment ramdisk image. -#ipa_ramdisk_checksum_url: - -# Algorithm of checksum of Ironic deployment ramdisk image. -#ipa_ramdisk_checksum_algorithm: diff --git a/etc/kayobe/environments/aufn-ceph/kolla.yml b/etc/kayobe/environments/aufn-ceph/kolla.yml index 3d52dd3a1..292b701d9 100644 --- a/etc/kayobe/environments/aufn-ceph/kolla.yml +++ b/etc/kayobe/environments/aufn-ceph/kolla.yml @@ -4,264 +4,13 @@ ############################################################################### # Kolla-ansible inventory configuration. -# Full custom seed inventory contents. -#kolla_seed_inventory_custom: - -# List of names of default host variables to pass through from kayobe hosts to -# the kolla-ansible seed host, if set. See also -# kolla_seed_inventory_pass_through_host_vars_map. -#kolla_seed_inventory_pass_through_host_vars_default: - -# List of names of additional host variables to pass through from kayobe hosts -# to the kolla-ansible seed host, if set. See also -# kolla_seed_inventory_pass_through_host_vars_map. -#kolla_seed_inventory_pass_through_host_vars_extra: - -# List of names of host variables to pass through from kayobe hosts to -# the kolla-ansible seed host, if set. See also -# kolla_seed_inventory_pass_through_host_vars_map. -#kolla_seed_inventory_pass_through_host_vars: - -# Dict mapping names of default variables in -# kolla_seed_inventory_pass_through_host_vars to the variable to use in -# kolla-ansible. If a variable name is not in this mapping the kayobe name is -# used. -#kolla_seed_inventory_pass_through_host_vars_map_default: - -# Dict mapping names of extra variables in -# kolla_seed_inventory_pass_through_host_vars to the variable to use in -# kolla-ansible. If a variable name is not in this mapping the kayobe name is -# used. -#kolla_seed_inventory_pass_through_host_vars_map_extra: - -# Dict mapping names of variables in -# kolla_seed_inventory_pass_through_host_vars to the variable to use in -# kolla-ansible. If a variable name is not in this mapping the kayobe name is -# used. -#kolla_seed_inventory_pass_through_host_vars_map: - -# Custom overcloud inventory containing a mapping from top level groups to -# hosts. -#kolla_overcloud_inventory_custom_top_level: - -# Custom overcloud inventory containing a mapping from components to top level -# groups. -#kolla_overcloud_inventory_custom_components: - # Custom overcloud inventory containing a mapping from services to components. kolla_overcloud_inventory_custom_services: "{{ lookup('template', kayobe_env_config_path ~ '/kolla/inventory/overcloud-services.j2') }}" -# Full custom overcloud inventory contents. By default this will be the -# concatenation of the top level, component, and service inventories. -#kolla_overcloud_inventory_custom: - # Don't give storage nodes to kolla-ansible - we're using Ceph-ansible. -kolla_overcloud_inventory_storage_groups: [] - -# Dict mapping from kolla-ansible groups to kayobe groups and variables. Each -# item is a dict with the following items: -# * groups: A list of kayobe ansible groups to map to this kolla-ansible group. -# * vars: A dict mapping variable names to values for hosts in this -# kolla-ansible group. -#kolla_overcloud_inventory_top_level_group_map: - -# List of names of top level kolla-ansible groups. Any of these groups which -# have no hosts mapped to them will be provided with an empty group definition. -#kolla_overcloud_inventory_kolla_top_level_groups: - -# List of names of default host variables to pass through from kayobe hosts to -# kolla-ansible hosts, if set. See also -# kolla_overcloud_inventory_pass_through_host_vars_map. -#kolla_overcloud_inventory_pass_through_host_vars_default: - -# List of names of additional host variables to pass through from kayobe hosts -# to kolla-ansible hosts, if set. See also -# kolla_overcloud_inventory_pass_through_host_vars_map. -#kolla_overcloud_inventory_pass_through_host_vars_extra: - -# List of names of host variables to pass through from kayobe hosts to -# kolla-ansible hosts, if set. See also -# kolla_overcloud_inventory_pass_through_host_vars_map. -#kolla_overcloud_inventory_pass_through_host_vars: - -# Dict mapping names of default variables in -# kolla_overcloud_inventory_pass_through_host_vars to the variable to use in -# kolla-ansible. If a variable name is not in this mapping the kayobe name is -# used. -#kolla_overcloud_inventory_pass_through_host_vars_map_default: - -# Dict mapping names of additional variables in -# kolla_overcloud_inventory_pass_through_host_vars to the variable to use in -# kolla-ansible. If a variable name is not in this mapping the kayobe name is -# used. -#kolla_overcloud_inventory_pass_through_host_vars_map_extra: - -# Dict mapping names of variables in -# kolla_overcloud_inventory_pass_through_host_vars to the variable to use in -# kolla-ansible. If a variable name is not in this mapping the kayobe name is -# used. -#kolla_overcloud_inventory_pass_through_host_vars_map: +# kolla_overcloud_inventory_storage_groups: [] ############################################################################### # Kolla feature flag configuration. - -#kolla_enable_aodh: -#kolla_enable_barbican: -#kolla_enable_blazar: -#kolla_enable_ceilometer: -#kolla_enable_ceilometer_horizon_policy_file: -#kolla_enable_ceilometer_ipmi: -#kolla_enable_cells: -#kolla_enable_central_logging: -#kolla_enable_chrony: kolla_enable_cinder: true -#kolla_enable_cinder_backend_hnas_nfs: -#kolla_enable_cinder_backend_iscsi: -#kolla_enable_cinder_backend_lvm: -#kolla_enable_cinder_backend_nfs: -#kolla_enable_cinder_backend_quobyte: -#kolla_enable_cinder_backend_zfssa_iscsi: -#kolla_enable_cinder_backup: -#kolla_enable_cinder_horizon_policy_file: -#kolla_enable_cloudkitty: -#kolla_enable_collectd: -#kolla_enable_container_healthchecks: -#kolla_enable_cyborg: -#kolla_enable_designate: -#kolla_enable_destroy_images: -#kolla_enable_elasticsearch: -#kolla_enable_elasticsearch_curator: -#kolla_enable_etcd: -#kolla_enable_external_mariadb_load_balancer: -#kolla_enable_fluentd: -#kolla_enable_freezer: -#kolla_enable_glance: -#kolla_enable_glance_horizon_policy_file: -#kolla_enable_glance_image_cache: -#kolla_enable_gnocchi: -#kolla_enable_gnocchi_statsd: -#kolla_enable_grafana: -#kolla_enable_hacluster: -#kolla_enable_haproxy: -#kolla_enable_haproxy_memcached: -#kolla_enable_heat: -#kolla_enable_heat_horizon_policy_file: -#kolla_enable_horizon: -#kolla_enable_horizon_blazar: -#kolla_enable_horizon_cloudkitty: -#kolla_enable_horizon_designate: -#kolla_enable_horizon_freezer: -#kolla_enable_horizon_heat: -#kolla_enable_horizon_ironic: -#kolla_enable_horizon_magnum: -#kolla_enable_horizon_manila: -#kolla_enable_horizon_masakari: -#kolla_enable_horizon_mistral: -#kolla_enable_horizon_monasca: -#kolla_enable_horizon_murano: -#kolla_enable_horizon_neutron_vpnaas: -#kolla_enable_horizon_octavia: -#kolla_enable_horizon_sahara: -#kolla_enable_horizon_senlin: -#kolla_enable_horizon_solum: -#kolla_enable_horizon_tacker: -#kolla_enable_horizon_trove: -#kolla_enable_horizon_vitrage: -#kolla_enable_horizon_watcher: -#kolla_enable_horizon_zun: -#kolla_enable_influxdb: -#kolla_enable_ironic: -#kolla_enable_ironic_ipxe: -#kolla_enable_ironic_neutron_agent: -#kolla_enable_ironic_pxe_uefi: -#kolla_enable_iscsid: -#kolla_enable_kafka: -#kolla_enable_keepalived: -#kolla_enable_keystone: -#kolla_enable_keystone_federation: -#kolla_enable_keystone_horizon_policy_file: -#kolla_enable_kibana: -#kolla_enable_kuryr: -#kolla_enable_magnum: -#kolla_enable_manila: -#kolla_enable_manila_backend_cephfs_native: -#kolla_enable_manila_backend_cephfs_nfs: -#kolla_enable_manila_backend_generic: -#kolla_enable_manila_backend_glusterfs_nfs: -#kolla_enable_manila_backend_hnas: -#kolla_enable_mariabackup: -#kolla_enable_mariadb: -#kolla_enable_masakari: -#kolla_enable_memcached: -#kolla_enable_mistral: -#kolla_enable_monasca: -#kolla_enable_multipathd: -#kolla_enable_murano: -#kolla_enable_neutron: -#kolla_enable_neutron_agent_ha: -#kolla_enable_neutron_bgp_dragent: -#kolla_enable_neutron_dvr: -#kolla_enable_neutron_horizon_policy_file: -#kolla_enable_neutron_infoblox_ipam_agent: -#kolla_enable_neutron_metering: -#kolla_enable_neutron_mlnx: -#kolla_enable_neutron_port_forwarding: -#kolla_enable_neutron_provider_networks: -#kolla_enable_neutron_qos: -#kolla_enable_neutron_segments: -#kolla_enable_neutron_sfc: -#kolla_enable_neutron_sriov: -#kolla_enable_neutron_trunk: -#kolla_enable_neutron_vpnaas: -#kolla_enable_nova: -#kolla_enable_nova_fake: -#kolla_enable_nova_horizon_policy_file: -#kolla_enable_nova_serialconsole_proxy: -#kolla_enable_nova_ssh: -#kolla_enable_octavia: -#kolla_enable_octavia_driver_agent: -#kolla_enable_openstack_core: -#kolla_enable_openvswitch: -#kolla_enable_osprofiler: -#kolla_enable_outward_rabbitmq: -kolla_enable_ovn: true -#kolla_enable_ovs_dpdk: -#kolla_enable_panko: -#kolla_enable_placement: -#kolla_enable_prometheus: -#kolla_enable_prometheus_alertmanager: -#kolla_enable_prometheus_blackbox_exporter: -#kolla_enable_prometheus_cadvisor: -#kolla_enable_prometheus_ceph_mgr_exporter: -#kolla_enable_prometheus_elasticsearch_exporter: -#kolla_enable_prometheus_haproxy_exporter: -#kolla_enable_prometheus_memcached_exporter: -#kolla_enable_prometheus_mysqld_exporter: -#kolla_enable_prometheus_node_exporter: -#kolla_enable_prometheus_openstack_exporter: -#kolla_enable_prometheus_rabbitmq_exporter: -#kolla_enable_prometheus_server: -#kolla_enable_qdrouterd: -#kolla_enable_rabbitmq: -#kolla_enable_rally: -#kolla_enable_redis: -#kolla_enable_sahara: -#kolla_enable_senlin: -#kolla_enable_skydive: -#kolla_enable_solum: -#kolla_enable_storm: -#kolla_enable_swift: -#kolla_enable_swift_recon: -#kolla_enable_swift_s3api: -#kolla_enable_tacker: -#kolla_enable_telegraf: -#kolla_enable_tempest: -#kolla_enable_trove: -#kolla_enable_trove_singletenant: -#kolla_enable_vitrage: -#kolla_enable_vitrage_prometheus_datasource: -#kolla_enable_vmtp: -#kolla_enable_watcher: -#kolla_enable_zookeeper: -#kolla_enable_zun: - +kolla_enable_ovn: true \ No newline at end of file diff --git a/etc/kayobe/environments/aufn-ceph/kolla/globals.yml b/etc/kayobe/environments/aufn-ceph/kolla/globals.yml index 79b09e0b1..599c7a4b0 100644 --- a/etc/kayobe/environments/aufn-ceph/kolla/globals.yml +++ b/etc/kayobe/environments/aufn-ceph/kolla/globals.yml @@ -8,10 +8,6 @@ nova_compute_virt_type: qemu # processes to one per-service. openstack_service_workers: "1" -# Prevent Docker from manipulating iptables. Docker changes the default policy -# on the FORWARD chain, which prevents traffic from reaching instances. -docker_disable_default_iptables_rules: true - glance_backend_ceph: "yes" cinder_backend_ceph: "yes" nova_backend_ceph: "yes" diff --git a/etc/kayobe/environments/aufn-ceph/networks.yml b/etc/kayobe/environments/aufn-ceph/networks.yml index 6ef780d20..a36993f0a 100644 --- a/etc/kayobe/environments/aufn-ceph/networks.yml +++ b/etc/kayobe/environments/aufn-ceph/networks.yml @@ -4,33 +4,23 @@ ############################################################################### # Network role to network mappings. -# Map all networks to the all-in-one network. - -# Name of the network used for admin access to the overcloud -#admin_oc_net_name: - # Name of the network used by the seed to manage the bare metal overcloud # hosts via their out-of-band management controllers. -#oob_oc_net_name: oob_oc_net_name: mgmt # Name of the network used by the seed to provision the bare metal overcloud # hosts. -#provision_oc_net_name: provision_oc_net_name: provision_oc # Name of the network used by the overcloud hosts to manage the bare metal # compute hosts via their out-of-band management controllers. -#oob_wl_net_name: oob_wl_net_name: mgmt # Name of the network used by the overcloud hosts to provision the bare metal # workload hosts. -#provision_wl_net_name: provision_wl_net_name: provision_wl # Name of the network used to expose the internal OpenStack API endpoints. -#internal_net_name: internal_net_name: internal # List of names of networks used to provide external network access via @@ -38,40 +28,27 @@ internal_net_name: internal # Deprecated name: external_net_name # If external_net_name is defined, external_net_names will default to a list # containing one item, external_net_name. -#external_net_names: external_net_names: - external # Name of the network used to expose the public OpenStack API endpoints. -#public_net_name: public_net_name: public # Name of the network used by Neutron to carry tenant overlay network traffic. -#tunnel_net_name: tunnel_net_name: tunnel # Name of the network used to carry storage data traffic. -#storage_net_name: storage_net_name: storage # Name of the network used to carry storage management traffic. -#storage_mgmt_net_name: storage_mgmt_net_name: storage_mgmt -# Name of the network used to carry swift storage data traffic. -#swift_storage_net_name: - -# Name of the network used to carry swift storage replication traffic. -#swift_storage_replication_net_name: - # Name of the network used to perform hardware introspection on the bare metal # workload hosts. -#inspection_net_name: inspection_net_name: provision_wl # Name of the network used to perform cleaning on the bare metal workload # hosts -#cleaning_net_name: cleaning_net_name: provision_wl ############################################################################### @@ -82,11 +59,6 @@ mgmt_mtu: 1450 # Native VLAN mgmt_physical_network: mgmt -#admin_cidr: 192.168.34.0/24 -#admin_mtu: 1450 -#admin_vlan: 100 -#admin_physical_network: provision - provision_oc_cidr: 192.168.33.0/24 provision_oc_mtu: 1450 provision_oc_inspection_allocation_pool_start: 192.168.33.128 @@ -139,18 +111,9 @@ storage_mgmt_mtu: 1450 storage_mgmt_vlan: 106 storage_mgmt_physical_network: cloud -############################################################################### -# Network routing table configuration. - -# List of IP routing tables. Each item should be a dict containing 'id' and -# 'name' items. These tables will be added to /etc/iproute2/rt_tables. -#network_route_tables: - ############################################################################### # MichaelRigart interfaces configuration. interfaces_pause_time: 5 -############################################################################### -# Dummy variable to allow Ansible to accept this file. -workaround_ansible_issue_8743: yes + diff --git a/etc/kayobe/environments/aufn-ceph/overcloud.yml b/etc/kayobe/environments/aufn-ceph/overcloud.yml index 1414c3a4e..20b307725 100644 --- a/etc/kayobe/environments/aufn-ceph/overcloud.yml +++ b/etc/kayobe/environments/aufn-ceph/overcloud.yml @@ -2,12 +2,6 @@ ############################################################################### # Overcloud configuration. -# Default Ansible group for overcloud hosts. -#overcloud_group_default: - -# List of names of Ansible groups for overcloud hosts. -#overcloud_groups: - # Dict mapping overcloud Ansible group names to lists of hosts in the group. # As a special case, the group 'ignore' can be used to specify hosts that # should not be added to the inventory. @@ -25,10 +19,3 @@ overcloud_group_hosts_map: - storage0 - storage1 - storage2 - -# To prevent some network issues you can choose to disable cloud-init -#disable_cloud_init: - -############################################################################### -# Dummy variable to allow Ansible to accept this file. -workaround_ansible_issue_8743: yes diff --git a/etc/kayobe/environments/aufn-ceph/seed-hypervisor.yml b/etc/kayobe/environments/aufn-ceph/seed-hypervisor.yml index 6b918ab60..b29068339 100644 --- a/etc/kayobe/environments/aufn-ceph/seed-hypervisor.yml +++ b/etc/kayobe/environments/aufn-ceph/seed-hypervisor.yml @@ -1,20 +1,8 @@ --- -############################################################################### -# Seed hypervisor node configuration. - -# User with which to access the seed hypervisor via SSH during bootstrap, in -# order to setup the Kayobe user account. Default is {{ os_distribution }}. -#seed_hypervisor_bootstrap_user: ############################################################################### # Seed hypervisor network interface configuration. -# List of networks to which seed hypervisor nodes are attached. -#seed_hypervisor_network_interfaces: - -# List of default networks to which seed hypervisor nodes are attached. -#seed_hypervisor_default_network_interfaces: - # List of extra networks to which seed hypervisor nodes are attached. seed_hypervisor_extra_network_interfaces: - "{{ provision_wl_net_name }}" diff --git a/etc/kayobe/environments/aufn-ceph/seed-vm.yml b/etc/kayobe/environments/aufn-ceph/seed-vm.yml index 2b697f9af..ddf82f9de 100644 --- a/etc/kayobe/environments/aufn-ceph/seed-vm.yml +++ b/etc/kayobe/environments/aufn-ceph/seed-vm.yml @@ -2,54 +2,8 @@ ############################################################################### # Seed node VM configuration. -# Name of the seed VM. -#seed_vm_name: - # Memory in MB. -#seed_vm_memory_mb: seed_vm_memory_mb: "{{ 4 * 1024 }}" # Number of vCPUs. -#seed_vm_vcpus: seed_vm_vcpus: 1 - -# List of volumes. -#seed_vm_volumes: - -# Name of the storage pool for the seed VM volumes. -#seed_vm_pool: - -# Capacity of the seed VM root volume. -#seed_vm_root_capacity: - -# Format of the seed VM root volume. -#seed_vm_root_format: - -# Base image for the seed VM root volume. Default is -# "https://cloud-images.ubuntu.com/focal/current/focal-server-cloudimg-amd64.img" -# when os_distribution is "ubuntu", or -# "https://cloud.centos.org/centos/8-stream/x86_64/images/CentOS-Stream-GenericCloud-8-20210210.0.x86_64.qcow2" -# otherwise. -#seed_vm_root_image: - -# Capacity of the seed VM data volume. -#seed_vm_data_capacity: - -# Format of the seed VM data volume. -#seed_vm_data_format: - -# List of network interfaces to attach to the seed VM. Format is as accepted by -# the stackhpc.libvirt-vm role's libvirt_vms.interfaces variable. Default is -# one interface for each network in 'network_interfaces'. -# -# Example with one interface connected to a libvirt network called -# 'libvirt-net', and another interface directly plugged into a host device -# called 'eth1': -# -# seed_vm_interfaces: -# - network: libvirt-net -# - type: direct -# source: -# dev: eth1 -# -#seed_vm_interfaces: diff --git a/etc/kayobe/environments/aufn-ceph/stackhpc.yml b/etc/kayobe/environments/aufn-ceph/stackhpc.yml index 88dc1302b..42c4fcb2e 100644 --- a/etc/kayobe/environments/aufn-ceph/stackhpc.yml +++ b/etc/kayobe/environments/aufn-ceph/stackhpc.yml @@ -5,12 +5,6 @@ # Docker namespace to use for Kolla images. Default is 'kolla'. kolla_docker_namespace: stackhpc-dev -############################################################################### -# Seed configuration. - -# Using a Pulp container on the seed-hypervisor. -seed_pulp_container_enabled: false - ############################################################################### # StackHPC configuration. @@ -21,7 +15,5 @@ stackhpc_release_pulp_url: "http://pulp-server.internal.sms-cloud:8080" stackhpc_release_pulp_client_cert: stackhpc_release_pulp_client_key: -pulp_url: http://192.168.33.4:8080 #"http://{{ admin_oc_net_name | net_ip(groups['seed-hypervisor'][0]) }}:80" pulp_username: admin -# NOTE: must match deploy-pulp.sh pulp_password: 9e4bfa04-9d9d-493d-9473-ba92e4361dae diff --git a/etc/kayobe/inventory/groups b/etc/kayobe/inventory/groups index e87ce82c4..e51195309 100644 --- a/etc/kayobe/inventory/groups +++ b/etc/kayobe/inventory/groups @@ -60,7 +60,7 @@ seed controllers network monitoring -#storage +storage compute [docker-registry:children] From d88173ca5128734532da776b0d69b2b9b2b5d95f Mon Sep 17 00:00:00 2001 From: Scott Davidson Date: Thu, 17 Nov 2022 13:14:15 +0000 Subject: [PATCH 08/33] Update more aufn env config --- .../aufn-ceph/a-universe-from-nothing.sh | 14 ++++---- .../kolla/inventory/overcloud-services.j2 | 30 ++++++++-------- etc/kayobe/environments/aufn-ceph/storage.yml | 35 ------------------- 3 files changed, 22 insertions(+), 57 deletions(-) diff --git a/etc/kayobe/environments/aufn-ceph/a-universe-from-nothing.sh b/etc/kayobe/environments/aufn-ceph/a-universe-from-nothing.sh index 89909b30c..eeb3cb61b 100755 --- a/etc/kayobe/environments/aufn-ceph/a-universe-from-nothing.sh +++ b/etc/kayobe/environments/aufn-ceph/a-universe-from-nothing.sh @@ -7,7 +7,7 @@ set -eu BASE_PATH=~ KAYOBE_BRANCH=stackhpc/yoga -KAYOBE_CONFIG_BRANCH=stackhpc/yoga +KAYOBE_CONFIG_BRANCH=yoga-aufn KAYOBE_ENVIRONMENT=aufn-ceph # FIXME: Work around lack of DNS on SMS lab. @@ -70,12 +70,6 @@ $KAYOBE_CONFIG_PATH/environments/$KAYOBE_ENVIRONMENT/configure-local-networking. # Bootstrap the Ansible control host. kayobe control host bootstrap -# Sync package & container repositories. -kayobe playbook run $KAYOBE_CONFIG_PATH/ansible/pulp-repo-sync.yml -kayobe playbook run $KAYOBE_CONFIG_PATH/ansible/pulp-repo-publish.yml -kayobe playbook run $KAYOBE_CONFIG_PATH/ansible/pulp-container-sync.yml -kayobe playbook run $KAYOBE_CONFIG_PATH/ansible/pulp-container-publish.yml - # Configure the seed hypervisor host. kayobe seed hypervisor host configure @@ -92,6 +86,12 @@ kayobe seed service deploy # run configure-local-networking.sh again to re-add routes. $KAYOBE_CONFIG_PATH/environments/$KAYOBE_ENVIRONMENT/configure-local-networking.sh +# Sync package & container repositories. +kayobe playbook run $KAYOBE_CONFIG_PATH/ansible/pulp-repo-sync.yml +kayobe playbook run $KAYOBE_CONFIG_PATH/ansible/pulp-repo-publish.yml +kayobe playbook run $KAYOBE_CONFIG_PATH/ansible/pulp-container-sync.yml +kayobe playbook run $KAYOBE_CONFIG_PATH/ansible/pulp-container-publish.yml + # NOTE: Make sure to use ./tenks, since just ‘tenks’ will install via PyPI. (export TENKS_CONFIG_PATH=$KAYOBE_CONFIG_PATH/environments/$KAYOBE_ENVIRONMENT/tenks.yml && \ export KAYOBE_CONFIG_SOURCE_PATH=$BASE_PATH/src/kayobe-config && \ diff --git a/etc/kayobe/environments/aufn-ceph/kolla/inventory/overcloud-services.j2 b/etc/kayobe/environments/aufn-ceph/kolla/inventory/overcloud-services.j2 index 4572d6af9..0ff09fa3f 100644 --- a/etc/kayobe/environments/aufn-ceph/kolla/inventory/overcloud-services.j2 +++ b/etc/kayobe/environments/aufn-ceph/kolla/inventory/overcloud-services.j2 @@ -96,6 +96,7 @@ neutron [neutron-ovn-metadata-agent:children] compute +network [neutron-bgp-dragent:children] neutron @@ -120,7 +121,7 @@ storage cinder [cinder-volume:children] -cinder +storage # Cloudkitty [cloudkitty-api:children] @@ -211,12 +212,6 @@ monasca-agent [monasca-api:children] monasca -[monasca-grafana:children] -monasca - -[monasca-log-transformer:children] -monasca - [monasca-log-persister:children] monasca @@ -257,10 +252,10 @@ ironic {{ groups['controllers'][0] }} {% endif %} -[ironic-pxe:children] +[ironic-tftp:children] ironic -[ironic-ipxe:children] +[ironic-http:children] ironic # Magnum @@ -345,10 +340,6 @@ compute [cyborg-conductor:children] cyborg -# Panko -[panko-api:children] -panko - # Gnocchi [gnocchi-api:children] gnocchi @@ -502,7 +493,7 @@ storage mariadb [prometheus-haproxy-exporter:children] -haproxy +loadbalancer [prometheus-memcached-exporter:children] memcached @@ -517,6 +508,9 @@ storage [prometheus-alertmanager:children] monitoring +[prometheus-msteams:children] +monitoring + [prometheus-openstack-exporter:children] monitoring @@ -526,6 +520,12 @@ elasticsearch [prometheus-blackbox-exporter:children] monitoring +[prometheus-libvirt-exporter:children] +compute + +[prometheus-msteams:children] +prometheus-alertmanager + [masakari-api:children] control @@ -558,4 +558,4 @@ ovn-database ovn-database [ovn-sb-db:children] -ovn-database +ovn-database \ No newline at end of file diff --git a/etc/kayobe/environments/aufn-ceph/storage.yml b/etc/kayobe/environments/aufn-ceph/storage.yml index aa74fa1b1..827db4e01 100644 --- a/etc/kayobe/environments/aufn-ceph/storage.yml +++ b/etc/kayobe/environments/aufn-ceph/storage.yml @@ -7,38 +7,3 @@ # format. #storage_lvm_groups: storage_lvm_groups: [] - -# Default list of storage volume groups. See mrlesmithjr.manage-lvm role for -# format. -#storage_lvm_groups_default: - -# Additional list of storage volume groups. See mrlesmithjr.manage-lvm role -# for format. -#storage_lvm_groups_extra: - -# Whether a 'data' LVM volume group should exist on storage hosts. By default -# this contains a 'docker-volumes' logical volume for Docker volume storage. It -# will also be used for Docker container and image storage if -# 'docker_storage_driver' is set to 'devicemapper'. Default is true if -# 'docker_storage_driver' is set to 'devicemapper', or false otherwise. -#storage_lvm_group_data_enabled: - -# Storage LVM volume group for data. See mrlesmithjr.manage-lvm role for -# format. -#storage_lvm_group_data: - -# List of disks for use by storage LVM data volume group. Default to an -# invalid value to require configuration. -#storage_lvm_group_data_disks: - -# List of LVM logical volumes for the data volume group. -#storage_lvm_group_data_lvs: - -# Docker volumes LVM backing volume. -#storage_lvm_group_data_lv_docker_volumes: - -# Size of docker volumes LVM backing volume. -#storage_lvm_group_data_lv_docker_volumes_size: - -# Filesystem for docker volumes LVM backing volume. ext4 allows for shrinking. -#storage_lvm_group_data_lv_docker_volumes_fs: From 194d77a6f956b24d33b9224cdf8d9c8b8ae7c9d0 Mon Sep 17 00:00:00 2001 From: Scott Davidson Date: Thu, 17 Nov 2022 13:16:31 +0000 Subject: [PATCH 09/33] Revert cinder volume change to non-default --- .../aufn-ceph/kolla/inventory/overcloud-services.j2 | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/etc/kayobe/environments/aufn-ceph/kolla/inventory/overcloud-services.j2 b/etc/kayobe/environments/aufn-ceph/kolla/inventory/overcloud-services.j2 index 0ff09fa3f..964b3369a 100644 --- a/etc/kayobe/environments/aufn-ceph/kolla/inventory/overcloud-services.j2 +++ b/etc/kayobe/environments/aufn-ceph/kolla/inventory/overcloud-services.j2 @@ -121,7 +121,7 @@ storage cinder [cinder-volume:children] -storage +cinder # Cloudkitty [cloudkitty-api:children] From a4cf881618dd34f05d4e0822023f5a965b341820 Mon Sep 17 00:00:00 2001 From: Scott Davidson Date: Wed, 30 Nov 2022 10:23:37 +0000 Subject: [PATCH 10/33] Update lots of aufn environment config --- etc/kayobe/environments/aufn-ceph/cephadm.yml | 5 +++++ .../seed-hypervisor/network-interfaces | 2 ++ .../environments/aufn-ceph/inventory/groups | 21 +++++++++++++------ .../environments/aufn-ceph/kolla/globals.yml | 3 +++ .../environments/aufn-ceph/networks.yml | 2 +- etc/kayobe/environments/aufn-ceph/neutron.yml | 3 +++ .../environments/aufn-ceph/overcloud.yml | 2 +- .../aufn-ceph/seed-hypervisor.yml | 1 + etc/kayobe/environments/aufn-ceph/tenks.yml | 6 +++--- 9 files changed, 34 insertions(+), 11 deletions(-) create mode 100644 etc/kayobe/environments/aufn-ceph/neutron.yml diff --git a/etc/kayobe/environments/aufn-ceph/cephadm.yml b/etc/kayobe/environments/aufn-ceph/cephadm.yml index b4cb2ca0d..72be305a3 100644 --- a/etc/kayobe/environments/aufn-ceph/cephadm.yml +++ b/etc/kayobe/environments/aufn-ceph/cephadm.yml @@ -5,6 +5,11 @@ # Ceph container image. cephadm_image: "quay.io/ceph/ceph:v16.2.5" +# List of additional cephadm commands to run before deployment +# cephadm_commands: +# - "config set global osd_pool_default_size {{ [3, groups['osds'] | length] | min }}" +# - "config set global osd_pool_default_min_size {{ [3, groups['osds'] | length] | min }}" + # Ceph OSD specification. cephadm_osd_spec: service_type: osd diff --git a/etc/kayobe/environments/aufn-ceph/inventory/group_vars/seed-hypervisor/network-interfaces b/etc/kayobe/environments/aufn-ceph/inventory/group_vars/seed-hypervisor/network-interfaces index 01406f3a6..61d0a836b 100644 --- a/etc/kayobe/environments/aufn-ceph/inventory/group_vars/seed-hypervisor/network-interfaces +++ b/etc/kayobe/environments/aufn-ceph/inventory/group_vars/seed-hypervisor/network-interfaces @@ -14,3 +14,5 @@ provision_wl_bridge_ports: internal_interface: "{{ provision_wl_interface }}.{{ internal_vlan }}" public_interface: "{{ provision_wl_interface }}.{{ public_vlan }}" + +external_interface: "{{ provision_wl_interface }}.{{ external_vlan }}" diff --git a/etc/kayobe/environments/aufn-ceph/inventory/groups b/etc/kayobe/environments/aufn-ceph/inventory/groups index 526c117a0..eba2264e0 100644 --- a/etc/kayobe/environments/aufn-ceph/inventory/groups +++ b/etc/kayobe/environments/aufn-ceph/inventory/groups @@ -4,17 +4,26 @@ ############################################################################### # Ceph groups -[ceph:children] -storage +[storage-ceph] +storage0 +storage1 +storage2 [mons:children] -storage +storage-ceph [mgrs:children] -storage +storage-ceph [osds:children] -storage +storage-ceph [rgws:children] -storage +storage-ceph + + +############################################################################### +# Monitoring groups + +[monitoring:children] +controllers \ No newline at end of file diff --git a/etc/kayobe/environments/aufn-ceph/kolla/globals.yml b/etc/kayobe/environments/aufn-ceph/kolla/globals.yml index 599c7a4b0..c1d90e7ab 100644 --- a/etc/kayobe/environments/aufn-ceph/kolla/globals.yml +++ b/etc/kayobe/environments/aufn-ceph/kolla/globals.yml @@ -11,3 +11,6 @@ openstack_service_workers: "1" glance_backend_ceph: "yes" cinder_backend_ceph: "yes" nova_backend_ceph: "yes" + +# Elasticsearch memory tuning +es_heap_size: 1g diff --git a/etc/kayobe/environments/aufn-ceph/networks.yml b/etc/kayobe/environments/aufn-ceph/networks.yml index a36993f0a..0bdb01ab8 100644 --- a/etc/kayobe/environments/aufn-ceph/networks.yml +++ b/etc/kayobe/environments/aufn-ceph/networks.yml @@ -84,7 +84,7 @@ internal_vlan: 101 internal_physical_network: cloud external_cidr: 192.168.38.0/24 -external_mtu: 1450 +external_mtu: 1400 external_vlan: 102 external_physical_network: cloud diff --git a/etc/kayobe/environments/aufn-ceph/neutron.yml b/etc/kayobe/environments/aufn-ceph/neutron.yml new file mode 100644 index 000000000..c6c658f38 --- /dev/null +++ b/etc/kayobe/environments/aufn-ceph/neutron.yml @@ -0,0 +1,3 @@ +--- +kolla_neutron_ml2_network_vlan_ranges: + - physical_network: "physnet1" \ No newline at end of file diff --git a/etc/kayobe/environments/aufn-ceph/overcloud.yml b/etc/kayobe/environments/aufn-ceph/overcloud.yml index 20b307725..1530c401d 100644 --- a/etc/kayobe/environments/aufn-ceph/overcloud.yml +++ b/etc/kayobe/environments/aufn-ceph/overcloud.yml @@ -15,7 +15,7 @@ overcloud_group_hosts_map: - compute0 - compute1 - compute2 - storage: + storage-ceph: - storage0 - storage1 - storage2 diff --git a/etc/kayobe/environments/aufn-ceph/seed-hypervisor.yml b/etc/kayobe/environments/aufn-ceph/seed-hypervisor.yml index b29068339..3b351675a 100644 --- a/etc/kayobe/environments/aufn-ceph/seed-hypervisor.yml +++ b/etc/kayobe/environments/aufn-ceph/seed-hypervisor.yml @@ -8,4 +8,5 @@ seed_hypervisor_extra_network_interfaces: - "{{ provision_wl_net_name }}" - "{{ internal_net_name }}" - "{{ public_net_name }}" + - "{{ external_net_names[0] }}" diff --git a/etc/kayobe/environments/aufn-ceph/tenks.yml b/etc/kayobe/environments/aufn-ceph/tenks.yml index 56ead9402..9b0e9e9f4 100644 --- a/etc/kayobe/environments/aufn-ceph/tenks.yml +++ b/etc/kayobe/environments/aufn-ceph/tenks.yml @@ -58,19 +58,19 @@ specs: resource_class: test-rc network_interface: noop - type: storage - count: 1 + count: 3 node_name_prefix: storage ironic_config: resource_class: test-rc network_interface: noop - type: compute - count: 3 + count: 2 node_name_prefix: compute ironic_config: resource_class: test-rc network_interface: noop - type: baremetal - count: 1 + count: 0 node_name_prefix: baremetal ipmi_address: 192.168.33.4 From 405d8b95832f836878f3d355ab10569c87b42cfc Mon Sep 17 00:00:00 2001 From: Scott Davidson Date: Wed, 30 Nov 2022 10:25:15 +0000 Subject: [PATCH 11/33] Ignore aufn env keyring files --- .gitignore | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/.gitignore b/.gitignore index 713cead5c..05cbc5283 100644 --- a/.gitignore +++ b/.gitignore @@ -41,3 +41,11 @@ etc/kayobe/inventory/group_vars/seed/ansible-host # Ignore kolla configuration. etc/kolla + +# Ignore ceph generated config in AUFN env +etc/kayobe/environments/aufn-ceph/kolla/config/glance/ceph.conf +etc/kayobe/environments/aufn-ceph/kolla/config/glance/ceph.client.glance.keyring +etc/kayobe/environments/aufn-ceph/kolla/config/cinder/ceph.conf +etc/kayobe/environments/aufn-ceph/kolla/config/cinder/ceph.client.glance.keyring +etc/kayobe/environments/aufn-ceph/kolla/config/nova/ceph.conf +etc/kayobe/environments/aufn-ceph/kolla/config/nova/ceph.client.glance.keyring \ No newline at end of file From 95d15696e9808d3fa152946a25ea2201dbcf54a0 Mon Sep 17 00:00:00 2001 From: Scott Davidson Date: Wed, 30 Nov 2022 10:27:17 +0000 Subject: [PATCH 12/33] WIP end-to-end script --- .../aufn-ceph/a-universe-from-nothing.sh | 216 +++++++++++------- 1 file changed, 129 insertions(+), 87 deletions(-) diff --git a/etc/kayobe/environments/aufn-ceph/a-universe-from-nothing.sh b/etc/kayobe/environments/aufn-ceph/a-universe-from-nothing.sh index eeb3cb61b..6c4df79b2 100755 --- a/etc/kayobe/environments/aufn-ceph/a-universe-from-nothing.sh +++ b/etc/kayobe/environments/aufn-ceph/a-universe-from-nothing.sh @@ -1,9 +1,13 @@ #!/bin/bash +########################################### +# STACKHPC-KAYOBE-CONFIG AUFN ENV VERSION # +########################################### + # Cheat script for a full deployment. # This should be used for testing only. -set -eu +# set -eu BASE_PATH=~ KAYOBE_BRANCH=stackhpc/yoga @@ -11,108 +15,146 @@ KAYOBE_CONFIG_BRANCH=yoga-aufn KAYOBE_ENVIRONMENT=aufn-ceph # FIXME: Work around lack of DNS on SMS lab. +PELICAN_HOST="10.0.0.34 pelican pelican.service.compute.sms-lab.cloud" +PULP_HOST="10.205.3.187 pulp-server pulp-server.internal.sms-cloud" cat << EOF | sudo tee -a /etc/hosts -10.0.0.34 pelican pelican.service.compute.sms-lab.cloud -10.205.3.187 pulp-server pulp-server.internal.sms-cloud +$PELICAN_HOST +$PULP_HOST EOF -# Install git and tmux. -if $(which dnf 2>/dev/null >/dev/null); then - sudo dnf -y install git tmux python3-virtualenv -else - sudo apt update - sudo apt -y install git tmux gcc libffi-dev python3-dev python-is-python3 python3-virtualenv -fi - -# Disable the firewall. -sudo systemctl is-enabled firewalld && sudo systemctl stop firewalld && sudo systemctl disable firewalld - -# Disable SELinux both immediately and permanently. -if $(which setenforce 2>/dev/null >/dev/null); then - sudo setenforce 0 - sudo sed -i 's/^SELINUX=enforcing/SELINUX=disabled/' /etc/selinux/config -fi - -# Prevent sudo from performing DNS queries. -echo 'Defaults !fqdn' | sudo tee /etc/sudoers.d/no-fqdn - -# Clone repositories -cd $BASE_PATH -mkdir -p src -pushd src -[[ -d kayobe ]] || git clone https://github.com/stackhpc/kayobe.git -b $KAYOBE_BRANCH -[[ -d kayobe-config ]] || git clone https://github.com/stackhpc/stackhpc-kayobe-config kayobe-config -b $KAYOBE_CONFIG_BRANCH -[[ -d kayobe/tenks ]] || (cd kayobe && git clone https://opendev.org/openstack/tenks.git) -popd +# # Install git and tmux. +# if $(which dnf 2>/dev/null >/dev/null); then +# sudo dnf -y install git tmux python3-virtualenv +# else +# sudo apt update +# sudo apt -y install git tmux gcc libffi-dev python3-dev python-is-python3 python3-virtualenv +# fi + +# # Disable the firewall. +# sudo systemctl is-enabled firewalld && sudo systemctl stop firewalld && sudo systemctl disable firewalld + +# # Disable SELinux both immediately and permanently. +# if $(which setenforce 2>/dev/null >/dev/null); then +# sudo setenforce 0 +# sudo sed -i 's/^SELINUX=enforcing/SELINUX=disabled/' /etc/selinux/config +# fi + +# # Prevent sudo from performing DNS queries. +# echo 'Defaults !fqdn' | sudo tee /etc/sudoers.d/no-fqdn + +# # Clone repositories +# cd $BASE_PATH +# mkdir -p src +# pushd src +# [[ -d kayobe ]] || git clone https://github.com/stackhpc/kayobe.git -b $KAYOBE_BRANCH +# [[ -d kayobe-config ]] || git clone https://github.com/stackhpc/stackhpc-kayobe-config kayobe-config -b $KAYOBE_CONFIG_BRANCH +# [[ -d kayobe/tenks ]] || (cd kayobe && git clone https://opendev.org/openstack/tenks.git) +# popd # Create Kayobe virtualenv -mkdir -p venvs -pushd venvs -if [[ ! -d kayobe ]]; then - virtualenv kayobe -fi -# NOTE: Virtualenv's activate and deactivate scripts reference an -# unbound variable. -set +u -source kayobe/bin/activate -set -u -pip install -U pip -pip install ../src/kayobe -popd - -# Activate environment -pushd $BASE_PATH/src/kayobe-config -source kayobe-env --environment $KAYOBE_ENVIRONMENT +# mkdir -p venvs +# pushd venvs +# if [[ ! -d kayobe ]]; then +# virtualenv kayobe +# fi +# # NOTE: Virtualenv's activate and deactivate scripts reference an +# # unbound variable. +# set +u +# source kayobe/bin/activate +# set -u +# pip install -U pip +# pip install ../src/kayobe +# popd + +# # Activate environment +# pushd $BASE_PATH/src/kayobe-config +# source kayobe-env --environment $KAYOBE_ENVIRONMENT # Configure host networking (bridge, routes & firewall) -$KAYOBE_CONFIG_PATH/environments/$KAYOBE_ENVIRONMENT/configure-local-networking.sh +# $KAYOBE_CONFIG_PATH/environments/$KAYOBE_ENVIRONMENT/configure-local-networking.sh + +# # Bootstrap the Ansible control host. +# kayobe control host bootstrap + +# # Configure the seed hypervisor host. +# kayobe seed hypervisor host configure + +# # Provision the seed VM. +# kayobe seed vm provision -# Bootstrap the Ansible control host. -kayobe control host bootstrap +# # Configure the seed host, and deploy a local registry. +# kayobe seed host configure -# Configure the seed hypervisor host. -kayobe seed hypervisor host configure +# kayobe seed container image build bifrost_deploy -# Provision the seed VM. -kayobe seed vm provision +# # Deploy the seed services (including local pulp registry) +# kayobe seed service deploy -vvv #Doesn't work +# kayobe seed service deploy --tags seed-deploy-containers --kolla-tags none # Deploy local pulp server -# Configure the seed host, and deploy a local registry. -kayobe seed host configure +# Deploying the seed restarts networking interface, run +# configure-local-networking.sh again to re-add routes. +# $KAYOBE_CONFIG_PATH/environments/$KAYOBE_ENVIRONMENT/configure-local-networking.sh -# Deploy the seed services. -kayobe seed service deploy -# Deploying the seed restarts networking interface, -# run configure-local-networking.sh again to re-add routes. -$KAYOBE_CONFIG_PATH/environments/$KAYOBE_ENVIRONMENT/configure-local-networking.sh +####################################################################### +# NEED TO ADD 10.205.3.187 pulp-server pulp-server.internal.sms-cloud +# TO ETC/HOSTS OF DOCKER CONTAINER BEFORE SYNCING WITH UPSTEAM PULP +# - I'VE DONE THIS MANUALLY FOR NOW. +####################################################################### + +# Add sms lab test pulp to /etc/hosts of seed vm's pulp container +SEED_IP=192.168.33.5 +REMOTE_COMMAND="docker exec pulp sh -c 'echo $PULP_HOST | sudo tee -a /etc/hosts'" +ssh stack@$SEED_IP $REMOTE_COMMAND +# Check contents of hosts file was modified correctly +# echo -e "\nContents of /etc/hosts on pulp container:\n" +# ssh stack@$SEED_IP 'docker exec pulp cat /etc/hosts' +# echo + # Sync package & container repositories. -kayobe playbook run $KAYOBE_CONFIG_PATH/ansible/pulp-repo-sync.yml -kayobe playbook run $KAYOBE_CONFIG_PATH/ansible/pulp-repo-publish.yml -kayobe playbook run $KAYOBE_CONFIG_PATH/ansible/pulp-container-sync.yml -kayobe playbook run $KAYOBE_CONFIG_PATH/ansible/pulp-container-publish.yml +# kayobe playbook run $KAYOBE_CONFIG_PATH/ansible/pulp-repo-sync.yml -vvv &> _pulp_repo_sync.log +# kayobe playbook run $KAYOBE_CONFIG_PATH/ansible/pulp-repo-publish.yml -vvv &> _pulp_repo_publish.log +# kayobe playbook run $KAYOBE_CONFIG_PATH/ansible/pulp-container-sync.yml -vvv &> _pulp_container_sync.log +# kayobe playbook run $KAYOBE_CONFIG_PATH/ansible/pulp-container-publish.yml -vvv &> _pulp_container_publish.log + +# Re-run full task to set up bifrost_deploy etc. using newly-populated pulp repo +# kayobe seed service deploy + + +# Deploying the seed restarts networking interface, run +# configure-local-networking.sh again to re-add routes. +# $KAYOBE_CONFIG_PATH/environments/$KAYOBE_ENVIRONMENT/configure-local-networking.sh + # NOTE: Make sure to use ./tenks, since just ‘tenks’ will install via PyPI. -(export TENKS_CONFIG_PATH=$KAYOBE_CONFIG_PATH/environments/$KAYOBE_ENVIRONMENT/tenks.yml && \ - export KAYOBE_CONFIG_SOURCE_PATH=$BASE_PATH/src/kayobe-config && \ - export KAYOBE_VENV_PATH=$BASE_PATH/venvs/kayobe && \ - cd $BASE_PATH/src/kayobe && \ - ./dev/tenks-deploy-overcloud.sh ./tenks) +# (export TENKS_CONFIG_PATH=$KAYOBE_CONFIG_PATH/environments/$KAYOBE_ENVIRONMENT/tenks.yml && \ +# export KAYOBE_CONFIG_SOURCE_PATH=$BASE_PATH/src/kayobe-config && \ +# export KAYOBE_VENV_PATH=$BASE_PATH/venvs/kayobe && \ +# cd $BASE_PATH/src/kayobe && \. +# ./dev/tenks-deploy-overcloud.sh ./tenks) +# ./dev/tenks-teardown-overcloud.sh ./tenks) # Inspect and provision the overcloud hardware: -kayobe overcloud inventory discover -kayobe overcloud hardware inspect -kayobe overcloud provision -kayobe overcloud host configure -kayobe playbook run $KAYOBE_CONFIG_PATH/ansible/cephadm.yml -kayobe overcloud container image pull -kayobe overcloud service deploy -source $KOLLA_CONFIG_PATH/public-openrc.sh -kayobe overcloud post configure -source $KOLLA_CONFIG_PATH/public-openrc.sh -$KAYOBE_CONFIG_PATH/environments/$KAYOBE_ENVIRONMENT/init-runonce.sh - -(export KAYOBE_CONFIG_SOURCE_PATH=$BASE_PATH/src/kayobe-config && \ - export KAYOBE_VENV_PATH=$BASE_PATH/venvs/kayobe && \ - cd $BASE_PATH/src/kayobe && \ - ./dev/overcloud-test-vm.sh) +# kayobe overcloud inventory discover +# kayobe overcloud hardware inspect +# kayobe overcloud provision +# kayobe overcloud host configure +# kayobe playbook run $KAYOBE_CONFIG_PATH/ansible/cephadm.yml +# kayobe playbook run $KAYOBE_CONFIG_PATH/ansible/cephadm-gather-keys.yml +# kayobe overcloud container image pull +# kayobe overcloud service deploy +# source $KOLLA_CONFIG_PATH/public-openrc.sh +# kayobe overcloud post configure +# source $KOLLA_CONFIG_PATH/public-openrc.sh + + +# $KAYOBE_CONFIG_PATH/environments/$KAYOBE_ENVIRONMENT/init-runonce.sh +# Use openstack-config-multinode here instead of init-runonce.sh + +# (export KAYOBE_CONFIG_SOURCE_PATH=$BASE_PATH/src/kayobe-config && \ +# export KAYOBE_VENV_PATH=$BASE_PATH/venvs/kayobe && \ +# cd $BASE_PATH/src/kayobe && \ +# ./dev/overcloud-test-vm.sh) + + From ed4db520297b7ec90d930db173bd57549ea31ef5 Mon Sep 17 00:00:00 2001 From: Scott Davidson Date: Thu, 1 Dec 2022 15:08:37 +0000 Subject: [PATCH 13/33] Workaround for MTU issue on 'external' openstack network Enable provider networks in neutron and add geneve network config --- .../group_vars/compute/network-interfaces | 2 ++ etc/kayobe/environments/aufn-ceph/kolla.yml | 3 ++- etc/kayobe/environments/aufn-ceph/neutron.yml | 14 +++++++++++++- 3 files changed, 17 insertions(+), 2 deletions(-) diff --git a/etc/kayobe/environments/aufn-ceph/inventory/group_vars/compute/network-interfaces b/etc/kayobe/environments/aufn-ceph/inventory/group_vars/compute/network-interfaces index a6944527f..b44b1b048 100644 --- a/etc/kayobe/environments/aufn-ceph/inventory/group_vars/compute/network-interfaces +++ b/etc/kayobe/environments/aufn-ceph/inventory/group_vars/compute/network-interfaces @@ -12,6 +12,8 @@ storage_interface: "{{ 'ens3' if os_distribution == 'ubuntu' else 'eth1' }}.{{ s tunnel_interface: "{{ 'ens3' if os_distribution == 'ubuntu' else 'eth1' }}.{{ tunnel_vlan }}" +external_interface: "{{ 'ens3' if os_distribution == 'ubuntu' else 'eth1' }}.{{ external_vlan }}" + ############################################################################### # Dummy variable to allow Ansible to accept this file. workaround_ansible_issue_8743: yes diff --git a/etc/kayobe/environments/aufn-ceph/kolla.yml b/etc/kayobe/environments/aufn-ceph/kolla.yml index 292b701d9..155ac2ed1 100644 --- a/etc/kayobe/environments/aufn-ceph/kolla.yml +++ b/etc/kayobe/environments/aufn-ceph/kolla.yml @@ -13,4 +13,5 @@ kolla_overcloud_inventory_custom_services: "{{ lookup('template', kayobe_env_con ############################################################################### # Kolla feature flag configuration. kolla_enable_cinder: true -kolla_enable_ovn: true \ No newline at end of file +kolla_enable_ovn: true +kolla_enable_neutron_provider_networks: true diff --git a/etc/kayobe/environments/aufn-ceph/neutron.yml b/etc/kayobe/environments/aufn-ceph/neutron.yml index c6c658f38..d2c5f6428 100644 --- a/etc/kayobe/environments/aufn-ceph/neutron.yml +++ b/etc/kayobe/environments/aufn-ceph/neutron.yml @@ -1,3 +1,15 @@ --- kolla_neutron_ml2_network_vlan_ranges: - - physical_network: "physnet1" \ No newline at end of file + - physical_network: "physnet1" + +kolla_neutron_ml2_type_drivers: + - flat + - vlan + - vxlan + - geneve + +kolla_neutron_ml2_tenant_network_types: + - flat + - vlan + - vxlan + - geneve From a0d5bb2d658aadb55cdb2f9b6ac9c5f75c1238a1 Mon Sep 17 00:00:00 2001 From: Scott Davidson Date: Thu, 1 Dec 2022 17:14:06 +0000 Subject: [PATCH 14/33] Improve end-to-end script --- .../aufn-ceph/a-universe-from-nothing.sh | 236 ++++++++++-------- 1 file changed, 131 insertions(+), 105 deletions(-) diff --git a/etc/kayobe/environments/aufn-ceph/a-universe-from-nothing.sh b/etc/kayobe/environments/aufn-ceph/a-universe-from-nothing.sh index 6c4df79b2..6a37f21ca 100755 --- a/etc/kayobe/environments/aufn-ceph/a-universe-from-nothing.sh +++ b/etc/kayobe/environments/aufn-ceph/a-universe-from-nothing.sh @@ -7,154 +7,180 @@ # Cheat script for a full deployment. # This should be used for testing only. -# set -eu +set -eu BASE_PATH=~ -KAYOBE_BRANCH=stackhpc/yoga +KAYOBE_BRANCH=stackhpc/yoga/ KAYOBE_CONFIG_BRANCH=yoga-aufn KAYOBE_ENVIRONMENT=aufn-ceph -# FIXME: Work around lack of DNS on SMS lab. PELICAN_HOST="10.0.0.34 pelican pelican.service.compute.sms-lab.cloud" -PULP_HOST="10.205.3.187 pulp-server pulp-server.internal.sms-cloud" +# PULP_HOST="10.205.3.187 pulp-server pulp-server.internal.sms-cloud" +PULP_HOST="10.209.0.207 pulp-server pulp-server.internal.sms-cloud" + +# FIXME: Work around lack of DNS on SMS lab. cat << EOF | sudo tee -a /etc/hosts $PELICAN_HOST $PULP_HOST EOF -# # Install git and tmux. -# if $(which dnf 2>/dev/null >/dev/null); then -# sudo dnf -y install git tmux python3-virtualenv -# else -# sudo apt update -# sudo apt -y install git tmux gcc libffi-dev python3-dev python-is-python3 python3-virtualenv -# fi - -# # Disable the firewall. -# sudo systemctl is-enabled firewalld && sudo systemctl stop firewalld && sudo systemctl disable firewalld - -# # Disable SELinux both immediately and permanently. -# if $(which setenforce 2>/dev/null >/dev/null); then -# sudo setenforce 0 -# sudo sed -i 's/^SELINUX=enforcing/SELINUX=disabled/' /etc/selinux/config -# fi - -# # Prevent sudo from performing DNS queries. -# echo 'Defaults !fqdn' | sudo tee /etc/sudoers.d/no-fqdn - -# # Clone repositories -# cd $BASE_PATH -# mkdir -p src -# pushd src -# [[ -d kayobe ]] || git clone https://github.com/stackhpc/kayobe.git -b $KAYOBE_BRANCH -# [[ -d kayobe-config ]] || git clone https://github.com/stackhpc/stackhpc-kayobe-config kayobe-config -b $KAYOBE_CONFIG_BRANCH -# [[ -d kayobe/tenks ]] || (cd kayobe && git clone https://opendev.org/openstack/tenks.git) -# popd +# Install git and tmux. +if $(which dnf 2>/dev/null >/dev/null); then + sudo dnf -y install git tmux python3-virtualenv +else + sudo apt update + sudo apt -y install git tmux gcc libffi-dev python3-dev python-is-python3 python3-virtualenv +fi + +# Disable the firewall. +sudo systemctl is-enabled firewalld && sudo systemctl stop firewalld && sudo systemctl disable firewalld + +# Disable SELinux both immediately and permanently. +if $(which setenforce 2>/dev/null >/dev/null); then + sudo setenforce 0 + sudo sed -i 's/^SELINUX=enforcing/SELINUX=disabled/' /etc/selinux/config +fi + +# Prevent sudo from performing DNS queries. +echo 'Defaults !fqdn' | sudo tee /etc/sudoers.d/no-fqdn + +# Clone repositories +cd $BASE_PATH +mkdir -p src +pushd src +[[ -d kayobe ]] || git clone https://github.com/stackhpc/kayobe.git -b $KAYOBE_BRANCH +[[ -d kayobe-config ]] || git clone https://github.com/stackhpc/stackhpc-kayobe-config kayobe-config -b $KAYOBE_CONFIG_BRANCH +[[ -d kayobe/tenks ]] || (cd kayobe && git clone https://opendev.org/openstack/tenks.git) +popd # Create Kayobe virtualenv -# mkdir -p venvs -# pushd venvs -# if [[ ! -d kayobe ]]; then -# virtualenv kayobe -# fi -# # NOTE: Virtualenv's activate and deactivate scripts reference an -# # unbound variable. -# set +u -# source kayobe/bin/activate -# set -u -# pip install -U pip -# pip install ../src/kayobe -# popd - -# # Activate environment -# pushd $BASE_PATH/src/kayobe-config -# source kayobe-env --environment $KAYOBE_ENVIRONMENT +mkdir -p venvs +pushd venvs +if [[ ! -d kayobe ]]; then + virtualenv kayobe +fi +# NOTE: Virtualenv's activate and deactivate scripts reference an +# unbound variable. +set +u +source kayobe/bin/activate +set -u +pip install -U pip +pip install ../src/kayobe +popd + +# Activate environment +pushd $BASE_PATH/src/kayobe-config +source kayobe-env --environment $KAYOBE_ENVIRONMENT # Configure host networking (bridge, routes & firewall) -# $KAYOBE_CONFIG_PATH/environments/$KAYOBE_ENVIRONMENT/configure-local-networking.sh +$KAYOBE_CONFIG_PATH/environments/$KAYOBE_ENVIRONMENT/configure-local-networking.sh -# # Bootstrap the Ansible control host. -# kayobe control host bootstrap +# Bootstrap the Ansible control host. +kayobe control host bootstrap -# # Configure the seed hypervisor host. -# kayobe seed hypervisor host configure +# Configure the seed hypervisor host. +kayobe seed hypervisor host configure -# # Provision the seed VM. -# kayobe seed vm provision +# Provision the seed VM. +kayobe seed vm provision -# # Configure the seed host, and deploy a local registry. -# kayobe seed host configure +# Configure the seed host, and deploy a local registry. +kayobe seed host configure -# kayobe seed container image build bifrost_deploy -# # Deploy the seed services (including local pulp registry) -# kayobe seed service deploy -vvv #Doesn't work -# kayobe seed service deploy --tags seed-deploy-containers --kolla-tags none # Deploy local pulp server - -# Deploying the seed restarts networking interface, run -# configure-local-networking.sh again to re-add routes. -# $KAYOBE_CONFIG_PATH/environments/$KAYOBE_ENVIRONMENT/configure-local-networking.sh +# Deploy local pulp server as a container on the seed VM +kayobe seed service deploy --tags seed-deploy-containers --kolla-tags none +# Deploying the seed restarts networking interface, run configure-local-networking.sh again to re-add routes. +$KAYOBE_CONFIG_PATH/environments/$KAYOBE_ENVIRONMENT/configure-local-networking.sh ####################################################################### # NEED TO ADD 10.205.3.187 pulp-server pulp-server.internal.sms-cloud # TO ETC/HOSTS OF DOCKER CONTAINER BEFORE SYNCING WITH UPSTEAM PULP -# - I'VE DONE THIS MANUALLY FOR NOW. ####################################################################### # Add sms lab test pulp to /etc/hosts of seed vm's pulp container SEED_IP=192.168.33.5 -REMOTE_COMMAND="docker exec pulp sh -c 'echo $PULP_HOST | sudo tee -a /etc/hosts'" +REMOTE_COMMAND="docker exec pulp sh -c 'echo $PULP_HOST | tee -a /etc/hosts'" ssh stack@$SEED_IP $REMOTE_COMMAND -# Check contents of hosts file was modified correctly -# echo -e "\nContents of /etc/hosts on pulp container:\n" -# ssh stack@$SEED_IP 'docker exec pulp cat /etc/hosts' -# echo - # Sync package & container repositories. -# kayobe playbook run $KAYOBE_CONFIG_PATH/ansible/pulp-repo-sync.yml -vvv &> _pulp_repo_sync.log -# kayobe playbook run $KAYOBE_CONFIG_PATH/ansible/pulp-repo-publish.yml -vvv &> _pulp_repo_publish.log -# kayobe playbook run $KAYOBE_CONFIG_PATH/ansible/pulp-container-sync.yml -vvv &> _pulp_container_sync.log -# kayobe playbook run $KAYOBE_CONFIG_PATH/ansible/pulp-container-publish.yml -vvv &> _pulp_container_publish.log +kayobe playbook run $KAYOBE_CONFIG_PATH/ansible/pulp-repo-sync.yml +kayobe playbook run $KAYOBE_CONFIG_PATH/ansible/pulp-repo-publish.yml +kayobe playbook run $KAYOBE_CONFIG_PATH/ansible/pulp-container-sync.yml +kayobe playbook run $KAYOBE_CONFIG_PATH/ansible/pulp-container-publish.yml + +kayobe seed container image build bifrost_deploy # Re-run full task to set up bifrost_deploy etc. using newly-populated pulp repo -# kayobe seed service deploy +kayobe seed service deploy -# Deploying the seed restarts networking interface, run -# configure-local-networking.sh again to re-add routes. -# $KAYOBE_CONFIG_PATH/environments/$KAYOBE_ENVIRONMENT/configure-local-networking.sh +# Deploying the seed restarts networking interface, run configure-local-networking.sh again to re-add routes. +$KAYOBE_CONFIG_PATH/environments/$KAYOBE_ENVIRONMENT/configure-local-networking.sh # NOTE: Make sure to use ./tenks, since just ‘tenks’ will install via PyPI. -# (export TENKS_CONFIG_PATH=$KAYOBE_CONFIG_PATH/environments/$KAYOBE_ENVIRONMENT/tenks.yml && \ -# export KAYOBE_CONFIG_SOURCE_PATH=$BASE_PATH/src/kayobe-config && \ -# export KAYOBE_VENV_PATH=$BASE_PATH/venvs/kayobe && \ -# cd $BASE_PATH/src/kayobe && \. -# ./dev/tenks-deploy-overcloud.sh ./tenks) -# ./dev/tenks-teardown-overcloud.sh ./tenks) +(export TENKS_CONFIG_PATH=$KAYOBE_CONFIG_PATH/environments/$KAYOBE_ENVIRONMENT/tenks.yml && \ + export KAYOBE_CONFIG_SOURCE_PATH=$BASE_PATH/src/kayobe-config && \ + export KAYOBE_VENV_PATH=$BASE_PATH/venvs/kayobe && \ + cd $BASE_PATH/src/kayobe && \ + ./dev/tenks-deploy-overcloud.sh ./tenks) # Inspect and provision the overcloud hardware: -# kayobe overcloud inventory discover -# kayobe overcloud hardware inspect -# kayobe overcloud provision -# kayobe overcloud host configure -# kayobe playbook run $KAYOBE_CONFIG_PATH/ansible/cephadm.yml -# kayobe playbook run $KAYOBE_CONFIG_PATH/ansible/cephadm-gather-keys.yml -# kayobe overcloud container image pull -# kayobe overcloud service deploy -# source $KOLLA_CONFIG_PATH/public-openrc.sh -# kayobe overcloud post configure -# source $KOLLA_CONFIG_PATH/public-openrc.sh - - -# $KAYOBE_CONFIG_PATH/environments/$KAYOBE_ENVIRONMENT/init-runonce.sh -# Use openstack-config-multinode here instead of init-runonce.sh +kayobe overcloud inventory discover +kayobe overcloud hardware inspect +kayobe overcloud provision +kayobe overcloud host configure +kayobe playbook run $KAYOBE_CONFIG_PATH/ansible/cephadm.yml +kayobe playbook run $KAYOBE_CONFIG_PATH/ansible/cephadm-gather-keys.yml +kayobe overcloud container image pull +kayobe overcloud service deploy +source $KOLLA_CONFIG_PATH/public-openrc.sh +kayobe overcloud post configure +source $KOLLA_CONFIG_PATH/public-openrc.sh + + + +# Use Jack's openstack-config-multinode here instead of init-runonce.sh +####### Old verson: $KAYOBE_CONFIG_PATH/environments/$KAYOBE_ENVIRONMENT/init-runonce.sh +VENV_DIR=$BASE_PATH/venvs/ansible +cd $BASE_PATH/src/ +[[ -d openstack-network-config ]] || git clone https://github.com/stackhpc/openstack-config-multinode.git -b geneve openstack-network-config +cd openstack-network-config +if [[ ! -d $VENV_DIR ]]; then + virtualenv $VENV_DIR +fi +source $VENV_DIR/bin/activate +pip install -U pip +pip install -r requirements.txt +ansible-galaxy role install -p ansible/roles -r requirements.yml +ansible-galaxy collection install -p ansible/collections -r requirements.yml +source $KOLLA_CONFIG_PATH/public-openrc.sh +tools/openstack-config #Run script to configure openstack cloud +deactivate + + +# Create a test vm +VENV_DIR=$BASE_PATH/venvs/openstack +if [[ ! -d $VENV_DIR ]]; then + virtualenv $VENV_DIR +fi +source $VENV_DIR/bin/activate +pip install -U pip +pip install python-openstackclient +source $KOLLA_CONFIG_PATH/public-openrc.sh +echo "Creating openstack key:" +openstack keypair create --private-key ~/.ssh/id_rsa mykey +echo "Creating test vm:" +openstack server create --key-name mykey --flavor m1.tiny --image cirros --network admin-geneve test-vm-1 +echo "Attaching floating IP:" +openstack floating ip create external +openstack server add floating ip test-vm-1 `openstack floating ip list -c ID -f value` +echo -e "Done! \nopenstack server list:" +openstack server list # (export KAYOBE_CONFIG_SOURCE_PATH=$BASE_PATH/src/kayobe-config && \ # export KAYOBE_VENV_PATH=$BASE_PATH/venvs/kayobe && \ # cd $BASE_PATH/src/kayobe && \ -# ./dev/overcloud-test-vm.sh) - - +# ./dev/overcloud-test-vm.sh) \ No newline at end of file From 9caa8008420ac88acc8934642747407f3391361c Mon Sep 17 00:00:00 2001 From: Scott Davidson Date: Fri, 2 Dec 2022 15:01:03 +0000 Subject: [PATCH 15/33] Further e2e script improvements --- .../aufn-ceph/a-universe-from-nothing.sh | 27 ++-------------- .../aufn-ceph/configure-openstack.sh | 32 +++++++++++++++++++ 2 files changed, 35 insertions(+), 24 deletions(-) create mode 100755 etc/kayobe/environments/aufn-ceph/configure-openstack.sh diff --git a/etc/kayobe/environments/aufn-ceph/a-universe-from-nothing.sh b/etc/kayobe/environments/aufn-ceph/a-universe-from-nothing.sh index 6a37f21ca..a72b5f5b2 100755 --- a/etc/kayobe/environments/aufn-ceph/a-universe-from-nothing.sh +++ b/etc/kayobe/environments/aufn-ceph/a-universe-from-nothing.sh @@ -10,13 +10,13 @@ set -eu BASE_PATH=~ -KAYOBE_BRANCH=stackhpc/yoga/ +KAYOBE_BRANCH=stackhpc/yoga KAYOBE_CONFIG_BRANCH=yoga-aufn KAYOBE_ENVIRONMENT=aufn-ceph PELICAN_HOST="10.0.0.34 pelican pelican.service.compute.sms-lab.cloud" # PULP_HOST="10.205.3.187 pulp-server pulp-server.internal.sms-cloud" -PULP_HOST="10.209.0.207 pulp-server pulp-server.internal.sms-cloud" +PULP_HOST="10.209.0.207 pulp-server pulp-server.internal.sms-cloud" #Use Mark's router workaround # FIXME: Work around lack of DNS on SMS lab. cat << EOF | sudo tee -a /etc/hosts @@ -141,25 +141,9 @@ kayobe overcloud post configure source $KOLLA_CONFIG_PATH/public-openrc.sh - # Use Jack's openstack-config-multinode here instead of init-runonce.sh ####### Old verson: $KAYOBE_CONFIG_PATH/environments/$KAYOBE_ENVIRONMENT/init-runonce.sh -VENV_DIR=$BASE_PATH/venvs/ansible -cd $BASE_PATH/src/ -[[ -d openstack-network-config ]] || git clone https://github.com/stackhpc/openstack-config-multinode.git -b geneve openstack-network-config -cd openstack-network-config -if [[ ! -d $VENV_DIR ]]; then - virtualenv $VENV_DIR -fi -source $VENV_DIR/bin/activate -pip install -U pip -pip install -r requirements.txt -ansible-galaxy role install -p ansible/roles -r requirements.yml -ansible-galaxy collection install -p ansible/collections -r requirements.yml -source $KOLLA_CONFIG_PATH/public-openrc.sh -tools/openstack-config #Run script to configure openstack cloud -deactivate - +$KAYOBE_CONFIG_PATH/environments/$KAYOBE_ENVIRONMENT/configure-openstack.sh $BASE_PATH # Create a test vm VENV_DIR=$BASE_PATH/venvs/openstack @@ -179,8 +163,3 @@ openstack floating ip create external openstack server add floating ip test-vm-1 `openstack floating ip list -c ID -f value` echo -e "Done! \nopenstack server list:" openstack server list - -# (export KAYOBE_CONFIG_SOURCE_PATH=$BASE_PATH/src/kayobe-config && \ -# export KAYOBE_VENV_PATH=$BASE_PATH/venvs/kayobe && \ -# cd $BASE_PATH/src/kayobe && \ -# ./dev/overcloud-test-vm.sh) \ No newline at end of file diff --git a/etc/kayobe/environments/aufn-ceph/configure-openstack.sh b/etc/kayobe/environments/aufn-ceph/configure-openstack.sh new file mode 100755 index 000000000..7b9b50416 --- /dev/null +++ b/etc/kayobe/environments/aufn-ceph/configure-openstack.sh @@ -0,0 +1,32 @@ +#!/bin/bash + +BASE_PATH=~ +VENV_DIR=$BASE_PATH/venvs/ansible +cd $BASE_PATH/src/ +[[ -d openstack-network-config ]] || git clone https://github.com/stackhpc/openstack-config-multinode.git -b geneve openstack-network-config +cd openstack-network-config +if [[ ! -d $VENV_DIR ]]; then + # virtualenv $VENV_DIR # This causes a strange bug with python3.6 where nested virtual env creation leads to envs without pip... + python3 -m venv $VENV_DIR +fi + +# NOTE: Virtualenv's activate and deactivate scripts reference an +# unbound variable. +set +u +source $VENV_DIR/bin/activate +set -u + +# ansible --version + +pip install -U pip +pip install -r requirements.txt +ansible-galaxy role install -p ansible/roles -r requirements.yml +ansible-galaxy collection install -p ansible/collections -r requirements.yml + +source $BASE_PATH/src/kayobe-config/etc/kolla/public-openrc.sh + +tools/openstack-config #Run script to configure openstack cloud + +# set +u +# deactivate +# set -u \ No newline at end of file From 1797e533ef0f80269a72118517ab522bb7c16b10 Mon Sep 17 00:00:00 2001 From: Scott Davidson Date: Fri, 9 Dec 2022 11:01:00 +0000 Subject: [PATCH 16/33] Refine e2e script --- .../aufn-ceph/a-universe-from-nothing.sh | 4 ++++ .../environments/aufn-ceph/configure-openstack.sh | 15 +++++---------- 2 files changed, 9 insertions(+), 10 deletions(-) diff --git a/etc/kayobe/environments/aufn-ceph/a-universe-from-nothing.sh b/etc/kayobe/environments/aufn-ceph/a-universe-from-nothing.sh index a72b5f5b2..7a6ef73de 100755 --- a/etc/kayobe/environments/aufn-ceph/a-universe-from-nothing.sh +++ b/etc/kayobe/environments/aufn-ceph/a-universe-from-nothing.sh @@ -143,6 +143,10 @@ source $KOLLA_CONFIG_PATH/public-openrc.sh # Use Jack's openstack-config-multinode here instead of init-runonce.sh ####### Old verson: $KAYOBE_CONFIG_PATH/environments/$KAYOBE_ENVIRONMENT/init-runonce.sh +#Deactivate current kayobe venv +set +u +deactivate +set -u $KAYOBE_CONFIG_PATH/environments/$KAYOBE_ENVIRONMENT/configure-openstack.sh $BASE_PATH # Create a test vm diff --git a/etc/kayobe/environments/aufn-ceph/configure-openstack.sh b/etc/kayobe/environments/aufn-ceph/configure-openstack.sh index 7b9b50416..e71c2940a 100755 --- a/etc/kayobe/environments/aufn-ceph/configure-openstack.sh +++ b/etc/kayobe/environments/aufn-ceph/configure-openstack.sh @@ -6,18 +6,17 @@ cd $BASE_PATH/src/ [[ -d openstack-network-config ]] || git clone https://github.com/stackhpc/openstack-config-multinode.git -b geneve openstack-network-config cd openstack-network-config if [[ ! -d $VENV_DIR ]]; then - # virtualenv $VENV_DIR # This causes a strange bug with python3.6 where nested virtual env creation leads to envs without pip... + # Using virtualenv causes a strange bug with python3.6 where + # nested virtual env creation leads to envs without pip... + # virtualenv $VENV_DIR python3 -m venv $VENV_DIR fi -# NOTE: Virtualenv's activate and deactivate scripts reference an -# unbound variable. +# NOTE: Virtualenv's activate and deactivate scripts reference an unbound variable. set +u source $VENV_DIR/bin/activate set -u -# ansible --version - pip install -U pip pip install -r requirements.txt ansible-galaxy role install -p ansible/roles -r requirements.yml @@ -25,8 +24,4 @@ ansible-galaxy collection install -p ansible/collections -r requirements.yml source $BASE_PATH/src/kayobe-config/etc/kolla/public-openrc.sh -tools/openstack-config #Run script to configure openstack cloud - -# set +u -# deactivate -# set -u \ No newline at end of file +tools/openstack-config #Run script to configure openstack cloud \ No newline at end of file From 1836459a13b52cd7869a7ffa3edb10ac5ddc6f11 Mon Sep 17 00:00:00 2001 From: Scott Davidson Date: Fri, 16 Dec 2022 10:44:02 +0000 Subject: [PATCH 17/33] Fix external network mtu --- etc/kayobe/environments/aufn-ceph/networks.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/etc/kayobe/environments/aufn-ceph/networks.yml b/etc/kayobe/environments/aufn-ceph/networks.yml index 0bdb01ab8..5706e3bc8 100644 --- a/etc/kayobe/environments/aufn-ceph/networks.yml +++ b/etc/kayobe/environments/aufn-ceph/networks.yml @@ -84,7 +84,7 @@ internal_vlan: 101 internal_physical_network: cloud external_cidr: 192.168.38.0/24 -external_mtu: 1400 +external_mtu: 1392 external_vlan: 102 external_physical_network: cloud From 06ac4c4f3c094010d7a21b439ae73a33560ef104 Mon Sep 17 00:00:00 2001 From: Scott Davidson Date: Fri, 16 Dec 2022 10:44:28 +0000 Subject: [PATCH 18/33] Fix comment --- .../environments/aufn-ceph/a-universe-from-nothing.sh | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/etc/kayobe/environments/aufn-ceph/a-universe-from-nothing.sh b/etc/kayobe/environments/aufn-ceph/a-universe-from-nothing.sh index 7a6ef73de..186a61a17 100755 --- a/etc/kayobe/environments/aufn-ceph/a-universe-from-nothing.sh +++ b/etc/kayobe/environments/aufn-ceph/a-universe-from-nothing.sh @@ -94,10 +94,10 @@ kayobe seed service deploy --tags seed-deploy-containers --kolla-tags none # Deploying the seed restarts networking interface, run configure-local-networking.sh again to re-add routes. $KAYOBE_CONFIG_PATH/environments/$KAYOBE_ENVIRONMENT/configure-local-networking.sh -####################################################################### -# NEED TO ADD 10.205.3.187 pulp-server pulp-server.internal.sms-cloud -# TO ETC/HOSTS OF DOCKER CONTAINER BEFORE SYNCING WITH UPSTEAM PULP -####################################################################### +##################################################################### +# NEED TO ADD $PULP_HOST pulp-server pulp-server.internal.sms-cloud # +# TO ETC/HOSTS OF DOCKER CONTAINER BEFORE SYNCING WITH UPSTEAM PULP # +##################################################################### # Add sms lab test pulp to /etc/hosts of seed vm's pulp container SEED_IP=192.168.33.5 From f8934b2c16d35cfde8e60ea6810eb378b636b718 Mon Sep 17 00:00:00 2001 From: Scott Davidson Date: Fri, 16 Dec 2022 10:51:56 +0000 Subject: [PATCH 19/33] Move cloud-user workaround to aufn env --- etc/kayobe/environments/aufn-ceph/seed-hypervisor.yml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/etc/kayobe/environments/aufn-ceph/seed-hypervisor.yml b/etc/kayobe/environments/aufn-ceph/seed-hypervisor.yml index 3b351675a..6a1b7ffdf 100644 --- a/etc/kayobe/environments/aufn-ceph/seed-hypervisor.yml +++ b/etc/kayobe/environments/aufn-ceph/seed-hypervisor.yml @@ -10,3 +10,5 @@ seed_hypervisor_extra_network_interfaces: - "{{ public_net_name }}" - "{{ external_net_names[0] }}" +# Workaround change to cloud-user default login name on CentOS-Stream8 +seed_hypervisor_bootstrap_user: "{{ lookup('env', 'USER') }}" From f17c2117675c9e5599a65caf58ced49df846d586 Mon Sep 17 00:00:00 2001 From: Scott Davidson Date: Tue, 3 Jan 2023 10:31:25 +0000 Subject: [PATCH 20/33] Remove pulp router workaround --- etc/kayobe/environments/aufn-ceph/a-universe-from-nothing.sh | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/etc/kayobe/environments/aufn-ceph/a-universe-from-nothing.sh b/etc/kayobe/environments/aufn-ceph/a-universe-from-nothing.sh index 186a61a17..198b6acaa 100755 --- a/etc/kayobe/environments/aufn-ceph/a-universe-from-nothing.sh +++ b/etc/kayobe/environments/aufn-ceph/a-universe-from-nothing.sh @@ -15,8 +15,7 @@ KAYOBE_CONFIG_BRANCH=yoga-aufn KAYOBE_ENVIRONMENT=aufn-ceph PELICAN_HOST="10.0.0.34 pelican pelican.service.compute.sms-lab.cloud" -# PULP_HOST="10.205.3.187 pulp-server pulp-server.internal.sms-cloud" -PULP_HOST="10.209.0.207 pulp-server pulp-server.internal.sms-cloud" #Use Mark's router workaround +PULP_HOST="10.205.3.187 pulp-server pulp-server.internal.sms-cloud" # FIXME: Work around lack of DNS on SMS lab. cat << EOF | sudo tee -a /etc/hosts From b42282fda0c6029141ff3a308eb128cff030b89d Mon Sep 17 00:00:00 2001 From: Scott Davidson Date: Wed, 4 Jan 2023 16:10:19 +0000 Subject: [PATCH 21/33] Tidy up comments and remove unused sections --- .../aufn-ceph/a-universe-from-nothing.sh | 17 ++--------------- .../aufn-ceph/configure-local-networking.sh | 8 -------- .../aufn-ceph/configure-openstack.sh | 5 +++-- .../environments/aufn-ceph/init-runonce.sh | 18 ------------------ etc/kayobe/environments/aufn-ceph/stackhpc.yml | 4 ---- etc/kayobe/environments/aufn-ceph/storage.yml | 4 +++- 6 files changed, 8 insertions(+), 48 deletions(-) delete mode 100755 etc/kayobe/environments/aufn-ceph/init-runonce.sh diff --git a/etc/kayobe/environments/aufn-ceph/a-universe-from-nothing.sh b/etc/kayobe/environments/aufn-ceph/a-universe-from-nothing.sh index 198b6acaa..ae2cd3c17 100755 --- a/etc/kayobe/environments/aufn-ceph/a-universe-from-nothing.sh +++ b/etc/kayobe/environments/aufn-ceph/a-universe-from-nothing.sh @@ -86,18 +86,12 @@ kayobe seed vm provision # Configure the seed host, and deploy a local registry. kayobe seed host configure - # Deploy local pulp server as a container on the seed VM kayobe seed service deploy --tags seed-deploy-containers --kolla-tags none # Deploying the seed restarts networking interface, run configure-local-networking.sh again to re-add routes. $KAYOBE_CONFIG_PATH/environments/$KAYOBE_ENVIRONMENT/configure-local-networking.sh -##################################################################### -# NEED TO ADD $PULP_HOST pulp-server pulp-server.internal.sms-cloud # -# TO ETC/HOSTS OF DOCKER CONTAINER BEFORE SYNCING WITH UPSTEAM PULP # -##################################################################### - # Add sms lab test pulp to /etc/hosts of seed vm's pulp container SEED_IP=192.168.33.5 REMOTE_COMMAND="docker exec pulp sh -c 'echo $PULP_HOST | tee -a /etc/hosts'" @@ -109,16 +103,9 @@ kayobe playbook run $KAYOBE_CONFIG_PATH/ansible/pulp-repo-publish.yml kayobe playbook run $KAYOBE_CONFIG_PATH/ansible/pulp-container-sync.yml kayobe playbook run $KAYOBE_CONFIG_PATH/ansible/pulp-container-publish.yml -kayobe seed container image build bifrost_deploy - # Re-run full task to set up bifrost_deploy etc. using newly-populated pulp repo kayobe seed service deploy - -# Deploying the seed restarts networking interface, run configure-local-networking.sh again to re-add routes. -$KAYOBE_CONFIG_PATH/environments/$KAYOBE_ENVIRONMENT/configure-local-networking.sh - - # NOTE: Make sure to use ./tenks, since just ‘tenks’ will install via PyPI. (export TENKS_CONFIG_PATH=$KAYOBE_CONFIG_PATH/environments/$KAYOBE_ENVIRONMENT/tenks.yml && \ export KAYOBE_CONFIG_SOURCE_PATH=$BASE_PATH/src/kayobe-config && \ @@ -140,8 +127,8 @@ kayobe overcloud post configure source $KOLLA_CONFIG_PATH/public-openrc.sh -# Use Jack's openstack-config-multinode here instead of init-runonce.sh -####### Old verson: $KAYOBE_CONFIG_PATH/environments/$KAYOBE_ENVIRONMENT/init-runonce.sh +# Use Jack's openstack-config-multinode here instead of init-runonce.sh script from standard aufn + #Deactivate current kayobe venv set +u deactivate diff --git a/etc/kayobe/environments/aufn-ceph/configure-local-networking.sh b/etc/kayobe/environments/aufn-ceph/configure-local-networking.sh index a50e7b144..ac8825758 100755 --- a/etc/kayobe/environments/aufn-ceph/configure-local-networking.sh +++ b/etc/kayobe/environments/aufn-ceph/configure-local-networking.sh @@ -22,9 +22,6 @@ seed_hv_private_ip=$(ip a show dev $iface | awk '$1 == "inet" { gsub(/\/[0-9]*/, # 6080: VNC console forwarded_ports="80 6080" -# IP of the seed hypervisor on the OpenStack 'public' network created by init-runonce.sh. -public_ip="10.0.2.1" - # Install iptables. if $(which dnf >/dev/null 2>&1); then sudo dnf -y install iptables @@ -43,11 +40,6 @@ if ! sudo ip l show brcloud >/dev/null 2>&1; then sudo ip l set brcloud up fi -# Configure an IP on the 'public' network to allow access to/from the cloud. -if ! sudo ip a show dev brcloud | grep $public_ip/24 >/dev/null 2>&1; then - sudo ip a add $public_ip/24 dev brcloud -fi - # On CentOS 8, bridges without a port are DOWN, which causes network # configuration to fail. Add a dummy interface and plug it into the bridge. for i in mgmt prov cloud; do diff --git a/etc/kayobe/environments/aufn-ceph/configure-openstack.sh b/etc/kayobe/environments/aufn-ceph/configure-openstack.sh index e71c2940a..6262fe9c5 100755 --- a/etc/kayobe/environments/aufn-ceph/configure-openstack.sh +++ b/etc/kayobe/environments/aufn-ceph/configure-openstack.sh @@ -3,7 +3,7 @@ BASE_PATH=~ VENV_DIR=$BASE_PATH/venvs/ansible cd $BASE_PATH/src/ -[[ -d openstack-network-config ]] || git clone https://github.com/stackhpc/openstack-config-multinode.git -b geneve openstack-network-config +[[ -d openstack-network-config ]] || git clone https://github.com/stackhpc/openstack-config-multinode.git openstack-network-config cd openstack-network-config if [[ ! -d $VENV_DIR ]]; then # Using virtualenv causes a strange bug with python3.6 where @@ -24,4 +24,5 @@ ansible-galaxy collection install -p ansible/collections -r requirements.yml source $BASE_PATH/src/kayobe-config/etc/kolla/public-openrc.sh -tools/openstack-config #Run script to configure openstack cloud \ No newline at end of file +# Run script to configure openstack cloud +tools/openstack-config \ No newline at end of file diff --git a/etc/kayobe/environments/aufn-ceph/init-runonce.sh b/etc/kayobe/environments/aufn-ceph/init-runonce.sh deleted file mode 100755 index 44e6a5e28..000000000 --- a/etc/kayobe/environments/aufn-ceph/init-runonce.sh +++ /dev/null @@ -1,18 +0,0 @@ -#!/bin/bash - -set -e - -if [[ ! -d ~/os-venv ]]; then - virtualenv ~/os-venv -fi -~/os-venv/bin/pip install -U pip -~/os-venv/bin/pip install python-openstackclient -c https://releases.openstack.org/constraints/upper/master - -init_runonce=$KOLLA_SOURCE_PATH/tools/init-runonce -if [[ ! -f $init_runonce ]]; then - echo "Unable to find kolla-ansible repo" - exit 1 -fi - -source ~/os-venv/bin/activate -$init_runonce diff --git a/etc/kayobe/environments/aufn-ceph/stackhpc.yml b/etc/kayobe/environments/aufn-ceph/stackhpc.yml index 42c4fcb2e..0f31b2851 100644 --- a/etc/kayobe/environments/aufn-ceph/stackhpc.yml +++ b/etc/kayobe/environments/aufn-ceph/stackhpc.yml @@ -11,9 +11,5 @@ kolla_docker_namespace: stackhpc-dev # Base URL of the StackHPC Test Pulp service. stackhpc_release_pulp_url: "http://pulp-server.internal.sms-cloud:8080" -# No client certs required to access Test Pulp. -stackhpc_release_pulp_client_cert: -stackhpc_release_pulp_client_key: - pulp_username: admin pulp_password: 9e4bfa04-9d9d-493d-9473-ba92e4361dae diff --git a/etc/kayobe/environments/aufn-ceph/storage.yml b/etc/kayobe/environments/aufn-ceph/storage.yml index 827db4e01..2d2302b7c 100644 --- a/etc/kayobe/environments/aufn-ceph/storage.yml +++ b/etc/kayobe/environments/aufn-ceph/storage.yml @@ -5,5 +5,7 @@ # List of storage volume groups. See mrlesmithjr.manage-lvm role for # format. -#storage_lvm_groups: +# storage_lvm_groups: + +# Avoid undefined var which would result in 'LVM physical disks have not been configured' error storage_lvm_groups: [] From 5724699352a281323a013c69c2ffc026a09afd0e Mon Sep 17 00:00:00 2001 From: Scott Davidson Date: Mon, 9 Jan 2023 15:42:28 +0000 Subject: [PATCH 22/33] Revert branch change --- etc/kayobe/environments/aufn-ceph/configure-openstack.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/etc/kayobe/environments/aufn-ceph/configure-openstack.sh b/etc/kayobe/environments/aufn-ceph/configure-openstack.sh index 6262fe9c5..b683da165 100755 --- a/etc/kayobe/environments/aufn-ceph/configure-openstack.sh +++ b/etc/kayobe/environments/aufn-ceph/configure-openstack.sh @@ -3,8 +3,8 @@ BASE_PATH=~ VENV_DIR=$BASE_PATH/venvs/ansible cd $BASE_PATH/src/ -[[ -d openstack-network-config ]] || git clone https://github.com/stackhpc/openstack-config-multinode.git openstack-network-config -cd openstack-network-config +[[ -d openstack-config ]] || git clone https://github.com/stackhpc/openstack-config-multinode.git -b geneve openstack-config +cd openstack-config if [[ ! -d $VENV_DIR ]]; then # Using virtualenv causes a strange bug with python3.6 where # nested virtual env creation leads to envs without pip... From 739e1b109bfac344ecba0cda90ccbb2359663492 Mon Sep 17 00:00:00 2001 From: Scott Davidson Date: Mon, 9 Jan 2023 15:43:23 +0000 Subject: [PATCH 23/33] Use newer image --- .../environments/aufn-ceph/kolla/config/bifrost/bifrost.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/etc/kayobe/environments/aufn-ceph/kolla/config/bifrost/bifrost.yml b/etc/kayobe/environments/aufn-ceph/kolla/config/bifrost/bifrost.yml index 78ea4bf9b..1c06e1a2d 100644 --- a/etc/kayobe/environments/aufn-ceph/kolla/config/bifrost/bifrost.yml +++ b/etc/kayobe/environments/aufn-ceph/kolla/config/bifrost/bifrost.yml @@ -8,5 +8,5 @@ use_cirros: true {% if os_distribution == 'ubuntu' %} cirros_deploy_image_upstream_url: "https://cloud-images.ubuntu.com/focal/current/focal-server-cloudimg-amd64.img" {% else %} -cirros_deploy_image_upstream_url: "https://cloud.centos.org/centos/8-stream/x86_64/images/CentOS-Stream-GenericCloud-8-20210210.0.x86_64.qcow2" -{% endif %} +cirros_deploy_image_upstream_url: "https://cloud.centos.org/centos/8-stream/x86_64/images/CentOS-Stream-GenericCloud-8-20220913.0.x86_64.qcow2" +{% endif %} \ No newline at end of file From 55684d7b939266138c639b13beef40a5c4276e7d Mon Sep 17 00:00:00 2001 From: Scott Davidson Date: Mon, 9 Jan 2023 15:44:02 +0000 Subject: [PATCH 24/33] Fix cinder-backup group --- .../aufn-ceph/kolla/inventory/overcloud-services.j2 | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/etc/kayobe/environments/aufn-ceph/kolla/inventory/overcloud-services.j2 b/etc/kayobe/environments/aufn-ceph/kolla/inventory/overcloud-services.j2 index 964b3369a..313c3ba58 100644 --- a/etc/kayobe/environments/aufn-ceph/kolla/inventory/overcloud-services.j2 +++ b/etc/kayobe/environments/aufn-ceph/kolla/inventory/overcloud-services.j2 @@ -115,7 +115,7 @@ neutron cinder [cinder-backup:children] -storage +cinder [cinder-scheduler:children] cinder From a479267e9d0b1cffed1a3cd46508816ad84b33a2 Mon Sep 17 00:00:00 2001 From: Scott Davidson Date: Mon, 9 Jan 2023 15:45:43 +0000 Subject: [PATCH 25/33] Remove explicit node refs --- etc/kayobe/environments/aufn-ceph/inventory/groups | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/etc/kayobe/environments/aufn-ceph/inventory/groups b/etc/kayobe/environments/aufn-ceph/inventory/groups index eba2264e0..2834d37ba 100644 --- a/etc/kayobe/environments/aufn-ceph/inventory/groups +++ b/etc/kayobe/environments/aufn-ceph/inventory/groups @@ -4,10 +4,8 @@ ############################################################################### # Ceph groups +# Empty group with hosts added in overcloud.yml [storage-ceph] -storage0 -storage1 -storage2 [mons:children] storage-ceph From a9ec6ade82739c1122da2e01eae7e1a5f86e470c Mon Sep 17 00:00:00 2001 From: Scott Davidson Date: Mon, 9 Jan 2023 15:46:02 +0000 Subject: [PATCH 26/33] Bug fixes --- .../environments/aufn-ceph/a-universe-from-nothing.sh | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/etc/kayobe/environments/aufn-ceph/a-universe-from-nothing.sh b/etc/kayobe/environments/aufn-ceph/a-universe-from-nothing.sh index ae2cd3c17..ff9bd0b0f 100755 --- a/etc/kayobe/environments/aufn-ceph/a-universe-from-nothing.sh +++ b/etc/kayobe/environments/aufn-ceph/a-universe-from-nothing.sh @@ -127,7 +127,7 @@ kayobe overcloud post configure source $KOLLA_CONFIG_PATH/public-openrc.sh -# Use Jack's openstack-config-multinode here instead of init-runonce.sh script from standard aufn +# Use openstack-config-multinode here instead of init-runonce.sh script from standard aufn #Deactivate current kayobe venv set +u @@ -138,14 +138,14 @@ $KAYOBE_CONFIG_PATH/environments/$KAYOBE_ENVIRONMENT/configure-openstack.sh $BAS # Create a test vm VENV_DIR=$BASE_PATH/venvs/openstack if [[ ! -d $VENV_DIR ]]; then - virtualenv $VENV_DIR + python3 -m venv $VENV_DIR fi source $VENV_DIR/bin/activate pip install -U pip pip install python-openstackclient source $KOLLA_CONFIG_PATH/public-openrc.sh echo "Creating openstack key:" -openstack keypair create --private-key ~/.ssh/id_rsa mykey +openstack keypair create --public-key ~/.ssh/id_rsa.pub mykey echo "Creating test vm:" openstack server create --key-name mykey --flavor m1.tiny --image cirros --network admin-geneve test-vm-1 echo "Attaching floating IP:" From 8da9c2f94c32e3c349204792b91bf4e95b4e662a Mon Sep 17 00:00:00 2001 From: Scott Davidson Date: Tue, 10 Jan 2023 15:30:56 +0000 Subject: [PATCH 27/33] Use generic network type in openstack-config --- etc/kayobe/environments/aufn-ceph/a-universe-from-nothing.sh | 2 +- etc/kayobe/environments/aufn-ceph/configure-openstack.sh | 4 ++-- etc/kayobe/environments/aufn-ceph/neutron.yml | 2 -- 3 files changed, 3 insertions(+), 5 deletions(-) diff --git a/etc/kayobe/environments/aufn-ceph/a-universe-from-nothing.sh b/etc/kayobe/environments/aufn-ceph/a-universe-from-nothing.sh index ff9bd0b0f..d5ac06518 100755 --- a/etc/kayobe/environments/aufn-ceph/a-universe-from-nothing.sh +++ b/etc/kayobe/environments/aufn-ceph/a-universe-from-nothing.sh @@ -147,7 +147,7 @@ source $KOLLA_CONFIG_PATH/public-openrc.sh echo "Creating openstack key:" openstack keypair create --public-key ~/.ssh/id_rsa.pub mykey echo "Creating test vm:" -openstack server create --key-name mykey --flavor m1.tiny --image cirros --network admin-geneve test-vm-1 +openstack server create --key-name mykey --flavor m1.tiny --image cirros --network admin-tenant test-vm-1 echo "Attaching floating IP:" openstack floating ip create external openstack server add floating ip test-vm-1 `openstack floating ip list -c ID -f value` diff --git a/etc/kayobe/environments/aufn-ceph/configure-openstack.sh b/etc/kayobe/environments/aufn-ceph/configure-openstack.sh index b683da165..174f97018 100755 --- a/etc/kayobe/environments/aufn-ceph/configure-openstack.sh +++ b/etc/kayobe/environments/aufn-ceph/configure-openstack.sh @@ -1,9 +1,9 @@ #!/bin/bash -BASE_PATH=~ +BASE_PATH=$1 VENV_DIR=$BASE_PATH/venvs/ansible cd $BASE_PATH/src/ -[[ -d openstack-config ]] || git clone https://github.com/stackhpc/openstack-config-multinode.git -b geneve openstack-config +[[ -d openstack-config ]] || git clone https://github.com/stackhpc/openstack-config-multinode.git -b generic-network openstack-config cd openstack-config if [[ ! -d $VENV_DIR ]]; then # Using virtualenv causes a strange bug with python3.6 where diff --git a/etc/kayobe/environments/aufn-ceph/neutron.yml b/etc/kayobe/environments/aufn-ceph/neutron.yml index d2c5f6428..258c0a15f 100644 --- a/etc/kayobe/environments/aufn-ceph/neutron.yml +++ b/etc/kayobe/environments/aufn-ceph/neutron.yml @@ -5,11 +5,9 @@ kolla_neutron_ml2_network_vlan_ranges: kolla_neutron_ml2_type_drivers: - flat - vlan - - vxlan - geneve kolla_neutron_ml2_tenant_network_types: - flat - vlan - - vxlan - geneve From dd31fe499f3ef392374f77b37dec57cd1d1df61e Mon Sep 17 00:00:00 2001 From: Scott Davidson Date: Tue, 10 Jan 2023 16:32:18 +0000 Subject: [PATCH 28/33] Update remote checkout branch --- etc/kayobe/environments/aufn-ceph/configure-openstack.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/etc/kayobe/environments/aufn-ceph/configure-openstack.sh b/etc/kayobe/environments/aufn-ceph/configure-openstack.sh index 174f97018..2129bc122 100755 --- a/etc/kayobe/environments/aufn-ceph/configure-openstack.sh +++ b/etc/kayobe/environments/aufn-ceph/configure-openstack.sh @@ -3,7 +3,7 @@ BASE_PATH=$1 VENV_DIR=$BASE_PATH/venvs/ansible cd $BASE_PATH/src/ -[[ -d openstack-config ]] || git clone https://github.com/stackhpc/openstack-config-multinode.git -b generic-network openstack-config +[[ -d openstack-config ]] || git clone https://github.com/stackhpc/openstack-config-multinode.git openstack-config cd openstack-config if [[ ! -d $VENV_DIR ]]; then # Using virtualenv causes a strange bug with python3.6 where From 9960aa50cd3a39a7e450b4622c6bd873f69ac985 Mon Sep 17 00:00:00 2001 From: Scott Davidson Date: Wed, 11 Jan 2023 14:11:12 +0000 Subject: [PATCH 29/33] Point to correct kayobe config branch --- etc/kayobe/environments/aufn-ceph/a-universe-from-nothing.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/etc/kayobe/environments/aufn-ceph/a-universe-from-nothing.sh b/etc/kayobe/environments/aufn-ceph/a-universe-from-nothing.sh index d5ac06518..e594ea388 100755 --- a/etc/kayobe/environments/aufn-ceph/a-universe-from-nothing.sh +++ b/etc/kayobe/environments/aufn-ceph/a-universe-from-nothing.sh @@ -11,7 +11,7 @@ set -eu BASE_PATH=~ KAYOBE_BRANCH=stackhpc/yoga -KAYOBE_CONFIG_BRANCH=yoga-aufn +KAYOBE_CONFIG_BRANCH=stackhpc/yoga KAYOBE_ENVIRONMENT=aufn-ceph PELICAN_HOST="10.0.0.34 pelican pelican.service.compute.sms-lab.cloud" From abc29e6d3eb8e2ed7597338a5e70ebe25a0e9504 Mon Sep 17 00:00:00 2001 From: Scott Davidson Date: Wed, 18 Jan 2023 14:37:57 +0000 Subject: [PATCH 30/33] Improve Ubuntu support --- .../environments/aufn-ceph/configure-local-networking.sh | 3 +++ 1 file changed, 3 insertions(+) diff --git a/etc/kayobe/environments/aufn-ceph/configure-local-networking.sh b/etc/kayobe/environments/aufn-ceph/configure-local-networking.sh index ac8825758..f74174eab 100755 --- a/etc/kayobe/environments/aufn-ceph/configure-local-networking.sh +++ b/etc/kayobe/environments/aufn-ceph/configure-local-networking.sh @@ -25,6 +25,9 @@ forwarded_ports="80 6080" # Install iptables. if $(which dnf >/dev/null 2>&1); then sudo dnf -y install iptables +else + sudo apt update + sudo apt -y install iptables fi # Configure local networking. From 066ad7b1c428937566d477d71ac8cbf0e9680c21 Mon Sep 17 00:00:00 2001 From: Scott Davidson Date: Wed, 18 Jan 2023 14:46:20 +0000 Subject: [PATCH 31/33] Improve Ubuntu support --- etc/kayobe/environments/aufn-ceph/configure-local-networking.sh | 1 + 1 file changed, 1 insertion(+) diff --git a/etc/kayobe/environments/aufn-ceph/configure-local-networking.sh b/etc/kayobe/environments/aufn-ceph/configure-local-networking.sh index f74174eab..ab3602d2a 100755 --- a/etc/kayobe/environments/aufn-ceph/configure-local-networking.sh +++ b/etc/kayobe/environments/aufn-ceph/configure-local-networking.sh @@ -58,6 +58,7 @@ sudo sysctl -w net.ipv4.conf.all.forwarding=1 # FIXME: IP MASQUERADE from control plane fails without this on Ubuntu. if ! $(which dnf >/dev/null 2>&1); then + sudo modprobe br_netfilter echo 0 | sudo tee /proc/sys/net/bridge/bridge-nf-call-iptables fi From 3a96d9bce5d97ac815ab1cac9fdb63963b8ce9a0 Mon Sep 17 00:00:00 2001 From: Scott Davidson Date: Wed, 18 Jan 2023 14:55:48 +0000 Subject: [PATCH 32/33] pep8 fixes --- etc/kayobe/environments/aufn-ceph/globals.yml | 1 - .../environments/aufn-ceph/kolla/config/bifrost/bifrost.yml | 2 +- etc/kayobe/environments/aufn-ceph/network-allocation.yml | 1 + etc/kayobe/environments/aufn-ceph/networks.yml | 2 -- 4 files changed, 2 insertions(+), 4 deletions(-) diff --git a/etc/kayobe/environments/aufn-ceph/globals.yml b/etc/kayobe/environments/aufn-ceph/globals.yml index feab452ca..2eb8232c6 100644 --- a/etc/kayobe/environments/aufn-ceph/globals.yml +++ b/etc/kayobe/environments/aufn-ceph/globals.yml @@ -11,4 +11,3 @@ os_distribution: "{{ lookup('pipe', '. /etc/os-release && echo $ID') | trim }}" # OS release. Valid options are "8-stream" when os_distribution is "centos", or # "focal" when os_distribution is "ubuntu". #os_release: - diff --git a/etc/kayobe/environments/aufn-ceph/kolla/config/bifrost/bifrost.yml b/etc/kayobe/environments/aufn-ceph/kolla/config/bifrost/bifrost.yml index 1c06e1a2d..fbbf2805b 100644 --- a/etc/kayobe/environments/aufn-ceph/kolla/config/bifrost/bifrost.yml +++ b/etc/kayobe/environments/aufn-ceph/kolla/config/bifrost/bifrost.yml @@ -9,4 +9,4 @@ use_cirros: true cirros_deploy_image_upstream_url: "https://cloud-images.ubuntu.com/focal/current/focal-server-cloudimg-amd64.img" {% else %} cirros_deploy_image_upstream_url: "https://cloud.centos.org/centos/8-stream/x86_64/images/CentOS-Stream-GenericCloud-8-20220913.0.x86_64.qcow2" -{% endif %} \ No newline at end of file +{% endif %} diff --git a/etc/kayobe/environments/aufn-ceph/network-allocation.yml b/etc/kayobe/environments/aufn-ceph/network-allocation.yml index 8d6c826fa..ba8a1241c 100644 --- a/etc/kayobe/environments/aufn-ceph/network-allocation.yml +++ b/etc/kayobe/environments/aufn-ceph/network-allocation.yml @@ -1,3 +1,4 @@ +--- provision_oc_ips: compute0: 192.168.33.6 compute1: 192.168.33.7 diff --git a/etc/kayobe/environments/aufn-ceph/networks.yml b/etc/kayobe/environments/aufn-ceph/networks.yml index 5706e3bc8..4b1178110 100644 --- a/etc/kayobe/environments/aufn-ceph/networks.yml +++ b/etc/kayobe/environments/aufn-ceph/networks.yml @@ -115,5 +115,3 @@ storage_mgmt_physical_network: cloud # MichaelRigart interfaces configuration. interfaces_pause_time: 5 - - From 92eb7bbb3247c6672ac50afdd56ea67678bd2600 Mon Sep 17 00:00:00 2001 From: Scott Davidson <49713135+sd109@users.noreply.github.com> Date: Thu, 19 Jan 2023 10:44:57 +0000 Subject: [PATCH 33/33] Update etc/kayobe/environments/aufn-ceph/kolla/config/bifrost/bifrost.yml Co-authored-by: Mark Goddard --- .../environments/aufn-ceph/kolla/config/bifrost/bifrost.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/etc/kayobe/environments/aufn-ceph/kolla/config/bifrost/bifrost.yml b/etc/kayobe/environments/aufn-ceph/kolla/config/bifrost/bifrost.yml index fbbf2805b..5f981c201 100644 --- a/etc/kayobe/environments/aufn-ceph/kolla/config/bifrost/bifrost.yml +++ b/etc/kayobe/environments/aufn-ceph/kolla/config/bifrost/bifrost.yml @@ -1,3 +1,4 @@ +# yamllint disable-file --- # Don't build an IPA deployment image, instead download upstream images. create_ipa_image: false