Add Maskari base jobs
This introduces the most basic jobs for masakari. Change-Id: Ie62ea7ec96b8963b5d3815a9241cce964e8fafc2
This commit is contained in:
parent
e86fe0c26b
commit
ab6cfd1ef1
@ -2,5 +2,3 @@
|
|||||||
host=review.openstack.org
|
host=review.openstack.org
|
||||||
port=29418
|
port=29418
|
||||||
project=openstack/openstack-ansible-os_masakari.git
|
project=openstack/openstack-ansible-os_masakari.git
|
||||||
|
|
||||||
|
|
||||||
|
@ -1,115 +1,115 @@
|
|||||||
---
|
---
|
||||||
# Copyright (c) 2018 NTT DATA
|
# Copyright (c) 2018 NTT DATA
|
||||||
#
|
#
|
||||||
# Licensed under the Apache License, Version 2.0 (the "License");
|
# Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
# you may not use this file except in compliance with the License.
|
# you may not use this file except in compliance with the License.
|
||||||
# You may obtain a copy of the License at
|
# You may obtain a copy of the License at
|
||||||
#
|
#
|
||||||
# http://www.apache.org/licenses/LICENSE-2.0
|
# http://www.apache.org/licenses/LICENSE-2.0
|
||||||
#
|
#
|
||||||
# Unless required by applicable law or agreed to in writing, software
|
# Unless required by applicable law or agreed to in writing, software
|
||||||
# distributed under the License is distributed on an "AS IS" BASIS,
|
# distributed under the License is distributed on an "AS IS" BASIS,
|
||||||
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||||
# See the License for the specific language governing permissions and
|
# See the License for the specific language governing permissions and
|
||||||
# limitations under the License.
|
# limitations under the License.
|
||||||
|
|
||||||
## Verbosity Options
|
## Verbosity Options
|
||||||
debug: False
|
debug: False
|
||||||
|
|
||||||
masakari_role_project_group: masakari_all
|
masakari_role_project_group: masakari_all
|
||||||
|
|
||||||
# Set the package install state for distribution and pip packages
|
# Set the package install state for distribution and pip packages
|
||||||
# Options are 'present' and 'latest'
|
# Options are 'present' and 'latest'
|
||||||
masakari_package_state: "latest"
|
masakari_package_state: "latest"
|
||||||
masakari_pip_package_state: "latest"
|
masakari_pip_package_state: "latest"
|
||||||
|
|
||||||
masakari_git_repo: https://git.openstack.org/openstack/masakari
|
masakari_git_repo: https://git.openstack.org/openstack/masakari
|
||||||
masakari_git_install_branch: master
|
masakari_git_install_branch: master
|
||||||
masakari_developer_mode: false
|
masakari_developer_mode: false
|
||||||
masakari_developer_constraints:
|
masakari_developer_constraints:
|
||||||
- "git+{{ masakari_git_repo }}@{{ masakari_git_install_branch }}#egg=masakari"
|
- "git+{{ masakari_git_repo }}@{{ masakari_git_install_branch }}#egg=masakari"
|
||||||
|
|
||||||
## System info
|
## System info
|
||||||
masakari_system_user_name: masakari
|
masakari_system_user_name: masakari
|
||||||
masakari_system_group_name: masakari
|
masakari_system_group_name: masakari
|
||||||
masakari_system_shell: /bin/false
|
masakari_system_shell: /bin/false
|
||||||
masakari_system_comment: masakari system user
|
masakari_system_comment: masakari system user
|
||||||
masakari_system_user_home: "/var/lib/{{ masakari_system_user_name }}"
|
masakari_system_user_home: "/var/lib/{{ masakari_system_user_name }}"
|
||||||
|
|
||||||
# masakari packages that must be installed before anything else
|
# masakari packages that must be installed before anything else
|
||||||
masakari_requires_pip_packages:
|
masakari_requires_pip_packages:
|
||||||
- virtualenv
|
- virtualenv
|
||||||
- python-masakariclient
|
- python-masakariclient
|
||||||
- python-keystoneclient # Keystoneclient needed to OSA keystone lib
|
- python-keystoneclient # Keystoneclient needed to OSA keystone lib
|
||||||
|
|
||||||
|
|
||||||
# venv_download, even when true, will use the fallback method of building the
|
# venv_download, even when true, will use the fallback method of building the
|
||||||
# venv from scratch if the venv download fails.
|
# venv from scratch if the venv download fails.
|
||||||
masakari_venv_download: "{{ not masakari_developer_mode | bool }}"
|
masakari_venv_download: "{{ not masakari_developer_mode | bool }}"
|
||||||
|
|
||||||
# Name of the virtual env to deploy into
|
# Name of the virtual env to deploy into
|
||||||
masakari_bin: "/openstack/venvs/masakari-{{ masakari_venv_tag }}/bin"
|
masakari_bin: "/openstack/venvs/masakari-{{ masakari_venv_tag }}/bin"
|
||||||
|
|
||||||
# Common pip packages
|
# Common pip packages
|
||||||
masakari_pip_packages:
|
masakari_pip_packages:
|
||||||
- cryptography
|
- cryptography
|
||||||
- masakari
|
- masakari
|
||||||
- keystonemiddleware
|
- keystonemiddleware
|
||||||
- PyMySQL
|
- PyMySQL
|
||||||
- python-masakariclient
|
- python-masakariclient
|
||||||
- python-novaclient
|
- python-novaclient
|
||||||
- python-keystoneclient
|
- python-keystoneclient
|
||||||
- python-memcached
|
- python-memcached
|
||||||
- python-swiftclient
|
- python-swiftclient
|
||||||
- uwsgi
|
- uwsgi
|
||||||
- keystoneauth1
|
- keystoneauth1
|
||||||
|
|
||||||
## Tunable overrides
|
## Tunable overrides
|
||||||
masakari_api_paste_ini_overrides: {}
|
masakari_api_paste_ini_overrides: {}
|
||||||
masakari_masakari_conf_overrides: {}
|
masakari_masakari_conf_overrides: {}
|
||||||
masakari_policy_json_overrides: {}
|
masakari_policy_json_overrides: {}
|
||||||
masakari_api_init_overrides: {}
|
masakari_api_init_overrides: {}
|
||||||
|
|
||||||
## Service Type and Data
|
## Service Type and Data
|
||||||
masakari_service_region: RegionOne
|
masakari_service_region: RegionOne
|
||||||
masakari_service_name: masakari
|
masakari_service_name: masakari
|
||||||
masakari_service_port: 15868
|
masakari_service_port: 15868
|
||||||
masakari_service_proto: http
|
masakari_service_proto: http
|
||||||
masakari_service_registry_proto: "{{ masakari_service_proto }}"
|
masakari_service_registry_proto: "{{ masakari_service_proto }}"
|
||||||
masakari_service_publicuri_proto: "{{ openstack_service_publicuri_proto | default(masakari_service_proto) }}"
|
masakari_service_publicuri_proto: "{{ openstack_service_publicuri_proto | default(masakari_service_proto) }}"
|
||||||
masakari_service_adminuri_proto: "{{ openstack_service_adminuri_proto | default(masakari_service_proto) }}"
|
masakari_service_adminuri_proto: "{{ openstack_service_adminuri_proto | default(masakari_service_proto) }}"
|
||||||
masakari_service_internaluri_proto: "{{ openstack_service_internaluri_proto | default(masakari_service_proto) }}"
|
masakari_service_internaluri_proto: "{{ openstack_service_internaluri_proto | default(masakari_service_proto) }}"
|
||||||
masakari_service_type: ha
|
masakari_service_type: ha
|
||||||
masakari_service_description: "Masakari ha Service"
|
masakari_service_description: "Masakari ha Service"
|
||||||
masakari_service_user_name: masakari
|
masakari_service_user_name: masakari
|
||||||
masakari_service_project_name: service
|
masakari_service_project_name: service
|
||||||
masakari_service_project_domain_id: default
|
masakari_service_project_domain_id: default
|
||||||
masakari_service_user_domain_id: default
|
masakari_service_user_domain_id: default
|
||||||
masakari_service_publicuri: "{{ masakari_service_publicuri_proto }}://{{ external_lb_vip_address }}:{{ masakari_service_port }}"
|
masakari_service_publicuri: "{{ masakari_service_publicuri_proto }}://{{ external_lb_vip_address }}:{{ masakari_service_port }}"
|
||||||
masakari_service_publicurl: "{{ masakari_service_publicuri }}/v1/%(tenant_id)s"
|
masakari_service_publicurl: "{{ masakari_service_publicuri }}/v1/%(tenant_id)s"
|
||||||
masakari_service_internaluri: "{{ masakari_service_internaluri_proto }}://{{ internal_lb_vip_address }}:{{ masakari_service_port }}"
|
masakari_service_internaluri: "{{ masakari_service_internaluri_proto }}://{{ internal_lb_vip_address }}:{{ masakari_service_port }}"
|
||||||
masakari_service_internalurl: "{{ masakari_service_internaluri }}/v1/%(tenant_id)s"
|
masakari_service_internalurl: "{{ masakari_service_internaluri }}/v1/%(tenant_id)s"
|
||||||
masakari_service_adminuri: "{{ masakari_service_adminuri_proto }}://{{ internal_lb_vip_address }}:{{ masakari_service_port }}"
|
masakari_service_adminuri: "{{ masakari_service_adminuri_proto }}://{{ internal_lb_vip_address }}:{{ masakari_service_port }}"
|
||||||
masakari_service_adminurl: "{{ masakari_service_adminuri }}/v1/%(tenant_id)s"
|
masakari_service_adminurl: "{{ masakari_service_adminuri }}/v1/%(tenant_id)s"
|
||||||
|
|
||||||
masakari_service_in_ldap: false
|
masakari_service_in_ldap: false
|
||||||
|
|
||||||
masakari_role_name: admin
|
masakari_role_name: admin
|
||||||
masakari_api_bind_address: 0.0.0.0
|
masakari_api_bind_address: 0.0.0.0
|
||||||
masakari_api_service_port: 15868
|
masakari_api_service_port: 15868
|
||||||
|
|
||||||
## API options
|
## API options
|
||||||
masakari_enable_v1_api: True
|
masakari_enable_v1_api: True
|
||||||
|
|
||||||
masakari_etc_dir: /etc/masakari
|
masakari_etc_dir: /etc/masakari
|
||||||
masakari_log_dir: /var/log/masakari
|
masakari_log_dir: /var/log/masakari
|
||||||
masakari_config_options: --config-file {{ masakari_etc_dir }}/masakari.conf
|
masakari_config_options: --config-file {{ masakari_etc_dir }}/masakari.conf
|
||||||
|
|
||||||
## Services
|
## Services
|
||||||
masakari_services:
|
masakari_services:
|
||||||
masakari-api:
|
masakari-api:
|
||||||
group: masakari_api
|
group: masakari_api
|
||||||
service_name: masakari-api
|
service_name: masakari-api
|
||||||
masakari-engine:
|
masakari-engine:
|
||||||
group: masakari_engine
|
group: masakari_engine
|
||||||
service_name: masakari-engine
|
service_name: masakari-engine
|
||||||
|
@ -1,329 +1,329 @@
|
|||||||
#!/usr/bin/env python3
|
#!/usr/bin/env python3
|
||||||
|
|
||||||
# Copyright (c) 2018 NTT DATA
|
# Copyright (c) 2018 NTT DATA
|
||||||
#
|
#
|
||||||
# Licensed under the Apache License, Version 2.0 (the "License");
|
# Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
# you may not use this file except in compliance with the License.
|
# you may not use this file except in compliance with the License.
|
||||||
# You may obtain a copy of the License at
|
# You may obtain a copy of the License at
|
||||||
#
|
#
|
||||||
# http://www.apache.org/licenses/LICENSE-2.0
|
# http://www.apache.org/licenses/LICENSE-2.0
|
||||||
#
|
#
|
||||||
# Unless required by applicable law or agreed to in writing, software
|
# Unless required by applicable law or agreed to in writing, software
|
||||||
# distributed under the License is distributed on an "AS IS" BASIS,
|
# distributed under the License is distributed on an "AS IS" BASIS,
|
||||||
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||||
# See the License for the specific language governing permissions and
|
# See the License for the specific language governing permissions and
|
||||||
# limitations under the License
|
# limitations under the License
|
||||||
|
|
||||||
# This file is execfile()d with the current directory set to its
|
# This file is execfile()d with the current directory set to its
|
||||||
# containing dir.
|
# containing dir.
|
||||||
#
|
#
|
||||||
# Note that not all possible configuration values are present in this
|
# Note that not all possible configuration values are present in this
|
||||||
# autogenerated file.
|
# autogenerated file.
|
||||||
#
|
#
|
||||||
# All configuration values have a default; values that are commented out
|
# All configuration values have a default; values that are commented out
|
||||||
# serve to show the default.
|
# serve to show the default.
|
||||||
|
|
||||||
import pbr.version
|
import pbr.version
|
||||||
import os
|
import os
|
||||||
|
|
||||||
# If extensions (or modules to document with autodoc) are in another directory,
|
# If extensions (or modules to document with autodoc) are in another directory,
|
||||||
# add these directories to sys.path here. If the directory is relative to the
|
# add these directories to sys.path here. If the directory is relative to the
|
||||||
# documentation root, use os.path.abspath to make it absolute, like shown here.
|
# documentation root, use os.path.abspath to make it absolute, like shown here.
|
||||||
# sys.path.insert(0, os.path.abspath('.'))
|
# sys.path.insert(0, os.path.abspath('.'))
|
||||||
|
|
||||||
# -- General configuration ------------------------------------------------
|
# -- General configuration ------------------------------------------------
|
||||||
|
|
||||||
# If your documentation needs a minimal Sphinx version, state it here.
|
# If your documentation needs a minimal Sphinx version, state it here.
|
||||||
# needs_sphinx = '1.0'
|
# needs_sphinx = '1.0'
|
||||||
|
|
||||||
# Add any Sphinx extension module names here, as strings. They can be
|
# Add any Sphinx extension module names here, as strings. They can be
|
||||||
# extensions coming with Sphinx (named 'sphinx.ext.*') or your custom
|
# extensions coming with Sphinx (named 'sphinx.ext.*') or your custom
|
||||||
# ones.
|
# ones.
|
||||||
extensions = [
|
extensions = [
|
||||||
'openstackdocstheme',
|
'openstackdocstheme',
|
||||||
'sphinx.ext.autodoc',
|
'sphinx.ext.autodoc',
|
||||||
'sphinxmark'
|
'sphinxmark'
|
||||||
]
|
]
|
||||||
|
|
||||||
# Add any paths that contain templates here, relative to this directory.
|
# Add any paths that contain templates here, relative to this directory.
|
||||||
templates_path = ['_templates']
|
templates_path = ['_templates']
|
||||||
|
|
||||||
# The suffix(es) of source filenames.
|
# The suffix(es) of source filenames.
|
||||||
# You can specify multiple suffix as a list of string:
|
# You can specify multiple suffix as a list of string:
|
||||||
# source_suffix = ['.rst', '.md']
|
# source_suffix = ['.rst', '.md']
|
||||||
source_suffix = '.rst'
|
source_suffix = '.rst'
|
||||||
|
|
||||||
# The encoding of source files.
|
# The encoding of source files.
|
||||||
# source_encoding = 'utf-8-sig'
|
# source_encoding = 'utf-8-sig'
|
||||||
|
|
||||||
# The master toctree document.
|
# The master toctree document.
|
||||||
master_doc = 'index'
|
master_doc = 'index'
|
||||||
|
|
||||||
# General information about the project.
|
# General information about the project.
|
||||||
author = 'OpenStack-Ansible Contributors'
|
author = 'OpenStack-Ansible Contributors'
|
||||||
category = 'Miscellaneous'
|
category = 'Miscellaneous'
|
||||||
copyright = '2016-2018, OpenStack-Ansible Contributors'
|
copyright = '2016-2018, OpenStack-Ansible Contributors'
|
||||||
description = 'OpenStack-Ansible deploys OpenStack environments using Ansible.'
|
description = 'OpenStack-Ansible deploys OpenStack environments using Ansible.'
|
||||||
project = 'OpenStack-Ansible'
|
project = 'OpenStack-Ansible'
|
||||||
role_name = 'os_masakari'
|
role_name = 'os_masakari'
|
||||||
target_name = 'openstack-ansible-' + role_name
|
target_name = 'openstack-ansible-' + role_name
|
||||||
title = 'OpenStack-Ansible Documentation: ' + role_name + 'role'
|
title = 'OpenStack-Ansible Documentation: ' + role_name + 'role'
|
||||||
|
|
||||||
# The link to the browsable source code (for the left hand menu)
|
# The link to the browsable source code (for the left hand menu)
|
||||||
oslosphinx_cgit_link = (
|
oslosphinx_cgit_link = (
|
||||||
'https://git.openstack.org/cgit/openstack/{}'.format(target_name)
|
'https://git.openstack.org/cgit/openstack/{}'.format(target_name)
|
||||||
)
|
)
|
||||||
|
|
||||||
# The version info for the project you're documenting, acts as replacement for
|
# The version info for the project you're documenting, acts as replacement for
|
||||||
# |version| and |release|, also used in various other places throughout the
|
# |version| and |release|, also used in various other places throughout the
|
||||||
# built documents.
|
# built documents.
|
||||||
#
|
#
|
||||||
# The short X.Y version.
|
# The short X.Y version.
|
||||||
version_info = pbr.version.VersionInfo(target_name)
|
version_info = pbr.version.VersionInfo(target_name)
|
||||||
# The full version, including alpha/beta/rc tags.
|
# The full version, including alpha/beta/rc tags.
|
||||||
release = version_info.version_string_with_vcs()
|
release = version_info.version_string_with_vcs()
|
||||||
# The short X.Y version.
|
# The short X.Y version.
|
||||||
version = version_info.canonical_version_string()
|
version = version_info.canonical_version_string()
|
||||||
|
|
||||||
# openstackdocstheme options
|
# openstackdocstheme options
|
||||||
repository_name = 'openstack/' + target_name
|
repository_name = 'openstack/' + target_name
|
||||||
bug_project = project.lower()
|
bug_project = project.lower()
|
||||||
bug_tag = ''
|
bug_tag = ''
|
||||||
|
|
||||||
# The language for content autogenerated by Sphinx. Refer to documentation
|
# The language for content autogenerated by Sphinx. Refer to documentation
|
||||||
# for a list of supported languages.
|
# for a list of supported languages.
|
||||||
#
|
#
|
||||||
# This is also used if you do content translation via gettext catalogs.
|
# This is also used if you do content translation via gettext catalogs.
|
||||||
# Usually you set "language" from the command line for these cases.
|
# Usually you set "language" from the command line for these cases.
|
||||||
language = None
|
language = None
|
||||||
|
|
||||||
# There are two options for replacing |today|: either, you set today to some
|
# There are two options for replacing |today|: either, you set today to some
|
||||||
# non-false value, then it is used:
|
# non-false value, then it is used:
|
||||||
# today = ''
|
# today = ''
|
||||||
# Else, today_fmt is used as the format for a strftime call.
|
# Else, today_fmt is used as the format for a strftime call.
|
||||||
# today_fmt = '%B %d, %Y'
|
# today_fmt = '%B %d, %Y'
|
||||||
|
|
||||||
# List of patterns, relative to source directory, that match files and
|
# List of patterns, relative to source directory, that match files and
|
||||||
# directories to ignore when looking for source files.
|
# directories to ignore when looking for source files.
|
||||||
exclude_patterns = []
|
exclude_patterns = []
|
||||||
|
|
||||||
# The reST default role (used for this markup: `text`) to use for all
|
# The reST default role (used for this markup: `text`) to use for all
|
||||||
# documents.
|
# documents.
|
||||||
# default_role = None
|
# default_role = None
|
||||||
|
|
||||||
# If true, '()' will be appended to :func: etc. cross-reference text.
|
# If true, '()' will be appended to :func: etc. cross-reference text.
|
||||||
# add_function_parentheses = True
|
# add_function_parentheses = True
|
||||||
|
|
||||||
# If true, the current module name will be prepended to all description
|
# If true, the current module name will be prepended to all description
|
||||||
# unit titles (such as .. function::).
|
# unit titles (such as .. function::).
|
||||||
# add_module_names = True
|
# add_module_names = True
|
||||||
|
|
||||||
# If true, sectionauthor and moduleauthor directives will be shown in the
|
# If true, sectionauthor and moduleauthor directives will be shown in the
|
||||||
# output. They are ignored by default.
|
# output. They are ignored by default.
|
||||||
# show_authors = False
|
# show_authors = False
|
||||||
|
|
||||||
# The name of the Pygments (syntax highlighting) style to use.
|
# The name of the Pygments (syntax highlighting) style to use.
|
||||||
pygments_style = 'sphinx'
|
pygments_style = 'sphinx'
|
||||||
|
|
||||||
# A list of ignored prefixes for module index sorting.
|
# A list of ignored prefixes for module index sorting.
|
||||||
# modindex_common_prefix = []
|
# modindex_common_prefix = []
|
||||||
|
|
||||||
# If true, keep warnings as "system message" paragraphs in the built documents.
|
# If true, keep warnings as "system message" paragraphs in the built documents.
|
||||||
# keep_warnings = False
|
# keep_warnings = False
|
||||||
|
|
||||||
# If true, `todo` and `todoList` produce output, else they produce nothing.
|
# If true, `todo` and `todoList` produce output, else they produce nothing.
|
||||||
todo_include_todos = False
|
todo_include_todos = False
|
||||||
|
|
||||||
|
|
||||||
# -- Options for HTML output ----------------------------------------------
|
# -- Options for HTML output ----------------------------------------------
|
||||||
|
|
||||||
# The theme to use for HTML and HTML Help pages. See the documentation for
|
# The theme to use for HTML and HTML Help pages. See the documentation for
|
||||||
# a list of builtin themes.
|
# a list of builtin themes.
|
||||||
html_theme = 'openstackdocs'
|
html_theme = 'openstackdocs'
|
||||||
|
|
||||||
# Theme options are theme-specific and customize the look and feel of a theme
|
# Theme options are theme-specific and customize the look and feel of a theme
|
||||||
# further. For a list of options available for each theme, see the
|
# further. For a list of options available for each theme, see the
|
||||||
# documentation.
|
# documentation.
|
||||||
# html_theme_options = {}
|
# html_theme_options = {}
|
||||||
|
|
||||||
# Add any paths that contain custom themes here, relative to this directory.
|
# Add any paths that contain custom themes here, relative to this directory.
|
||||||
# html_theme_path = []
|
# html_theme_path = []
|
||||||
|
|
||||||
# The name for this set of Sphinx documents. If None, it defaults to
|
# The name for this set of Sphinx documents. If None, it defaults to
|
||||||
# "<project> v<release> documentation".
|
# "<project> v<release> documentation".
|
||||||
# html_title = None
|
# html_title = None
|
||||||
|
|
||||||
# A shorter title for the navigation bar. Default is the same as html_title.
|
# A shorter title for the navigation bar. Default is the same as html_title.
|
||||||
# html_short_title = None
|
# html_short_title = None
|
||||||
|
|
||||||
# The name of an image file (relative to this directory) to place at the top
|
# The name of an image file (relative to this directory) to place at the top
|
||||||
# of the sidebar.
|
# of the sidebar.
|
||||||
# html_logo = None
|
# html_logo = None
|
||||||
|
|
||||||
# The name of an image file (within the static path) to use as favicon of the
|
# The name of an image file (within the static path) to use as favicon of the
|
||||||
# docs. This file should be a Windows icon file (.ico) being 16x16 or 32x32
|
# docs. This file should be a Windows icon file (.ico) being 16x16 or 32x32
|
||||||
# pixels large.
|
# pixels large.
|
||||||
# html_favicon = None
|
# html_favicon = None
|
||||||
|
|
||||||
# Add any paths that contain custom static files (such as style sheets) here,
|
# Add any paths that contain custom static files (such as style sheets) here,
|
||||||
# relative to this directory. They are copied after the builtin static files,
|
# relative to this directory. They are copied after the builtin static files,
|
||||||
# so a file named "default.css" will overwrite the builtin "default.css".
|
# so a file named "default.css" will overwrite the builtin "default.css".
|
||||||
html_static_path = ['_static']
|
html_static_path = ['_static']
|
||||||
|
|
||||||
# Add any extra paths that contain custom files (such as robots.txt or
|
# Add any extra paths that contain custom files (such as robots.txt or
|
||||||
# .htaccess) here, relative to this directory. These files are copied
|
# .htaccess) here, relative to this directory. These files are copied
|
||||||
# directly to the root of the documentation.
|
# directly to the root of the documentation.
|
||||||
# html_extra_path = []
|
# html_extra_path = []
|
||||||
|
|
||||||
# If not '', a 'Last updated on:' timestamp is inserted at every page bottom,
|
# If not '', a 'Last updated on:' timestamp is inserted at every page bottom,
|
||||||
# using the given strftime format.
|
# using the given strftime format.
|
||||||
html_last_updated_fmt = '%Y-%m-%d %H:%M'
|
html_last_updated_fmt = '%Y-%m-%d %H:%M'
|
||||||
|
|
||||||
# If true, SmartyPants will be used to convert quotes and dashes to
|
# If true, SmartyPants will be used to convert quotes and dashes to
|
||||||
# typographically correct entities.
|
# typographically correct entities.
|
||||||
# html_use_smartypants = True
|
# html_use_smartypants = True
|
||||||
|
|
||||||
# Custom sidebar templates, maps document names to template names.
|
# Custom sidebar templates, maps document names to template names.
|
||||||
# html_sidebars = {}
|
# html_sidebars = {}
|
||||||
|
|
||||||
# Additional templates that should be rendered to pages, maps page names to
|
# Additional templates that should be rendered to pages, maps page names to
|
||||||
# template names.
|
# template names.
|
||||||
# html_additional_pages = {}
|
# html_additional_pages = {}
|
||||||
|
|
||||||
# If false, no module index is generated.
|
# If false, no module index is generated.
|
||||||
# html_domain_indices = True
|
# html_domain_indices = True
|
||||||
|
|
||||||
# If false, no index is generated.
|
# If false, no index is generated.
|
||||||
# html_use_index = True
|
# html_use_index = True
|
||||||
|
|
||||||
# If true, the index is split into individual pages for each letter.
|
# If true, the index is split into individual pages for each letter.
|
||||||
# html_split_index = False
|
# html_split_index = False
|
||||||
|
|
||||||
# If true, links to the reST sources are added to the pages.
|
# If true, links to the reST sources are added to the pages.
|
||||||
# html_show_sourcelink = True
|
# html_show_sourcelink = True
|
||||||
|
|
||||||
# If true, "Created using Sphinx" is shown in the HTML footer. Default is True.
|
# If true, "Created using Sphinx" is shown in the HTML footer. Default is True.
|
||||||
# html_show_sphinx = True
|
# html_show_sphinx = True
|
||||||
|
|
||||||
# If true, "(C) Copyright ..." is shown in the HTML footer. Default is True.
|
# If true, "(C) Copyright ..." is shown in the HTML footer. Default is True.
|
||||||
# html_show_copyright = True
|
# html_show_copyright = True
|
||||||
|
|
||||||
# If true, an OpenSearch description file will be output, and all pages will
|
# If true, an OpenSearch description file will be output, and all pages will
|
||||||
# contain a <link> tag referring to it. The value of this option must be the
|
# contain a <link> tag referring to it. The value of this option must be the
|
||||||
# base URL from which the finished HTML is served.
|
# base URL from which the finished HTML is served.
|
||||||
# html_use_opensearch = ''
|
# html_use_opensearch = ''
|
||||||
|
|
||||||
# This is the file name suffix for HTML files (e.g. ".xhtml").
|
# This is the file name suffix for HTML files (e.g. ".xhtml").
|
||||||
# html_file_suffix = None
|
# html_file_suffix = None
|
||||||
|
|
||||||
# Language to be used for generating the HTML full-text search index.
|
# Language to be used for generating the HTML full-text search index.
|
||||||
# Sphinx supports the following languages:
|
# Sphinx supports the following languages:
|
||||||
# 'da', 'de', 'en', 'es', 'fi', 'fr', 'h', 'it', 'ja'
|
# 'da', 'de', 'en', 'es', 'fi', 'fr', 'h', 'it', 'ja'
|
||||||
# 'nl', 'no', 'pt', 'ro', 'r', 'sv', 'tr'
|
# 'nl', 'no', 'pt', 'ro', 'r', 'sv', 'tr'
|
||||||
# html_search_language = 'en'
|
# html_search_language = 'en'
|
||||||
|
|
||||||
# A dictionary with options for the search language support, empty by default.
|
# A dictionary with options for the search language support, empty by default.
|
||||||
# Now only 'ja' uses this config value
|
# Now only 'ja' uses this config value
|
||||||
# html_search_options = {'type': 'default'}
|
# html_search_options = {'type': 'default'}
|
||||||
|
|
||||||
# The name of a javascript file (relative to the configuration directory) that
|
# The name of a javascript file (relative to the configuration directory) that
|
||||||
# implements a search results scorer. If empty, the default will be used.
|
# implements a search results scorer. If empty, the default will be used.
|
||||||
# html_search_scorer = 'scorer.js'
|
# html_search_scorer = 'scorer.js'
|
||||||
|
|
||||||
# Output file base name for HTML help builder.
|
# Output file base name for HTML help builder.
|
||||||
htmlhelp_basename = target_name + '-docs'
|
htmlhelp_basename = target_name + '-docs'
|
||||||
|
|
||||||
# -- Options for LaTeX output ---------------------------------------------
|
# -- Options for LaTeX output ---------------------------------------------
|
||||||
|
|
||||||
latex_elements = {
|
latex_elements = {
|
||||||
# The paper size ('letterpaper' or 'a4paper').
|
# The paper size ('letterpaper' or 'a4paper').
|
||||||
# 'papersize': 'letterpaper',
|
# 'papersize': 'letterpaper',
|
||||||
|
|
||||||
# The font size ('10pt', '11pt' or '12pt').
|
# The font size ('10pt', '11pt' or '12pt').
|
||||||
# 'pointsize': '10pt',
|
# 'pointsize': '10pt',
|
||||||
|
|
||||||
# Additional stuff for the LaTeX preamble.
|
# Additional stuff for the LaTeX preamble.
|
||||||
# 'preamble': '',
|
# 'preamble': '',
|
||||||
|
|
||||||
# Latex figure (float) alignment
|
# Latex figure (float) alignment
|
||||||
# 'figure_align': 'htbp',
|
# 'figure_align': 'htbp',
|
||||||
}
|
}
|
||||||
|
|
||||||
# Grouping the document tree into LaTeX files. List of tuples
|
# Grouping the document tree into LaTeX files. List of tuples
|
||||||
# (source start file, target name, title,
|
# (source start file, target name, title,
|
||||||
# author, documentclass [howto, manual, or own class]).
|
# author, documentclass [howto, manual, or own class]).
|
||||||
latex_documents = [
|
latex_documents = [
|
||||||
(master_doc, target_name + '.tex',
|
(master_doc, target_name + '.tex',
|
||||||
title, author, 'manual'),
|
title, author, 'manual'),
|
||||||
]
|
]
|
||||||
|
|
||||||
# The name of an image file (relative to this directory) to place at the top of
|
# The name of an image file (relative to this directory) to place at the top of
|
||||||
# the title page.
|
# the title page.
|
||||||
# latex_logo = None
|
# latex_logo = None
|
||||||
|
|
||||||
# For "manual" documents, if this is true, then toplevel headings are parts,
|
# For "manual" documents, if this is true, then toplevel headings are parts,
|
||||||
# not chapters.
|
# not chapters.
|
||||||
# latex_use_parts = False
|
# latex_use_parts = False
|
||||||
|
|
||||||
# If true, show page references after internal links.
|
# If true, show page references after internal links.
|
||||||
# latex_show_pagerefs = False
|
# latex_show_pagerefs = False
|
||||||
|
|
||||||
# If true, show URL addresses after external links.
|
# If true, show URL addresses after external links.
|
||||||
# latex_show_urls = False
|
# latex_show_urls = False
|
||||||
|
|
||||||
# Documents to append as an appendix to all manuals.
|
# Documents to append as an appendix to all manuals.
|
||||||
# latex_appendices = []
|
# latex_appendices = []
|
||||||
|
|
||||||
# If false, no module index is generated.
|
# If false, no module index is generated.
|
||||||
# latex_domain_indices = True
|
# latex_domain_indices = True
|
||||||
|
|
||||||
|
|
||||||
# -- Options for manual page output ---------------------------------------
|
# -- Options for manual page output ---------------------------------------
|
||||||
|
|
||||||
# One entry per manual page. List of tuples
|
# One entry per manual page. List of tuples
|
||||||
# (source start file, name, description, authors, manual section).
|
# (source start file, name, description, authors, manual section).
|
||||||
man_pages = [
|
man_pages = [
|
||||||
(master_doc, target_name,
|
(master_doc, target_name,
|
||||||
title, [author], 1)
|
title, [author], 1)
|
||||||
]
|
]
|
||||||
|
|
||||||
# If true, show URL addresses after external links.
|
# If true, show URL addresses after external links.
|
||||||
# man_show_urls = False
|
# man_show_urls = False
|
||||||
|
|
||||||
|
|
||||||
# -- Options for Texinfo output -------------------------------------------
|
# -- Options for Texinfo output -------------------------------------------
|
||||||
|
|
||||||
# Grouping the document tree into Texinfo files. List of tuples
|
# Grouping the document tree into Texinfo files. List of tuples
|
||||||
# (source start file, target name, title, author,
|
# (source start file, target name, title, author,
|
||||||
# dir menu entry, description, category)
|
# dir menu entry, description, category)
|
||||||
texinfo_documents = [
|
texinfo_documents = [
|
||||||
(master_doc, target_name,
|
(master_doc, target_name,
|
||||||
title, author, project,
|
title, author, project,
|
||||||
description, category),
|
description, category),
|
||||||
]
|
]
|
||||||
|
|
||||||
# Documents to append as an appendix to all manuals.
|
# Documents to append as an appendix to all manuals.
|
||||||
# texinfo_appendices = []
|
# texinfo_appendices = []
|
||||||
|
|
||||||
# If false, no module index is generated.
|
# If false, no module index is generated.
|
||||||
# texinfo_domain_indices = True
|
# texinfo_domain_indices = True
|
||||||
|
|
||||||
# How to display URL addresses: 'footnote', 'no', or 'inline'.
|
# How to display URL addresses: 'footnote', 'no', or 'inline'.
|
||||||
# texinfo_show_urls = 'footnote'
|
# texinfo_show_urls = 'footnote'
|
||||||
|
|
||||||
# If true, do not generate a @detailmenu in the "Top" node's menu.
|
# If true, do not generate a @detailmenu in the "Top" node's menu.
|
||||||
# texinfo_no_detailmenu = False
|
# texinfo_no_detailmenu = False
|
||||||
|
|
||||||
|
|
||||||
watermark = os.popen("git branch --contains $(git rev-parse HEAD)\
|
watermark = os.popen("git branch --contains $(git rev-parse HEAD)\
|
||||||
| awk -F/ '/stable/ {print $2}'").read().strip(' \n\t').capitalize()
|
| awk -F/ '/stable/ {print $2}'").read().strip(' \n\t').capitalize()
|
||||||
if watermark == "":
|
if watermark == "":
|
||||||
watermark = "Pre-release"
|
watermark = "Pre-release"
|
||||||
|
|
||||||
# -- Options for sphinxmark -----------------------------------------------
|
# -- Options for sphinxmark -----------------------------------------------
|
||||||
sphinxmark_enable = True
|
sphinxmark_enable = True
|
||||||
sphinxmark_div = 'docs-body'
|
sphinxmark_div = 'docs-body'
|
||||||
sphinxmark_image = 'text'
|
sphinxmark_image = 'text'
|
||||||
sphinxmark_text = watermark
|
sphinxmark_text = watermark
|
||||||
sphinxmark_text_color = (128, 128, 128)
|
sphinxmark_text_color = (128, 128, 128)
|
||||||
sphinxmark_text_size = 70
|
sphinxmark_text_size = 70
|
||||||
|
@ -1 +1,2 @@
|
|||||||
<TODO>
|
<TODO>
|
||||||
|
|
||||||
|
@ -1,32 +1,32 @@
|
|||||||
==================================
|
====================================
|
||||||
Masakari role for OpenStack-Ansible
|
Masakari role for OpenStack-Ansible
|
||||||
==================================
|
====================================
|
||||||
|
|
||||||
:tags: openstack, masakari, cloud, ansible
|
:tags: openstack, masakari, cloud, ansible
|
||||||
:category: \*nix
|
:category: \*nix
|
||||||
|
|
||||||
To clone or view the source code for this repository, visit the role repository
|
To clone or view the source code for this repository, visit the role repository
|
||||||
for `os_masakari <https://github.com/openstack/openstack-ansible-os_masakari>`_.
|
for `os_masakari <https://github.com/openstack/openstack-ansible-os_masakari>`_.
|
||||||
|
|
||||||
Default variables
|
Default variables
|
||||||
~~~~~~~~~~~~~~~~~
|
~~~~~~~~~~~~~~~~~
|
||||||
|
|
||||||
.. literalinclude:: ../../defaults/main.yml
|
.. literalinclude:: ../../defaults/main.yml
|
||||||
:language: yaml
|
:language: yaml
|
||||||
:start-after: under the License.
|
:start-after: under the License.
|
||||||
|
|
||||||
Dependencies
|
Dependencies
|
||||||
~~~~~~~~~~~~
|
~~~~~~~~~~~~
|
||||||
|
|
||||||
<TODO>
|
<TODO>
|
||||||
|
|
||||||
Example playbook
|
Example playbook
|
||||||
~~~~~~~~~~~~~~~~
|
~~~~~~~~~~~~~~~~
|
||||||
|
|
||||||
.. literalinclude:: ../../examples/playbook.yml
|
.. literalinclude:: ../../examples/playbook.yml
|
||||||
:language: yaml
|
:language: yaml
|
||||||
|
|
||||||
Tags
|
Tags
|
||||||
~~~~
|
~~~~
|
||||||
|
|
||||||
<TODO>
|
<TODO>
|
||||||
|
@ -1,23 +1,23 @@
|
|||||||
---
|
---
|
||||||
# Copyright (c) 2018 NTT DATA
|
# Copyright (c) 2018 NTT DATA
|
||||||
#
|
#
|
||||||
# Licensed under the Apache License, Version 2.0 (the "License");
|
# Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
# you may not use this file except in compliance with the License.
|
# you may not use this file except in compliance with the License.
|
||||||
# You may obtain a copy of the License at
|
# You may obtain a copy of the License at
|
||||||
#
|
#
|
||||||
# http://www.apache.org/licenses/LICENSE-2.0
|
# http://www.apache.org/licenses/LICENSE-2.0
|
||||||
#
|
#
|
||||||
# Unless required by applicable law or agreed to in writing, software
|
# Unless required by applicable law or agreed to in writing, software
|
||||||
# distributed under the License is distributed on an "AS IS" BASIS,
|
# distributed under the License is distributed on an "AS IS" BASIS,
|
||||||
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||||
# See the License for the specific language governing permissions and
|
# See the License for the specific language governing permissions and
|
||||||
# limitations under the License.
|
# limitations under the License.
|
||||||
|
|
||||||
- name: Restart masakari services
|
- name: Restart masakari services
|
||||||
service:
|
service:
|
||||||
name: "{{ item.value.service_name }}"
|
name: "{{ item.value.service_name }}"
|
||||||
state: restarted
|
state: restarted
|
||||||
daemon_reload: yes
|
daemon_reload: yes
|
||||||
with_dict: "{{ masakari-services }}"
|
with_dict: "{{ masakari-services }}"
|
||||||
when: inventory_hostname in groups[item.value.group]
|
when: inventory_hostname in groups[item.value.group]
|
||||||
|
|
||||||
|
@ -1,45 +1,45 @@
|
|||||||
---
|
---
|
||||||
# Copyright (c) 2018 NTT DATA
|
# Copyright (c) 2018 NTT DATA
|
||||||
#
|
#
|
||||||
# Licensed under the Apache License, Version 2.0 (the "License");
|
# Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
# you may not use this file except in compliance with the License.
|
# you may not use this file except in compliance with the License.
|
||||||
# You may obtain a copy of the License at
|
# You may obtain a copy of the License at
|
||||||
#
|
#
|
||||||
# http://www.apache.org/licenses/LICENSE-2.0
|
# http://www.apache.org/licenses/LICENSE-2.0
|
||||||
#
|
#
|
||||||
# Unless required by applicable law or agreed to in writing, software
|
# Unless required by applicable law or agreed to in writing, software
|
||||||
# distributed under the License is distributed on an "AS IS" BASIS,
|
# distributed under the License is distributed on an "AS IS" BASIS,
|
||||||
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||||
# See the License for the specific language governing permissions and
|
# See the License for the specific language governing permissions and
|
||||||
# limitations under the License.
|
# limitations under the License.
|
||||||
|
|
||||||
galaxy_info:
|
galaxy_info:
|
||||||
author: niraj singh
|
author: niraj singh
|
||||||
description: Installation and setup of masakari
|
description: Installation and setup of masakari
|
||||||
company: NTT DATA
|
company: NTT DATA
|
||||||
license: Apache2
|
license: Apache2
|
||||||
min_ansible_version: 2.2
|
min_ansible_version: 2.2
|
||||||
platforms:
|
platforms:
|
||||||
- name: Ubuntu
|
- name: Ubuntu
|
||||||
versions:
|
versions:
|
||||||
- xenial
|
- xenial
|
||||||
- name: EL
|
- name: EL
|
||||||
versions:
|
versions:
|
||||||
- 7
|
- 7
|
||||||
- name: opensuse
|
- name: opensuse
|
||||||
versions:
|
versions:
|
||||||
- 42.1
|
- 42.1
|
||||||
- 42.2
|
- 42.2
|
||||||
- 42.3
|
- 42.3
|
||||||
categories:
|
categories:
|
||||||
- cloud
|
- cloud
|
||||||
- python
|
- python
|
||||||
- masakari
|
- masakari
|
||||||
- development
|
- development
|
||||||
- openstack
|
- openstack
|
||||||
dependencies:
|
dependencies:
|
||||||
- role: apt_package_pinning
|
- role: apt_package_pinning
|
||||||
when:
|
when:
|
||||||
- ansible_pkg_mgr == 'apt'
|
- ansible_pkg_mgr == 'apt'
|
||||||
- galera_client
|
- galera_client
|
||||||
- openstack_openrc
|
- openstack_openrc
|
||||||
|
@ -1,19 +1,19 @@
|
|||||||
---
|
---
|
||||||
# Copyright (c) 2018 NTT DATA
|
# Copyright (c) 2018 NTT DATA
|
||||||
#
|
#
|
||||||
# Licensed under the Apache License, Version 2.0 (the "License");
|
# Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
# you may not use this file except in compliance with the License.
|
# you may not use this file except in compliance with the License.
|
||||||
# You may obtain a copy of the License at
|
# You may obtain a copy of the License at
|
||||||
#
|
#
|
||||||
# http://www.apache.org/licenses/LICENSE-2.0
|
# http://www.apache.org/licenses/LICENSE-2.0
|
||||||
#
|
#
|
||||||
# Unless required by applicable law or agreed to in writing, software
|
# Unless required by applicable law or agreed to in writing, software
|
||||||
# distributed under the License is distributed on an "AS IS" BASIS,
|
# distributed under the License is distributed on an "AS IS" BASIS,
|
||||||
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||||
# See the License for the specific language governing permissions and
|
# See the License for the specific language governing permissions and
|
||||||
# limitations under the License.
|
# limitations under the License.
|
||||||
|
|
||||||
|
|
||||||
maturity_info:
|
maturity_info:
|
||||||
status: incubated
|
status: incubated
|
||||||
created_during: rocky
|
created_during: rocky
|
||||||
|
0
run_tests.sh
Normal file → Executable file
0
run_tests.sh
Normal file → Executable file
118
tasks/main.yml
118
tasks/main.yml
@ -1,59 +1,59 @@
|
|||||||
---
|
---
|
||||||
# Copyright (c) 2018 NTT DATA
|
# Copyright (c) 2018 NTT DATA
|
||||||
#
|
#
|
||||||
# Licensed under the Apache License, Version 2.0 (the "License");
|
# Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
# you may not use this file except in compliance with the License.
|
# you may not use this file except in compliance with the License.
|
||||||
# You may obtain a copy of the License at
|
# You may obtain a copy of the License at
|
||||||
#
|
#
|
||||||
# http://www.apache.org/licenses/LICENSE-2.0
|
# http://www.apache.org/licenses/LICENSE-2.0
|
||||||
#
|
#
|
||||||
# Unless required by applicable law or agreed to in writing, software
|
# Unless required by applicable law or agreed to in writing, software
|
||||||
# distributed under the License is distributed on an "AS IS" BASIS,
|
# distributed under the License is distributed on an "AS IS" BASIS,
|
||||||
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||||
# See the License for the specific language governing permissions and
|
# See the License for the specific language governing permissions and
|
||||||
# limitations under the License.
|
# limitations under the License.
|
||||||
|
|
||||||
- name: Gather variables for each operating system
|
- name: Gather variables for each operating system
|
||||||
include_vars: "{{ item }}"
|
include_vars: "{{ item }}"
|
||||||
with_first_found:
|
with_first_found:
|
||||||
- "{{ ansible_distribution | lower }}-{{ ansible_distribution_version | lower }}.yml"
|
- "{{ ansible_distribution | lower }}-{{ ansible_distribution_version | lower }}.yml"
|
||||||
- "{{ ansible_distribution | lower }}-{{ ansible_distribution_major_version | lower }}.yml"
|
- "{{ ansible_distribution | lower }}-{{ ansible_distribution_major_version | lower }}.yml"
|
||||||
- "{{ ansible_os_family | lower }}-{{ ansible_distribution_major_version | lower }}.yml"
|
- "{{ ansible_os_family | lower }}-{{ ansible_distribution_major_version | lower }}.yml"
|
||||||
- "{{ ansible_distribution | lower }}.yml"
|
- "{{ ansible_distribution | lower }}.yml"
|
||||||
- "{{ ansible_os_family | lower }}-{{ ansible_distribution_version.split('.')[0] }}.yml"
|
- "{{ ansible_os_family | lower }}-{{ ansible_distribution_version.split('.')[0] }}.yml"
|
||||||
- "{{ ansible_os_family | lower }}.yml"
|
- "{{ ansible_os_family | lower }}.yml"
|
||||||
tags:
|
tags:
|
||||||
- always
|
- always
|
||||||
|
|
||||||
- include: masakari_pre_install.yml
|
- include: masakari_pre_install.yml
|
||||||
tags:
|
tags:
|
||||||
- masakari-install
|
- masakari-install
|
||||||
|
|
||||||
- include: masakari_install.yml
|
- include: masakari_install.yml
|
||||||
tags:
|
tags:
|
||||||
- masakari-install
|
- masakari-install
|
||||||
|
|
||||||
- include: masakari_post_install.yml
|
- include: masakari_post_install.yml
|
||||||
tags:
|
tags:
|
||||||
- masakari-config
|
- masakari-config
|
||||||
|
|
||||||
- include: masakari_init_common.yml
|
- include: masakari_init_common.yml
|
||||||
tags:
|
tags:
|
||||||
- masakari-config
|
- masakari-config
|
||||||
|
|
||||||
- include: masakari_db_setup.yml
|
- include: masakari_db_setup.yml
|
||||||
static: no
|
static: no
|
||||||
when:
|
when:
|
||||||
inventory_hostname == groups['masakari_all'][0]
|
inventory_hostname == groups['masakari_all'][0]
|
||||||
tags:
|
tags:
|
||||||
- masakari-config
|
- masakari-config
|
||||||
|
|
||||||
- include: masakari_service_setup.yml
|
- include: masakari_service_setup.yml
|
||||||
static: no
|
static: no
|
||||||
when:
|
when:
|
||||||
inventory_hostname == groups['masakari_all'][0]
|
inventory_hostname == groups['masakari_all'][0]
|
||||||
tags:
|
tags:
|
||||||
- masakari-config
|
- masakari-config
|
||||||
|
|
||||||
- name: Flush handlers
|
- name: Flush handlers
|
||||||
meta: flush_handlers
|
meta: flush_handlers
|
||||||
|
@ -1,20 +1,20 @@
|
|||||||
---
|
---
|
||||||
# Copyright (c) 2018 NTT DATA
|
# Copyright (c) 2018 NTT DATA
|
||||||
#
|
#
|
||||||
# Licensed under the Apache License, Version 2.0 (the "License");
|
# Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
# you may not use this file except in compliance with the License.
|
# you may not use this file except in compliance with the License.
|
||||||
# You may obtain a copy of the License at
|
# You may obtain a copy of the License at
|
||||||
#
|
#
|
||||||
# http://www.apache.org/licenses/LICENSE-2.0
|
# http://www.apache.org/licenses/LICENSE-2.0
|
||||||
#
|
#
|
||||||
# Unless required by applicable law or agreed to in writing, software
|
# Unless required by applicable law or agreed to in writing, software
|
||||||
# distributed under the License is distributed on an "AS IS" BASIS,
|
# distributed under the License is distributed on an "AS IS" BASIS,
|
||||||
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||||
# See the License for the specific language governing permissions and
|
# See the License for the specific language governing permissions and
|
||||||
# limitations under the License
|
# limitations under the License
|
||||||
|
|
||||||
- name: Perform a synchronization of the Masakari database
|
- name: Perform a synchronization of the Masakari database
|
||||||
command: "{{ masakari_bin }}/masakari-manage db sync"
|
command: "{{ masakari_bin }}/masakari-manage db sync"
|
||||||
become: yes
|
become: yes
|
||||||
become_user: "{{ masakari_system_user_name }}"
|
become_user: "{{ masakari_system_user_name }}"
|
||||||
changed_when: false
|
changed_when: false
|
||||||
|
@ -1,153 +1,153 @@
|
|||||||
---
|
---
|
||||||
# Copyright (c) 2018 NTT DATA
|
# Copyright (c) 2018 NTT DATA
|
||||||
#
|
#
|
||||||
# Licensed under the Apache License, Version 2.0 (the "License");
|
# Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
# you may not use this file except in compliance with the License.
|
# you may not use this file except in compliance with the License.
|
||||||
# You may obtain a copy of the License at
|
# You may obtain a copy of the License at
|
||||||
#
|
#
|
||||||
# http://www.apache.org/licenses/LICENSE-2.0
|
# http://www.apache.org/licenses/LICENSE-2.0
|
||||||
#
|
#
|
||||||
# Unless required by applicable law or agreed to in writing, software
|
# Unless required by applicable law or agreed to in writing, software
|
||||||
# distributed under the License is distributed on an "AS IS" BASIS,
|
# distributed under the License is distributed on an "AS IS" BASIS,
|
||||||
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||||
# See the License for the specific language governing permissions and
|
# See the License for the specific language governing permissions and
|
||||||
# limitations under the License.
|
# limitations under the License.
|
||||||
|
|
||||||
- name: Install distro packages
|
- name: Install distro packages
|
||||||
package:
|
package:
|
||||||
name: "{{ masakari_distro_packages }}"
|
name: "{{ masakari_distro_packages }}"
|
||||||
state: "{{ masakari_package_state }}"
|
state: "{{ masakari_package_state }}"
|
||||||
update_cache: "{{ (ansible_pkg_mgr in ['apt', 'zypper']) | ternary('yes', omit) }}"
|
update_cache: "{{ (ansible_pkg_mgr in ['apt', 'zypper']) | ternary('yes', omit) }}"
|
||||||
cache_valid_time: "{{ (ansible_pkg_mgr == 'apt') | ternary(cache_timeout, omit) }}"
|
cache_valid_time: "{{ (ansible_pkg_mgr == 'apt') | ternary(cache_timeout, omit) }}"
|
||||||
register: install_packages
|
register: install_packages
|
||||||
until: install_packages|success
|
until: install_packages|success
|
||||||
retries: 5
|
retries: 5
|
||||||
delay: 2
|
delay: 2
|
||||||
|
|
||||||
- name: Create developer mode constraint file
|
- name: Create developer mode constraint file
|
||||||
copy:
|
copy:
|
||||||
dest: "/opt/developer-pip-constraints.txt"
|
dest: "/opt/developer-pip-constraints.txt"
|
||||||
content: |
|
content: |
|
||||||
{% for item in masakari_developer_constraints %}
|
{% for item in masakari_developer_constraints %}
|
||||||
{{ item }}
|
{{ item }}
|
||||||
{% endfor %}
|
{% endfor %}
|
||||||
when: masakari_developer_mode | bool
|
when: masakari_developer_mode | bool
|
||||||
|
|
||||||
- name: Install requires pip packages
|
- name: Install requires pip packages
|
||||||
pip:
|
pip:
|
||||||
name: "{{ masakari_requires_pip_packages }}"
|
name: "{{ masakari_requires_pip_packages }}"
|
||||||
state: "{{ masakari_pip_package_state }}"
|
state: "{{ masakari_pip_package_state }}"
|
||||||
extra_args: >-
|
extra_args: >-
|
||||||
{{ masakari_developer_mode | ternary(pip_install_developer_constraints | default('--constraint /opt/developer-pip-constraints.txt'), '') }}
|
{{ masakari_developer_mode | ternary(pip_install_developer_constraints | default('--constraint /opt/developer-pip-constraints.txt'), '') }}
|
||||||
{{ (pip_install_upper_constraints is defined) | ternary('--constraint ' + pip_install_upper_constraints | default(''),'') }}
|
{{ (pip_install_upper_constraints is defined) | ternary('--constraint ' + pip_install_upper_constraints | default(''),'') }}
|
||||||
{{ pip_install_options | default('') }}
|
{{ pip_install_options | default('') }}
|
||||||
register: install_packages
|
register: install_packages
|
||||||
until: install_packages|success
|
until: install_packages|success
|
||||||
retries: 5
|
retries: 5
|
||||||
delay: 2
|
delay: 2
|
||||||
|
|
||||||
- name: Retrieve checksum for venv download
|
- name: Retrieve checksum for venv download
|
||||||
uri:
|
uri:
|
||||||
url: "{{ masakari_venv_download_url | replace('tgz', 'checksum') }}"
|
url: "{{ masakari_venv_download_url | replace('tgz', 'checksum') }}"
|
||||||
return_content: yes
|
return_content: yes
|
||||||
register: masakari_venv_checksum
|
register: masakari_venv_checksum
|
||||||
when: masakari_venv_download | bool
|
when: masakari_venv_download | bool
|
||||||
|
|
||||||
- name: Attempt venv download
|
- name: Attempt venv download
|
||||||
get_url:
|
get_url:
|
||||||
url: "{{ masakari_venv_download_url }}"
|
url: "{{ masakari_venv_download_url }}"
|
||||||
dest: "/var/cache/{{ masakari_venv_download_url | basename }}"
|
dest: "/var/cache/{{ masakari_venv_download_url | basename }}"
|
||||||
checksum: "sha1:{{ masakari_venv_checksum.content | trim }}"
|
checksum: "sha1:{{ masakari_venv_checksum.content | trim }}"
|
||||||
register: masakari_get_venv
|
register: masakari_get_venv
|
||||||
when: masakari_venv_download | bool
|
when: masakari_venv_download | bool
|
||||||
|
|
||||||
- name: Remove existing venv
|
- name: Remove existing venv
|
||||||
file:
|
file:
|
||||||
path: "{{ masakari_bin | dirname }}"
|
path: "{{ masakari_bin | dirname }}"
|
||||||
state: absent
|
state: absent
|
||||||
when: masakari_get_venv | changed
|
when: masakari_get_venv | changed
|
||||||
|
|
||||||
- name: Create masakari venv dir
|
- name: Create masakari venv dir
|
||||||
file:
|
file:
|
||||||
path: "{{ masakari_bin | dirname }}"
|
path: "{{ masakari_bin | dirname }}"
|
||||||
state: directory
|
state: directory
|
||||||
register: masakari_venv_dir
|
register: masakari_venv_dir
|
||||||
when: masakari_get_venv | changed
|
when: masakari_get_venv | changed
|
||||||
|
|
||||||
- name: Unarchive pre-built venv
|
- name: Unarchive pre-built venv
|
||||||
unarchive:
|
unarchive:
|
||||||
src: "/var/cache/{{ masakari_venv_download_url | basename }}"
|
src: "/var/cache/{{ masakari_venv_download_url | basename }}"
|
||||||
dest: "{{ masakari_bin | dirname }}"
|
dest: "{{ masakari_bin | dirname }}"
|
||||||
copy: "no"
|
copy: "no"
|
||||||
when: masakari_get_venv | changed
|
when: masakari_get_venv | changed
|
||||||
notify:
|
notify:
|
||||||
- Manage LB
|
- Manage LB
|
||||||
- Restart masakari services
|
- Restart masakari services
|
||||||
|
|
||||||
- name: Install pip packages
|
- name: Install pip packages
|
||||||
pip:
|
pip:
|
||||||
name: "{{ masakari_pip_packages }}"
|
name: "{{ masakari_pip_packages }}"
|
||||||
state: "{{ masakari_pip_package_state }}"
|
state: "{{ masakari_pip_package_state }}"
|
||||||
virtualenv: "{{ masakari_bin | dirname }}"
|
virtualenv: "{{ masakari_bin | dirname }}"
|
||||||
virtualenv_site_packages: "no"
|
virtualenv_site_packages: "no"
|
||||||
extra_args: >-
|
extra_args: >-
|
||||||
{{ masakari_developer_mode | ternary(pip_install_developer_constraints | default('--constraint /opt/developer-pip-constraints.txt'), '') }}
|
{{ masakari_developer_mode | ternary(pip_install_developer_constraints | default('--constraint /opt/developer-pip-constraints.txt'), '') }}
|
||||||
{{ (pip_install_upper_constraints is defined) | ternary('--constraint ' + pip_install_upper_constraints | default(''),'') }}
|
{{ (pip_install_upper_constraints is defined) | ternary('--constraint ' + pip_install_upper_constraints | default(''),'') }}
|
||||||
{{ pip_install_options | default('') }}
|
{{ pip_install_options | default('') }}
|
||||||
register: install_packages
|
register: install_packages
|
||||||
until: install_packages|success
|
until: install_packages|success
|
||||||
retries: 5
|
retries: 5
|
||||||
delay: 2
|
delay: 2
|
||||||
when: masakari_get_venv | failed or masakari_get_venv | skipped
|
when: masakari_get_venv | failed or masakari_get_venv | skipped
|
||||||
notify:
|
notify:
|
||||||
- Manage LB
|
- Manage LB
|
||||||
- Restart masakari services
|
- Restart masakari services
|
||||||
|
|
||||||
- name: Remove python from path first (CentOS, openSUSE)
|
- name: Remove python from path first (CentOS, openSUSE)
|
||||||
file:
|
file:
|
||||||
path: "{{ masakari_bin | dirname }}/bin/python2.7"
|
path: "{{ masakari_bin | dirname }}/bin/python2.7"
|
||||||
state: "absent"
|
state: "absent"
|
||||||
when:
|
when:
|
||||||
- ansible_pkg_mgr in ['yum', 'dnf', 'zypper']
|
- ansible_pkg_mgr in ['yum', 'dnf', 'zypper']
|
||||||
- masakari_get_venv | changed
|
- masakari_get_venv | changed
|
||||||
|
|
||||||
# NOTE(odyssey4me):
|
# NOTE(odyssey4me):
|
||||||
# We reinitialize the venv to ensure that the right
|
# We reinitialize the venv to ensure that the right
|
||||||
# version of python is in the venv, but we do not
|
# version of python is in the venv, but we do not
|
||||||
# want virtualenv to also replace pip, setuptools
|
# want virtualenv to also replace pip, setuptools
|
||||||
# and wheel so we tell it not to.
|
# and wheel so we tell it not to.
|
||||||
# We do not use --always-copy for CentOS/SuSE due
|
# We do not use --always-copy for CentOS/SuSE due
|
||||||
# to https://github.com/pypa/virtualenv/issues/565
|
# to https://github.com/pypa/virtualenv/issues/565
|
||||||
- name: Update virtualenv path
|
- name: Update virtualenv path
|
||||||
shell: |
|
shell: |
|
||||||
find {{ masakari_bin }} -name \*.pyc -delete
|
find {{ masakari_bin }} -name \*.pyc -delete
|
||||||
sed -si '1s/^.*python.*$/#!{{ masakari_bin | replace ('/','\/') }}\/python/' {{ masakari_bin }}/*
|
sed -si '1s/^.*python.*$/#!{{ masakari_bin | replace ('/','\/') }}\/python/' {{ masakari_bin }}/*
|
||||||
virtualenv {{ masakari_bin | dirname }} \
|
virtualenv {{ masakari_bin | dirname }} \
|
||||||
{{ (ansible_pkg_mgr == 'apt') | ternary('--always-copy', '') }} \
|
{{ (ansible_pkg_mgr == 'apt') | ternary('--always-copy', '') }} \
|
||||||
--no-pip \
|
--no-pip \
|
||||||
--no-setuptools \
|
--no-setuptools \
|
||||||
--no-wheel
|
--no-wheel
|
||||||
when: masakari_get_venv | changed
|
when: masakari_get_venv | changed
|
||||||
tags:
|
tags:
|
||||||
- skip_ansible_lint
|
- skip_ansible_lint
|
||||||
|
|
||||||
- name: Record the need for a service restart
|
- name: Record the need for a service restart
|
||||||
ini_file:
|
ini_file:
|
||||||
dest: "/etc/ansible/facts.d/openstack_ansible.fact"
|
dest: "/etc/ansible/facts.d/openstack_ansible.fact"
|
||||||
section: masakari
|
section: masakari
|
||||||
option: need_service_restart
|
option: need_service_restart
|
||||||
value: True
|
value: True
|
||||||
when: (masakari_get_venv | changed) or
|
when: (masakari_get_venv | changed) or
|
||||||
(masakari_venv_dir | changed) or
|
(masakari_venv_dir | changed) or
|
||||||
(install_packages | changed) or
|
(install_packages | changed) or
|
||||||
(ansible_local is not defined) or
|
(ansible_local is not defined) or
|
||||||
('openstack_ansible' not in ansible_local) or
|
('openstack_ansible' not in ansible_local) or
|
||||||
('masakari' not in ansible_local['openstack_ansible']) or
|
('masakari' not in ansible_local['openstack_ansible']) or
|
||||||
('need_service_restart' not in ansible_local['openstack_ansible']['masakari'])
|
('need_service_restart' not in ansible_local['openstack_ansible']['masakari'])
|
||||||
|
|
||||||
- name: Record the venv tag deployed
|
- name: Record the venv tag deployed
|
||||||
ini_file:
|
ini_file:
|
||||||
dest: "/etc/ansible/facts.d/openstack_ansible.fact"
|
dest: "/etc/ansible/facts.d/openstack_ansible.fact"
|
||||||
section: masakari
|
section: masakari
|
||||||
option: venv_tag
|
option: venv_tag
|
||||||
value: "{{ masakari_venv_tag }}"
|
value: "{{ masakari_venv_tag }}"
|
||||||
|
@ -1,40 +1,40 @@
|
|||||||
---
|
---
|
||||||
# Copyright (c) 2018 NTT DATA
|
# Copyright (c) 2018 NTT DATA
|
||||||
#
|
#
|
||||||
# Licensed under the Apache License, Version 2.0 (the "License");
|
# Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
# you may not use this file except in compliance with the License.
|
# you may not use this file except in compliance with the License.
|
||||||
# You may obtain a copy of the License at
|
# You may obtain a copy of the License at
|
||||||
#
|
#
|
||||||
# http://www.apache.org/licenses/LICENSE-2.0
|
# http://www.apache.org/licenses/LICENSE-2.0
|
||||||
#
|
#
|
||||||
# Unless required by applicable law or agreed to in writing, software
|
# Unless required by applicable law or agreed to in writing, software
|
||||||
# distributed under the License is distributed on an "AS IS" BASIS,
|
# distributed under the License is distributed on an "AS IS" BASIS,
|
||||||
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||||
# See the License for the specific language governing permissions and
|
# See the License for the specific language governing permissions and
|
||||||
# limitations under the License.
|
# limitations under the License.
|
||||||
|
|
||||||
- name: Deploy masakari configuration files
|
- name: Deploy masakari configuration files
|
||||||
config_template:
|
config_template:
|
||||||
src: "{{ item.src }}"
|
src: "{{ item.src }}"
|
||||||
dest: "{{ item.dest }}"
|
dest: "{{ item.dest }}"
|
||||||
owner: "root"
|
owner: "root"
|
||||||
group: "{{ masakari_system_group_name }}"
|
group: "{{ masakari_system_group_name }}"
|
||||||
mode: "0640"
|
mode: "0640"
|
||||||
config_overrides: "{{ item.config_overrides }}"
|
config_overrides: "{{ item.config_overrides }}"
|
||||||
config_type: "{{ item.config_type }}"
|
config_type: "{{ item.config_type }}"
|
||||||
when: item.condition | default(True)
|
when: item.condition | default(True)
|
||||||
with_items:
|
with_items:
|
||||||
- src: "api-paste.ini.j2"
|
- src: "api-paste.ini.j2"
|
||||||
dest: "/etc/masakari/api-paste.ini"
|
dest: "/etc/masakari/api-paste.ini"
|
||||||
config_overrides: "{{ masakari_api_paste_ini_overrides }}"
|
config_overrides: "{{ masakari_api_paste_ini_overrides }}"
|
||||||
config_type: "ini"
|
config_type: "ini"
|
||||||
- src: "masakari.conf.j2"
|
- src: "masakari.conf.j2"
|
||||||
dest: "/etc/masakari/masakari.conf"
|
dest: "/etc/masakari/masakari.conf"
|
||||||
config_overrides: "{{ masakari_masakari_conf_overrides }}"
|
config_overrides: "{{ masakari_masakari_conf_overrides }}"
|
||||||
config_type: "ini"
|
config_type: "ini"
|
||||||
- src: "policy.json.j2"
|
- src: "policy.json.j2"
|
||||||
dest: "/etc/masakari/policy.json"
|
dest: "/etc/masakari/policy.json"
|
||||||
config_overrides: "{{ masakari_policy_json_overrides }}"
|
config_overrides: "{{ masakari_policy_json_overrides }}"
|
||||||
config_type: "json"
|
config_type: "json"
|
||||||
notify:
|
notify:
|
||||||
- Restart masakari services
|
- Restart masakari services
|
||||||
|
@ -1,69 +1,69 @@
|
|||||||
---
|
---
|
||||||
# Copyright (c) 2018 NTT DATA
|
# Copyright (c) 2018 NTT DATA
|
||||||
#
|
#
|
||||||
# Licensed under the Apache License, Version 2.0 (the "License");
|
# Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
# you may not use this file except in compliance with the License.
|
# you may not use this file except in compliance with the License.
|
||||||
# You may obtain a copy of the License at
|
# You may obtain a copy of the License at
|
||||||
#
|
#
|
||||||
# http://www.apache.org/licenses/LICENSE-2.0
|
# http://www.apache.org/licenses/LICENSE-2.0
|
||||||
#
|
#
|
||||||
# Unless required by applicable law or agreed to in writing, software
|
# Unless required by applicable law or agreed to in writing, software
|
||||||
# distributed under the License is distributed on an "AS IS" BASIS,
|
# distributed under the License is distributed on an "AS IS" BASIS,
|
||||||
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||||
# See the License for the specific language governing permissions and
|
# See the License for the specific language governing permissions and
|
||||||
# limitations under the License.
|
# limitations under the License.
|
||||||
|
|
||||||
- name: create the system group
|
- name: create the system group
|
||||||
group:
|
group:
|
||||||
name: "{{ masakari_system_group_name }}"
|
name: "{{ masakari_system_group_name }}"
|
||||||
gid: "{{ masakari_system_group_gid | default(omit) }}"
|
gid: "{{ masakari_system_group_gid | default(omit) }}"
|
||||||
state: "present"
|
state: "present"
|
||||||
system: "yes"
|
system: "yes"
|
||||||
|
|
||||||
- name: Create the masakari system user
|
- name: Create the masakari system user
|
||||||
user:
|
user:
|
||||||
name: "{{ masakari_system_user_name }}"
|
name: "{{ masakari_system_user_name }}"
|
||||||
uid: "{{ masakari_system_user_uid | default(omit) }}"
|
uid: "{{ masakari_system_user_uid | default(omit) }}"
|
||||||
group: "{{ masakari_system_group_name }}"
|
group: "{{ masakari_system_group_name }}"
|
||||||
comment: "{{ masakari_system_comment }}"
|
comment: "{{ masakari_system_comment }}"
|
||||||
shell: "{{ masakari_system_shell }}"
|
shell: "{{ masakari_system_shell }}"
|
||||||
system: "yes"
|
system: "yes"
|
||||||
createhome: "yes"
|
createhome: "yes"
|
||||||
home: "{{ masakari_system_user_home }}"
|
home: "{{ masakari_system_user_home }}"
|
||||||
|
|
||||||
- name: Create masakari dir
|
- name: Create masakari dir
|
||||||
file:
|
file:
|
||||||
path: "{{ item.path }}"
|
path: "{{ item.path }}"
|
||||||
state: directory
|
state: directory
|
||||||
owner: "{{ item.owner|default(masakari_system_user_name) }}"
|
owner: "{{ item.owner|default(masakari_system_user_name) }}"
|
||||||
group: "{{ item.group|default(masakari_system_group_name) }}"
|
group: "{{ item.group|default(masakari_system_group_name) }}"
|
||||||
mode: "{{ item.mode|default(omit) }}"
|
mode: "{{ item.mode|default(omit) }}"
|
||||||
with_items:
|
with_items:
|
||||||
- { path: "/openstack", mode: "0755", owner: "root", group: "root" }
|
- { path: "/openstack", mode: "0755", owner: "root", group: "root" }
|
||||||
- { path: "/etc/masakari", mode: "0750" }
|
- { path: "/etc/masakari", mode: "0750" }
|
||||||
- { path: "/var/cache/masakari" }
|
- { path: "/var/cache/masakari" }
|
||||||
- { path: "{{ masakari_system_user_home }}" }
|
- { path: "{{ masakari_system_user_home }}" }
|
||||||
- { path: "{{ masakari_system_user_home }}/cache/api", mode: "0700" }
|
- { path: "{{ masakari_system_user_home }}/cache/api", mode: "0700" }
|
||||||
- { path: "{{ masakari_system_user_home }}/cache/registry" }
|
- { path: "{{ masakari_system_user_home }}/cache/registry" }
|
||||||
- { path: "{{ masakari_system_user_home }}/scrubber" }
|
- { path: "{{ masakari_system_user_home }}/scrubber" }
|
||||||
|
|
||||||
- name: Test for log directory or link
|
- name: Test for log directory or link
|
||||||
shell: |
|
shell: |
|
||||||
if [ -h "/var/log/masakari" ]; then
|
if [ -h "/var/log/masakari" ]; then
|
||||||
chown -h {{ masakari_system_user_name }}:{{ masakari_system_group_name }} "/var/log/masakari"
|
chown -h {{ masakari_system_user_name }}:{{ masakari_system_group_name }} "/var/log/masakari"
|
||||||
chown -R {{ masakari_system_user_name }}:{{ masakari_system_group_name }} "$(readlink /var/log/masakari)"
|
chown -R {{ masakari_system_user_name }}:{{ masakari_system_group_name }} "$(readlink /var/log/masakari)"
|
||||||
else
|
else
|
||||||
exit 1
|
exit 1
|
||||||
fi
|
fi
|
||||||
register: log_dir
|
register: log_dir
|
||||||
failed_when: false
|
failed_when: false
|
||||||
changed_when: log_dir.rc != 0
|
changed_when: log_dir.rc != 0
|
||||||
|
|
||||||
- name: Create masakari log dir
|
- name: Create masakari log dir
|
||||||
file:
|
file:
|
||||||
path: "/var/log/masakari"
|
path: "/var/log/masakari"
|
||||||
state: directory
|
state: directory
|
||||||
owner: "{{ masakari_system_user_name }}"
|
owner: "{{ masakari_system_user_name }}"
|
||||||
group: "{{ masakari_system_group_name }}"
|
group: "{{ masakari_system_group_name }}"
|
||||||
mode: "0755"
|
mode: "0755"
|
||||||
when: log_dir.rc != 0
|
when: log_dir.rc != 0
|
||||||
|
@ -1,91 +1,95 @@
|
|||||||
---
|
---
|
||||||
# Copyright (c) 2018 NTT DATA
|
# Copyright (c) 2018 NTT DATA
|
||||||
#
|
#
|
||||||
# Licensed under the Apache License, Version 2.0 (the "License");
|
# Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
# you may not use this file except in compliance with the License.
|
# you may not use this file except in compliance with the License.
|
||||||
# You may obtain a copy of the License at
|
# You may obtain a copy of the License at
|
||||||
#
|
#
|
||||||
# http://www.apache.org/licenses/LICENSE-2.0
|
# http://www.apache.org/licenses/LICENSE-2.0
|
||||||
#
|
#
|
||||||
# Unless required by applicable law or agreed to in writing, software
|
# Unless required by applicable law or agreed to in writing, software
|
||||||
# distributed under the License is distributed on an "AS IS" BASIS,
|
# distributed under the License is distributed on an "AS IS" BASIS,
|
||||||
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||||
# See the License for the specific language governing permissions and
|
# See the License for the specific language governing permissions and
|
||||||
# limitations under the License.
|
# limitations under the License.
|
||||||
|
|
||||||
# Create a service
|
# Create a service
|
||||||
- name: Ensure masakari service
|
- name: Ensure masakari service
|
||||||
keystone:
|
keystone:
|
||||||
command: "ensure_service"
|
command: "ensure_service"
|
||||||
endpoint: "{{ keystone_service_adminurl }}"
|
endpoint: "{{ keystone_service_adminurl }}"
|
||||||
login_user: "{{ keystone_admin_user_name }}"
|
login_user: "{{ keystone_admin_user_name }}"
|
||||||
login_password: "{{ keystone_auth_admin_password }}"
|
login_password: "{{ keystone_auth_admin_password }}"
|
||||||
login_project_name: "{{ keystone_admin_tenant_name }}"
|
login_project_name: "{{ keystone_admin_tenant_name }}"
|
||||||
service_name: "{{ masakari_service_name }}"
|
service_name: "{{ masakari_service_name }}"
|
||||||
service_type: "{{ masakari_service_type }}"
|
service_type: "{{ masakari_service_type }}"
|
||||||
description: "{{ masakari_service_description }}"
|
description: "{{ masakari_service_description }}"
|
||||||
insecure: "{{ keystone_service_adminuri_insecure }}"
|
insecure: "{{ keystone_service_adminuri_insecure }}"
|
||||||
register: add_service
|
register: add_service
|
||||||
until: add_service|success
|
until: add_service|success
|
||||||
retries: 5
|
retries: 5
|
||||||
delay: 2
|
delay: 2
|
||||||
|
no_log: True
|
||||||
# Create an admin user
|
|
||||||
- name: Ensure masakari user
|
# Create an admin user
|
||||||
keystone:
|
- name: Ensure masakari user
|
||||||
command: "ensure_user"
|
keystone:
|
||||||
endpoint: "{{ keystone_service_adminurl }}"
|
command: "ensure_user"
|
||||||
login_user: "{{ keystone_admin_user_name }}"
|
endpoint: "{{ keystone_service_adminurl }}"
|
||||||
login_password: "{{ keystone_auth_admin_password }}"
|
login_user: "{{ keystone_admin_user_name }}"
|
||||||
login_project_name: "{{ keystone_admin_tenant_name }}"
|
login_password: "{{ keystone_auth_admin_password }}"
|
||||||
user_name: "{{ masakari_service_user_name }}"
|
login_project_name: "{{ keystone_admin_tenant_name }}"
|
||||||
tenant_name: "{{ masakari_service_project_name }}"
|
user_name: "{{ masakari_service_user_name }}"
|
||||||
password: "{{ masakari_service_password }}"
|
tenant_name: "{{ masakari_service_project_name }}"
|
||||||
insecure: "{{ keystone_service_adminuri_insecure }}"
|
password: "{{ masakari_service_password }}"
|
||||||
register: add_service
|
insecure: "{{ keystone_service_adminuri_insecure }}"
|
||||||
when: not masakari_service_in_ldap | bool
|
register: add_service
|
||||||
until: add_service|success
|
when: not masakari_service_in_ldap | bool
|
||||||
retries: 5
|
until: add_service|success
|
||||||
delay: 10
|
retries: 5
|
||||||
|
delay: 10
|
||||||
# Add a role to the user
|
no_log: True
|
||||||
- name: Ensure masakari user to admin role
|
|
||||||
keystone:
|
# Add a role to the user
|
||||||
command: "ensure_user_role"
|
- name: Ensure masakari user to admin role
|
||||||
endpoint: "{{ keystone_service_adminurl }}"
|
keystone:
|
||||||
login_user: "{{ keystone_admin_user_name }}"
|
command: "ensure_user_role"
|
||||||
login_password: "{{ keystone_auth_admin_password }}"
|
endpoint: "{{ keystone_service_adminurl }}"
|
||||||
login_project_name: "{{ keystone_admin_tenant_name }}"
|
login_user: "{{ keystone_admin_user_name }}"
|
||||||
user_name: "{{ masakari_service_user_name }}"
|
login_password: "{{ keystone_auth_admin_password }}"
|
||||||
tenant_name: "{{ masakari_service_project_name }}"
|
login_project_name: "{{ keystone_admin_tenant_name }}"
|
||||||
role_name: "{{ masakari_role_name }}"
|
user_name: "{{ masakari_service_user_name }}"
|
||||||
insecure: "{{ keystone_service_adminuri_insecure }}"
|
tenant_name: "{{ masakari_service_project_name }}"
|
||||||
register: add_service
|
role_name: "{{ masakari_role_name }}"
|
||||||
when: not masakari_service_in_ldap | bool
|
insecure: "{{ keystone_service_adminuri_insecure }}"
|
||||||
until: add_service|success
|
register: add_service
|
||||||
retries: 5
|
when: not masakari_service_in_ldap | bool
|
||||||
delay: 10
|
until: add_service|success
|
||||||
|
retries: 5
|
||||||
# Create an endpoint
|
delay: 10
|
||||||
- name: Ensure masakari endpoint
|
no_log: True
|
||||||
keystone:
|
|
||||||
command: "ensure_endpoint"
|
# Create an endpoint
|
||||||
endpoint: "{{ keystone_service_adminurl }}"
|
- name: Ensure masakari endpoint
|
||||||
login_user: "{{ keystone_admin_user_name }}"
|
keystone:
|
||||||
login_password: "{{ keystone_auth_admin_password }}"
|
command: "ensure_endpoint"
|
||||||
login_project_name: "{{ keystone_admin_tenant_name }}"
|
endpoint: "{{ keystone_service_adminurl }}"
|
||||||
region_name: "{{ masakari_service_region }}"
|
login_user: "{{ keystone_admin_user_name }}"
|
||||||
service_name: "{{ masakari_service_name }}"
|
login_password: "{{ keystone_auth_admin_password }}"
|
||||||
service_type: "{{ masakari_service_type }}"
|
login_project_name: "{{ keystone_admin_tenant_name }}"
|
||||||
insecure: "{{ keystone_service_adminuri_insecure }}"
|
region_name: "{{ masakari_service_region }}"
|
||||||
endpoint_list:
|
service_name: "{{ masakari_service_name }}"
|
||||||
- url: "{{ masakari_service_publicurl }}"
|
service_type: "{{ masakari_service_type }}"
|
||||||
interface: "public"
|
insecure: "{{ keystone_service_adminuri_insecure }}"
|
||||||
- url: "{{ masakari_service_internalurl }}"
|
endpoint_list:
|
||||||
interface: "internal"
|
- url: "{{ masakari_service_publicurl }}"
|
||||||
- url: "{{ masakari_service_adminurl }}"
|
interface: "public"
|
||||||
interface: "admin"
|
- url: "{{ masakari_service_internalurl }}"
|
||||||
register: add_service
|
interface: "internal"
|
||||||
until: add_service|success
|
- url: "{{ masakari_service_adminurl }}"
|
||||||
retries: 5
|
interface: "admin"
|
||||||
delay: 10
|
register: add_service
|
||||||
|
until: add_service|success
|
||||||
|
retries: 5
|
||||||
|
delay: 10
|
||||||
|
no_log: True
|
||||||
|
@ -1,30 +1,30 @@
|
|||||||
---
|
---
|
||||||
# Copyright (c) 2018 NTT DATA
|
# Copyright (c) 2018 NTT DATA
|
||||||
#
|
#
|
||||||
# Licensed under the Apache License, Version 2.0 (the "License");
|
# Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
# you may not use this file except in compliance with the License.
|
# you may not use this file except in compliance with the License.
|
||||||
# You may obtain a copy of the License at
|
# You may obtain a copy of the License at
|
||||||
#
|
#
|
||||||
# http://www.apache.org/licenses/LICENSE-2.0
|
# http://www.apache.org/licenses/LICENSE-2.0
|
||||||
#
|
#
|
||||||
# Unless required by applicable law or agreed to in writing, software
|
# Unless required by applicable law or agreed to in writing, software
|
||||||
# distributed under the License is distributed on an "AS IS" BASIS,
|
# distributed under the License is distributed on an "AS IS" BASIS,
|
||||||
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||||
# See the License for the specific language governing permissions and
|
# See the License for the specific language governing permissions and
|
||||||
# limitations under the License.
|
# limitations under the License.
|
||||||
|
|
||||||
masakari_service_tenant_name: service
|
masakari_service_tenant_name: service
|
||||||
masakari_rabbitmq_port: "{{ rabbitmq_port }}"
|
masakari_rabbitmq_port: "{{ rabbitmq_port }}"
|
||||||
masakari_rabbitmq_use_ssl: "{{ rabbitmq_use_ssl }}"
|
masakari_rabbitmq_use_ssl: "{{ rabbitmq_use_ssl }}"
|
||||||
masakari_rabbitmq_servers: "{{ rabbitmq_servers }}"
|
masakari_rabbitmq_servers: "{{ rabbitmq_servers }}"
|
||||||
masakari_rabbitmq_host_group: "{{ rabbitmq_host_group }}"
|
masakari_rabbitmq_host_group: "{{ rabbitmq_host_group }}"
|
||||||
masakari_service_publicuri: "{{ masakari_service_proto }}://{{ hostvars[groups['masakari_all'][0]]['ansible_host'] }}:{{ masakari_service_port }}"
|
masakari_service_publicuri: "{{ masakari_service_proto }}://{{ hostvars[groups['masakari_all'][0]]['ansible_host'] }}:{{ masakari_service_port }}"
|
||||||
masakari_service_adminurl: "{{ masakari_service_proto }}://{{ hostvars[groups['masakari_all'][0]]['ansible_host'] }}:{{ masakari_service_port }}"
|
masakari_service_adminurl: "{{ masakari_service_proto }}://{{ hostvars[groups['masakari_all'][0]]['ansible_host'] }}:{{ masakari_service_port }}"
|
||||||
masakari_service_adminuri: "{{ masakari_service_proto }}://{{ hostvars[groups['masakari_all'][0]]['ansible_host'] }}:{{ masakari_service_port }}"
|
masakari_service_adminuri: "{{ masakari_service_proto }}://{{ hostvars[groups['masakari_all'][0]]['ansible_host'] }}:{{ masakari_service_port }}"
|
||||||
masakari_aodh_enabled: false
|
masakari_aodh_enabled: false
|
||||||
masakari_gnocchi_enabled: false
|
masakari_gnocchi_enabled: false
|
||||||
masakari_rabbitmq_password: "secrete"
|
masakari_rabbitmq_password: "secrete"
|
||||||
masakari_service_password: "secrete"
|
masakari_service_password: "secrete"
|
||||||
masakari_container_mysql_password: "secrete"
|
masakari_container_mysql_password: "secrete"
|
||||||
masakari_developer_mode: true
|
masakari_developer_mode: true
|
||||||
masakari_galera_address: "{{ test_galera_host }}"
|
masakari_galera_address: "{{ test_galera_host }}"
|
||||||
|
@ -1,34 +1,34 @@
|
|||||||
---
|
---
|
||||||
# Copyright (c) 2018 NTT DATA
|
# Copyright (c) 2018 NTT DATA
|
||||||
#
|
#
|
||||||
# Licensed under the Apache License, Version 2.0 (the "License");
|
# Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
# you may not use this file except in compliance with the License.
|
# you may not use this file except in compliance with the License.
|
||||||
# You may obtain a copy of the License at
|
# You may obtain a copy of the License at
|
||||||
#
|
#
|
||||||
# http://www.apache.org/licenses/LICENSE-2.0
|
# http://www.apache.org/licenses/LICENSE-2.0
|
||||||
#
|
#
|
||||||
# Unless required by applicable law or agreed to in writing, software
|
# Unless required by applicable law or agreed to in writing, software
|
||||||
# distributed under the License is distributed on an "AS IS" BASIS,
|
# distributed under the License is distributed on an "AS IS" BASIS,
|
||||||
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||||
# See the License for the specific language governing permissions and
|
# See the License for the specific language governing permissions and
|
||||||
# limitations under the License.
|
# limitations under the License.
|
||||||
|
|
||||||
- name: Playbook for deploying masakari
|
- name: Playbook for deploying masakari
|
||||||
hosts: masakari_all
|
hosts: masakari_all
|
||||||
user: root
|
user: root
|
||||||
become: true
|
become: true
|
||||||
gather_facts: true
|
gather_facts: true
|
||||||
any_errors_fatal: true
|
any_errors_fatal: true
|
||||||
pre_tasks:
|
pre_tasks:
|
||||||
- include: common/ensure-rabbitmq.yml
|
- include: common/ensure-rabbitmq.yml
|
||||||
vhost_name: "{{ masakari_rabbitmq_vhost }}"
|
vhost_name: "{{ masakari_rabbitmq_vhost }}"
|
||||||
user_name: "{{ masakari_rabbitmq_userid }}"
|
user_name: "{{ masakari_rabbitmq_userid }}"
|
||||||
user_password: "{{ masakari_rabbitmq_password }}"
|
user_password: "{{ masakari_rabbitmq_password }}"
|
||||||
when: groups['rabbitmq_all'] is defined
|
when: groups['rabbitmq_all'] is defined
|
||||||
- include: common/create-grant-db.yml
|
- include: common/create-grant-db.yml
|
||||||
db_name: "{{ masakari_galera_database }}"
|
db_name: "{{ masakari_galera_database }}"
|
||||||
db_password: "{{ masakari_container_mysql_password }}"
|
db_password: "{{ masakari_container_mysql_password }}"
|
||||||
roles:
|
roles:
|
||||||
- role: os_masakari
|
- role: os_masakari
|
||||||
vars_files:
|
vars_files:
|
||||||
- common/test-vars.yml
|
- common/test-vars.yml
|
||||||
|
@ -1,30 +1,30 @@
|
|||||||
---
|
---
|
||||||
# Copyright (c) 2018 NTT DATA
|
# Copyright (c) 2018 NTT DATA
|
||||||
#
|
#
|
||||||
# Licensed under the Apache License, Version 2.0 (the "License");
|
# Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
# you may not use this file except in compliance with the License.
|
# you may not use this file except in compliance with the License.
|
||||||
# You may obtain a copy of the License at
|
# You may obtain a copy of the License at
|
||||||
#
|
#
|
||||||
# http://www.apache.org/licenses/LICENSE-2.0
|
# http://www.apache.org/licenses/LICENSE-2.0
|
||||||
#
|
#
|
||||||
# Unless required by applicable law or agreed to in writing, software
|
# Unless required by applicable law or agreed to in writing, software
|
||||||
# distributed under the License is distributed on an "AS IS" BASIS,
|
# distributed under the License is distributed on an "AS IS" BASIS,
|
||||||
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||||
# See the License for the specific language governing permissions and
|
# See the License for the specific language governing permissions and
|
||||||
# limitations under the License.
|
# limitations under the License.
|
||||||
|
|
||||||
- name: Ensure masakari APIs are reachable
|
- name: Ensure masakari APIs are reachable
|
||||||
hosts: masakari_api
|
hosts: masakari_api
|
||||||
user: root
|
user: root
|
||||||
gather_facts: false
|
gather_facts: false
|
||||||
tasks:
|
tasks:
|
||||||
- name: check masakari api
|
- name: check masakari api
|
||||||
uri:
|
uri:
|
||||||
url: "http://localhost:{{ item.value.service_name['masakari-api'] }}"
|
url: "http://localhost:{{ item.value.service_name['masakari-api'] }}"
|
||||||
status_code: 200
|
status_code: 200
|
||||||
register: result
|
register: result
|
||||||
until: result.status == 200
|
until: result.status == 200
|
||||||
retries: 5
|
retries: 5
|
||||||
delay: 10
|
delay: 10
|
||||||
with_items:
|
with_items:
|
||||||
- 15868
|
- 15868
|
||||||
|
@ -1,29 +1,29 @@
|
|||||||
---
|
---
|
||||||
# Copyright (c) 2018 NTT DATA
|
# Copyright (c) 2018 NTT DATA
|
||||||
#
|
#
|
||||||
# Licensed under the Apache License, Version 2.0 (the "License");
|
# Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
# you may not use this file except in compliance with the License.
|
# you may not use this file except in compliance with the License.
|
||||||
# You may obtain a copy of the License at
|
# You may obtain a copy of the License at
|
||||||
#
|
#
|
||||||
# http://www.apache.org/licenses/LICENSE-2.0
|
# http://www.apache.org/licenses/LICENSE-2.0
|
||||||
#
|
#
|
||||||
# Unless required by applicable law or agreed to in writing, software
|
# Unless required by applicable law or agreed to in writing, software
|
||||||
# distributed under the License is distributed on an "AS IS" BASIS,
|
# distributed under the License is distributed on an "AS IS" BASIS,
|
||||||
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||||
# See the License for the specific language governing permissions and
|
# See the License for the specific language governing permissions and
|
||||||
# limitations under the License.
|
# limitations under the License.
|
||||||
|
|
||||||
# Setup the host
|
# Setup the host
|
||||||
- include: common/test-setup-host.yml
|
- include: common/test-setup-host.yml
|
||||||
|
|
||||||
# Install RabbitMQ/MariaDB
|
# Install RabbitMQ/MariaDB
|
||||||
- include: common/test-install-infra.yml
|
- include: common/test-install-infra.yml
|
||||||
|
|
||||||
# Install Keystone
|
# Install Keystone
|
||||||
- include: common/test-install-keystone.yml
|
- include: common/test-install-keystone.yml
|
||||||
|
|
||||||
# Install Masakari
|
# Install Masakari
|
||||||
- include: test-install-masakari.yml
|
- include: test-install-masakari.yml
|
||||||
|
|
||||||
# Test Masakari
|
# Test Masakari
|
||||||
- include: test-masakari-functional.yml
|
- include: test-masakari-functional.yml
|
||||||
|
25
zuul.d/project.yaml
Normal file
25
zuul.d/project.yaml
Normal file
@ -0,0 +1,25 @@
|
|||||||
|
---
|
||||||
|
# Copyright 2018, Rackspace US, Inc.
|
||||||
|
#
|
||||||
|
# Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
|
# you may not use this file except in compliance with the License.
|
||||||
|
# You may obtain a copy of the License at
|
||||||
|
#
|
||||||
|
# http://www.apache.org/licenses/LICENSE-2.0
|
||||||
|
#
|
||||||
|
# Unless required by applicable law or agreed to in writing, software
|
||||||
|
# distributed under the License is distributed on an "AS IS" BASIS,
|
||||||
|
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||||
|
# See the License for the specific language governing permissions and
|
||||||
|
# limitations under the License.
|
||||||
|
|
||||||
|
- project:
|
||||||
|
check:
|
||||||
|
jobs:
|
||||||
|
- openstack-ansible-linters
|
||||||
|
- openstack-ansible-functional-centos-7-nv
|
||||||
|
- openstack-ansible-functional-opensuse-423-nv
|
||||||
|
- openstack-ansible-functional-ubuntu-xenial-nv
|
||||||
|
gate:
|
||||||
|
jobs:
|
||||||
|
- openstack-ansible-linters
|
Loading…
Reference in New Issue
Block a user