Added Openstack Senlin role deployment

This commit adds experimental deployment of Senlin role.

Change-Id: I1e116518ec437c1634ea9d40172e424c73da56d5
This commit is contained in:
Dmitriy Rabotyagov 2020-09-02 18:44:03 +03:00 committed by Jonathan Rosser
parent 72a39d652a
commit 3214d6fbc3
16 changed files with 175 additions and 1 deletions

View File

@ -188,6 +188,11 @@
src: https://opendev.org/openstack/openstack-ansible-os_sahara src: https://opendev.org/openstack/openstack-ansible-os_sahara
version: master version: master
trackbranch: master trackbranch: master
- name: os_senlin
scm: git
src: https://opendev.org/openstack/openstack-ansible-os_senlin
version: master
trackbranch: master
- name: os_swift - name: os_swift
scm: git scm: git
src: https://opendev.org/openstack/openstack-ansible-os_swift src: https://opendev.org/openstack/openstack-ansible-os_swift

View File

@ -166,6 +166,8 @@ OpenStack service roles
- :role_docs:`os_sahara` - :role_docs:`os_sahara`
- :role_docs:`os_senlin`
- :role_docs:`os_swift` - :role_docs:`os_swift`
- :role_docs:`os_tempest` - :role_docs:`os_tempest`

View File

@ -291,7 +291,7 @@
<tr class="warning"> <tr class="warning">
<td>os_panko</td> <td>os_panko</td>
<td>Rocky</td> <td>Rocky</td>
<td>Inclubated</td> <td>Incubated</td>
<td></td> <td></td>
<td></td> <td></td>
<td></td> <td></td>
@ -315,6 +315,15 @@
<td></td> <td></td>
<td></td> <td></td>
</tr> </tr>
<tr class="warning">
<td>os_senlin</td>
<td>Ussuri</td>
<td>Inclubated</td>
<td></td>
<td></td>
<td></td>
<td></td>
</tr>
<tr > <tr >
<td>os_swift</td> <td>os_swift</td>
<td>Mitaka</td> <td>Mitaka</td>

View File

@ -0,0 +1,4 @@
# The controller host that the senlin control plane will be run on
senlin-infra_hosts:
aio1:
ip: 172.29.236.100

View File

@ -0,0 +1,8 @@
# The infra nodes that will be running the senlin services
senlin-infra_hosts:
infra1:
ip: 172.20.236.111
infra2:
ip: 172.20.236.112
infra3:
ip: 172.20.236.113

View File

@ -163,6 +163,13 @@ sahara_oslomsg_rpc_password:
#sahara_oslomsg_notify_password: #sahara_oslomsg_notify_password:
sahara_service_password: sahara_service_password:
## Senlin Options:
senlin_galera_password:
senlin_oslomsg_rpc_password:
senlin_service_password:
## Swift Options: ## Swift Options:
swift_service_password: swift_service_password:
swift_dispersion_password: swift_dispersion_password:

View File

@ -0,0 +1,31 @@
component_skel:
senlin_api:
belongs_to:
- senlin_all
senlin_engine:
belongs_to:
- senlin_all
senlin_conductor:
belongs_to:
- senlin_all
senlin_health_manager:
belongs_to:
- senlin_all
container_skel:
senlin_container:
belongs_to:
- senlin-infra_containers
contains:
- senlin_api
- senlin_engine
- senlin_conductor
- senlin_health_manager
physical_skel:
senlin-infra_containers:
belongs_to:
- all_containers
senlin-infra_hosts:
belongs_to:
- hosts

View File

@ -227,6 +227,16 @@ haproxy_default_services:
haproxy_backend_options: haproxy_backend_options:
- "httpchk GET /healthcheck HTTP/1.0\\r\\nUser-agent:\\ osa-haproxy-healthcheck" - "httpchk GET /healthcheck HTTP/1.0\\r\\nUser-agent:\\ osa-haproxy-healthcheck"
haproxy_service_enabled: "{{ groups['sahara_api'] is defined and groups['sahara_api'] | length > 0 }}" haproxy_service_enabled: "{{ groups['sahara_api'] is defined and groups['sahara_api'] | length > 0 }}"
- service:
haproxy_service_name: senlin_api
haproxy_backend_nodes: "{{ groups['senlin_api'] | default([]) }}"
haproxy_ssl: "{{ haproxy_ssl }}"
haproxy_ssl_all_vips: "{{ haproxy_ssl_all_vips }}"
haproxy_port: 8778
haproxy_balance_type: http
haproxy_backend_options:
- "httpchk GET / HTTP/1.0\\r\\nUser-agent:\\ osa-haproxy-healthcheck"
haproxy_service_enabled: "{{ groups['senlin_api'] is defined and groups['senlin_api'] | length > 0 }}"
- service: - service:
haproxy_service_name: swift_proxy haproxy_service_name: swift_proxy
haproxy_backend_nodes: "{{ groups['swift_proxy'] | default([]) }}" haproxy_backend_nodes: "{{ groups['swift_proxy'] | default([]) }}"

View File

@ -28,6 +28,7 @@ horizon_enable_designate_ui: "{{ (groups['designate_all'] is defined) and (group
horizon_enable_octavia_ui: "{{ (groups['octavia-infra_all'] is defined) and (groups['octavia-infra_all'] | length > 0) }}" horizon_enable_octavia_ui: "{{ (groups['octavia-infra_all'] is defined) and (groups['octavia-infra_all'] | length > 0) }}"
horizon_enable_neutron_fwaas: "{{ neutron_plugin_base is defined and (neutron_plugin_base | intersect(['firewall', 'firewall_v2']) | length > 0) }}" horizon_enable_neutron_fwaas: "{{ neutron_plugin_base is defined and (neutron_plugin_base | intersect(['firewall', 'firewall_v2']) | length > 0) }}"
horizon_enable_neutron_vpnaas: "{{ neutron_plugin_base is defined and 'vpnaas' in neutron_plugin_base }}" horizon_enable_neutron_vpnaas: "{{ neutron_plugin_base is defined and 'vpnaas' in neutron_plugin_base }}"
horizon_enable_senlin_ui: "{{ (groups['senlin_all'] is defined) and (groups['senlin_all'] | length > 0) }}"
horizon_enable_ha_router: "{{ neutron_plugin_type.split('.')[0] == 'ml2' and (groups['neutron_l3_agent'] | length >= 2) }}" horizon_enable_ha_router: "{{ neutron_plugin_type.split('.')[0] == 'ml2' and (groups['neutron_l3_agent'] | length >= 2) }}"
# Ensure that the package state matches the global setting # Ensure that the package state matches the global setting

View File

@ -230,6 +230,16 @@ sahara_engine
[sahara_api] [sahara_api]
[sahara_engine] [sahara_engine]
[senlin_all:children]
senlin_api
senlin_engine
senlin_conductor
senlin_health_manager
[senlin_api]
[senlin_engine]
[senlin_conductor]
[senlin_health_manager]
[swift_all:children] [swift_all:children]
swift_acc swift_acc
swift_cont swift_cont

View File

@ -205,6 +205,13 @@ sahara_git_project_group: sahara_all
sahara_git_track_branch: master sahara_git_track_branch: master
## Senlin service
senlin_git_repo: https://opendev.org/openstack/senlin
senlin_git_install_branch: 585bd14c70415b63265321cc7728b4e8c50702a7 # HEAD as of 02.09.2020
senlin_git_project_group: senlin_all
senlin_git_track_branch: master
## Swift service ## Swift service
swift_git_repo: https://opendev.org/openstack/swift swift_git_repo: https://opendev.org/openstack/swift
swift_git_install_branch: 0fa259e7beecaf0dd8e3d342ffbf1ec4a2b23864 # HEAD as of 23.08.2020 swift_git_install_branch: 0fa259e7beecaf0dd8e3d342ffbf1ec4a2b23864 # HEAD as of 23.08.2020

View File

@ -0,0 +1,62 @@
---
# Copyright 2020, City Network International AB
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
- name: Gather senlin facts
hosts: senlin_all
gather_facts: "{{ osa_gather_facts | default(True) }}"
tags:
- always
- name: Install senlin services
hosts: senlin_all
gather_facts: false
user: root
environment: "{{ deployment_environment_variables | default({}) }}"
vars_files:
- "defaults/repo_packages/openstack_services.yml"
- "defaults/{{ install_method }}_install.yml"
tags:
- senlin
pre_tasks:
# In order to ensure that any container, software or
# config file changes which causes a container/service
# restart do not cause an unexpected outage, we drain
# the load balancer back end for this container.
- include_tasks: common-tasks/haproxy-endpoint-manage.yml
vars:
haproxy_backend: senlin_api-back
haproxy_state: disabled
when:
- "'senlin_api' in group_names"
- "groups['senlin_api'] | length > 1"
- include_tasks: common-tasks/unbound-clients.yml
when:
- hostvars['localhost']['resolvconf_enabled'] | bool
roles:
- role: "os_senlin"
post_tasks:
# Now that container changes are done, we can set
# the load balancer back end for this container
# to available again.
- include_tasks: common-tasks/haproxy-endpoint-manage.yml
vars:
haproxy_backend: senlin_api-back
haproxy_state: enabled
when:
- "'senlin_api' in group_names"
- "groups['senlin_api'] | length > 1"

View File

@ -32,6 +32,7 @@
- import_playbook: os-magnum-install.yml - import_playbook: os-magnum-install.yml
- import_playbook: os-trove-install.yml - import_playbook: os-trove-install.yml
- import_playbook: os-sahara-install.yml - import_playbook: os-sahara-install.yml
- import_playbook: os-senlin-install.yml
- import_playbook: os-octavia-install.yml - import_playbook: os-octavia-install.yml
- import_playbook: os-tacker-install.yml - import_playbook: os-tacker-install.yml
- import_playbook: os-blazar-install.yml - import_playbook: os-blazar-install.yml

View File

@ -0,0 +1,6 @@
---
features:
- |
Experimental support has been added to allow the deployment of the
OpenStack Senlin service when hosts are present in the host group
``senlin-infra_hosts``.

View File

@ -450,6 +450,15 @@ class TestAnsibleInventoryFormatConstraints(unittest.TestCase):
'sahara_api', 'sahara_api',
'sahara_container', 'sahara_container',
'sahara_engine', 'sahara_engine',
'senlin-infra_all',
'senlin-infra_containers',
'senlin-infra_hosts',
'senlin_all',
'senlin_api',
'senlin_container',
'senlin_engine',
'senlin_conductor',
'senlin_health_manager',
'shared-infra_all', 'shared-infra_all',
'shared-infra_containers', 'shared-infra_containers',
'shared-infra_hosts', 'shared-infra_hosts',

View File

@ -60,6 +60,7 @@
- name: openstack/openstack-ansible-os_placement - name: openstack/openstack-ansible-os_placement
- name: openstack/openstack-ansible-os_rally - name: openstack/openstack-ansible-os_rally
- name: openstack/openstack-ansible-os_sahara - name: openstack/openstack-ansible-os_sahara
- name: openstack/openstack-ansible-os_senlin
- name: openstack/openstack-ansible-os_swift - name: openstack/openstack-ansible-os_swift
- name: openstack/openstack-ansible-os_tacker - name: openstack/openstack-ansible-os_tacker
- name: openstack/openstack-ansible-os_tempest - name: openstack/openstack-ansible-os_tempest
@ -107,6 +108,7 @@
- name: openstack/networking-sfc - name: openstack/networking-sfc
- name: openstack/nova - name: openstack/nova
- name: openstack/sahara - name: openstack/sahara
- name: openstack/senlin
- name: openstack/swift - name: openstack/swift
- name: openstack/ironic - name: openstack/ironic
- name: openstack/ironic-inspector - name: openstack/ironic-inspector