Merge "Remove sahara support"

This commit is contained in:
Zuul 2024-03-06 19:38:07 +00:00 committed by Gerrit Code Review
commit e6e8c93d95
19 changed files with 7 additions and 298 deletions

View File

@ -25,7 +25,6 @@
- openstack/puppet-oslo
- openstack/puppet-ovn
- openstack/puppet-placement
- openstack/puppet-sahara
- openstack/puppet-swift
- openstack/puppet-tempest
- openstack/puppet-trove

View File

@ -70,10 +70,6 @@ mod 'placement',
:git => 'https://github.com/openstack/puppet-placement',
:ref => 'master'
mod 'sahara',
:git => 'https://github.com/openstack/puppet-sahara',
:ref => 'master'
mod 'swift',
:git => 'https://github.com/openstack/puppet-swift',
:ref => 'master'

View File

@ -250,7 +250,6 @@ aodh X X
gnocchi X X
heat X
swift X X
sahara X
trove X
horizon X
manila X

View File

@ -72,9 +72,6 @@ Global Options
**CONFIG_MAGNUM_INSTALL**
Specify 'y' to install OpenStack Container Infrastructure Management Service (magnum). ['y', 'n']
**CONFIG_SAHARA_INSTALL**
Specify 'y' to install OpenStack Data Processing (sahara). In case of sahara installation packstack also installs heat.['y', 'n']
**CONFIG_TROVE_INSTALL**
Specify 'y' to install OpenStack Database (trove) ['y', 'n']
@ -170,9 +167,6 @@ Global unsupported options
**CONFIG_STORAGE_HOST**
(Unsupported!) Server on which to install OpenStack services specific to storage servers such as Image or Block Storage services.
**CONFIG_SAHARA_HOST**
(Unsupported!) Server on which to install OpenStack services specific to OpenStack Data Processing (sahara).
Server Prepare Configs
-----------------------
@ -1071,15 +1065,6 @@ Gnocchi Config parameters
Password to use for Gnocchi to authenticate with the Identity service.
Sahara Config parameters
------------------------
**CONFIG_SAHARA_DB_PW**
Password to use for OpenStack Data Processing (sahara) to access the database.
**CONFIG_SAHARA_KS_PW**
Password to use for OpenStack Data Processing to authenticate with the Identity service.
Trove config parameters
-----------------------

View File

@ -125,8 +125,6 @@ def process_password(param, param_name, config=None):
def process_heat(param, param_name, config=None):
if config["CONFIG_SAHARA_INSTALL"] == 'y':
param = 'y'
return param

View File

@ -231,21 +231,6 @@ def initConfig(controller):
"NEED_CONFIRM": False,
"CONDITION": False},
{"CMD_OPTION": "os-sahara-install",
"PROMPT": (
"Should Packstack install OpenStack Clustering (Sahara)."
" If yes it'll also install Heat."
),
"OPTION_LIST": ["y", "n"],
"VALIDATORS": [validators.validate_options],
"DEFAULT_VALUE": "n",
"MASK_INPUT": False,
"LOOSE_VALIDATION": False,
"CONF_NAME": "CONFIG_SAHARA_INSTALL",
"USE_DEFAULT": False,
"NEED_CONFIRM": False,
"CONDITION": False},
{"CMD_OPTION": "os-heat-install",
"PROMPT": (
"Should Packstack install OpenStack Orchestration (Heat)"
@ -518,18 +503,6 @@ def initConfig(controller):
"USE_DEFAULT": False,
"NEED_CONFIRM": False,
"CONDITION": False},
{"CONF_NAME": "CONFIG_SAHARA_HOST",
"CMD_OPTION": "os-sahara-host",
"PROMPT": "Enter the host for the Sahara",
"OPTION_LIST": [],
"VALIDATORS": [validators.validate_ssh],
"DEFAULT_VALUE": utils.get_localhost_ip(),
"MASK_INPUT": False,
"LOOSE_VALIDATION": False,
"USE_DEFAULT": False,
"NEED_CONFIRM": False,
"CONDITION": False},
],
"SERVERPREPARE": [

View File

@ -151,9 +151,8 @@ def copy_puppet_modules(config, messages):
'memcached', 'mysql', 'neutron', 'nova', 'nssdb',
'openstacklib', 'oslo', 'ovn', 'packstack',
'placement', 'rabbitmq', 'redis', 'remote', 'rsync',
'sahara', 'ssh', 'stdlib', 'swift', 'sysctl',
'systemd', 'tempest', 'trove', 'vcsrepo', 'vswitch',
'xinetd'))
'ssh', 'stdlib', 'swift', 'sysctl', 'systemd',
'tempest', 'trove', 'vcsrepo', 'vswitch', 'xinetd'))
# write puppet manifest to disk
manifestfiles.writeManifests()

View File

@ -1,108 +0,0 @@
# -*- coding: utf-8 -*-
# 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.
"""
Installs and configures Sahara
"""
from packstack.installer import basedefs
from packstack.installer import utils
from packstack.installer import validators
from packstack.installer import processors
from packstack.modules.documentation import update_params_usage
from packstack.modules.ospluginutils import generate_ssl_cert
# ------------------ Sahara installer initialization ------------------
PLUGIN_NAME = "OS-Sahara"
PLUGIN_NAME_COLORED = utils.color_text(PLUGIN_NAME, "blue")
def initConfig(controller):
params = [
{"CONF_NAME": "CONFIG_SAHARA_DB_PW",
"CMD_OPTION": "sahara-db-passwd",
"PROMPT": "Enter the password to use for Sahara to access the DB",
"OPTION_LIST": [],
"VALIDATORS": [validators.validate_not_empty],
"DEFAULT_VALUE": "PW_PLACEHOLDER",
"PROCESSORS": [processors.process_password],
"MASK_INPUT": True,
"LOOSE_VALIDATION": False,
"USE_DEFAULT": False,
"NEED_CONFIRM": True,
"CONDITION": False},
{"CONF_NAME": "CONFIG_SAHARA_KS_PW",
"CMD_OPTION": "sahara-ks-passwd",
"PROMPT": "Enter the password for Sahara Keystone access",
"OPTION_LIST": [],
"VALIDATORS": [validators.validate_not_empty],
"DEFAULT_VALUE": "PW_PLACEHOLDER",
"PROCESSORS": [processors.process_password],
"MASK_INPUT": True,
"LOOSE_VALIDATION": False,
"USE_DEFAULT": False,
"NEED_CONFIRM": True,
"CONDITION": False},
]
update_params_usage(basedefs.PACKSTACK_DOC, params, sectioned=False)
group = {"GROUP_NAME": "SAHARA",
"DESCRIPTION": "Sahara Config parameters",
"PRE_CONDITION": "CONFIG_SAHARA_INSTALL",
"PRE_CONDITION_MATCH": "y",
"POST_CONDITION": False,
"POST_CONDITION_MATCH": True}
controller.addGroup(group, params)
def initSequences(controller):
conf = controller.CONF
if conf["CONFIG_SAHARA_INSTALL"] != 'y':
return
saharasteps = [
{"title": "Preparing Sahara entries",
"functions": [create_manifest]},
]
controller.addSequence("Installing Sahara", [], [], saharasteps)
# -------------------------- step functions --------------------------
def create_manifest(config, messages):
if config['CONFIG_UNSUPPORTED'] != 'y':
config['CONFIG_SAHARA_HOST'] = config['CONFIG_CONTROLLER_HOST']
if config['CONFIG_AMQP_ENABLE_SSL'] == 'y':
ssl_host = config['CONFIG_SAHARA_HOST']
ssl_cert_file = config['CONFIG_SAHARA_SSL_CERT'] = (
'/etc/pki/tls/certs/ssl_amqp_sahara.crt'
)
ssl_key_file = config['CONFIG_SAHARA_SSL_KEY'] = (
'/etc/pki/tls/private/ssl_amqp_sahara.key'
)
service = 'sahara'
generate_ssl_cert(config, ssl_host, service, ssl_key_file,
ssl_cert_file)
fw_details = dict()
key = "sahara-api"
fw_details.setdefault(key, {})
fw_details[key]["host"] = "ALL"
fw_details[key]["service_name"] = "sahara api"
fw_details[key]["chain"] = "INPUT"
fw_details[key]["ports"] = ["8386"]
fw_details[key]["proto"] = "tcp"
config["FIREWALL_SAHARA_CFN_RULES"] = fw_details

View File

@ -52,10 +52,6 @@ class packstack::horizon ()
ensure_packages(['openstack-trove-ui'], {'ensure' => 'present'})
}
if lookup('CONFIG_SAHARA_INSTALL') == 'y' {
ensure_packages(['openstack-sahara-ui'], {'ensure' => 'present'})
}
if lookup('CONFIG_HEAT_INSTALL') == 'y' {
ensure_packages(['openstack-heat-ui'], {'ensure' => 'present'})
}

View File

@ -1,14 +0,0 @@
class packstack::keystone::sahara ()
{
$sahara_protocol = 'http'
$sahara_host = lookup('CONFIG_KEYSTONE_HOST_URL')
$sahara_port = '8386'
$sahara_url = "${sahara_protocol}://${sahara_host}:${sahara_port}"
class { 'sahara::keystone::auth':
password => lookup('CONFIG_SAHARA_KS_PW'),
public_url => $sahara_url,
admin_url => $sahara_url,
internal_url => $sahara_url,
}
}

View File

@ -108,15 +108,6 @@ class packstack::mariadb::services ()
}
}
if lookup('CONFIG_SAHARA_INSTALL') == 'y' {
class { 'sahara::db::mysql':
password => lookup('CONFIG_SAHARA_DB_PW'),
host => '%',
allowed_hosts => '%',
}
}
if lookup('CONFIG_TROVE_INSTALL') == 'y' {
class { 'trove::db::mysql':
password => lookup('CONFIG_TROVE_DB_PW'),

View File

@ -413,37 +413,6 @@ class packstack::mariadb::services_remote () {
}
if lookup('CONFIG_SAHARA_INSTALL') == 'y' {
remote_database { 'sahara':
ensure => 'present',
charset => 'utf8',
db_host => lookup('CONFIG_MARIADB_HOST'),
db_user => lookup('CONFIG_MARIADB_USER'),
db_password => lookup('CONFIG_MARIADB_PW'),
provider => 'mysql',
}
$sahara_cfg_sahara_db_pw = lookup('CONFIG_SAHARA_DB_PW')
remote_database_user { 'sahara@%':
password_hash => mysql_password($sahara_cfg_sahara_db_pw),
db_host => lookup('CONFIG_MARIADB_HOST'),
db_user => lookup('CONFIG_MARIADB_USER'),
db_password => lookup('CONFIG_MARIADB_PW'),
provider => 'mysql',
require => Remote_database['sahara'],
}
remote_database_grant { 'sahara@%/sahara':
privileges => 'all',
db_host => lookup('CONFIG_MARIADB_HOST'),
db_user => lookup('CONFIG_MARIADB_USER'),
db_password => lookup('CONFIG_MARIADB_PW'),
provider => 'mysql',
require => Remote_database_user['sahara@%'],
}
}
if lookup('CONFIG_TROVE_INSTALL') == 'y' {
remote_database { 'trove':
ensure => 'present',

View File

@ -89,7 +89,6 @@ class packstack::provision::tempest ()
$ceilometer_available = str2bool(lookup('CONFIG_CEILOMETER_INSTALL'))
$aodh_available = str2bool(lookup('CONFIG_AODH_INSTALL'))
$trove_available = str2bool(lookup('CONFIG_TROVE_INSTALL'))
$sahara_available = str2bool(lookup('CONFIG_SAHARA_INSTALL'))
$heat_available = str2bool(lookup('CONFIG_HEAT_INSTALL'))
$swift_available = str2bool(lookup('CONFIG_SWIFT_INSTALL'))
$configure_tempest = str2bool(lookup('CONFIG_PROVISION_TEMPEST'))
@ -143,7 +142,6 @@ class packstack::provision::tempest ()
public_network_name => $public_network_name,
public_router_id => $public_router_id,
resize_available => $resize_available,
sahara_available => $sahara_available,
ssh_key_type => $ssh_key_type,
swift_available => $swift_available,
tempest_workspace => $tempest_workspace,

View File

@ -1,10 +0,0 @@
class packstack::sahara ()
{
create_resources(packstack::firewall, lookup('FIREWALL_SAHARA_CFN_RULES', undef, undef, {}))
class { 'sahara::service::api':
api_workers => lookup('CONFIG_SERVICE_WORKERS')
}
class { 'sahara::service::engine': }
}

View File

@ -1,6 +0,0 @@
class packstack::sahara::ceilometer ()
{
class { 'sahara::notify':
notification_driver => 'messagingv2',
}
}

View File

@ -1,50 +0,0 @@
class packstack::sahara::rabbitmq ()
{
$sahara_cfg_sahara_db_pw = lookup('CONFIG_SAHARA_DB_PW')
$sahara_cfg_sahara_mariadb_host = lookup('CONFIG_MARIADB_HOST_URL')
$kombu_ssl_ca_certs = lookup('CONFIG_AMQP_SSL_CACERT_FILE', undef, undef, $::os_service_default)
$kombu_ssl_keyfile = lookup('CONFIG_SAHARA_SSL_KEY', undef, undef, $::os_service_default)
$kombu_ssl_certfile = lookup('CONFIG_SAHARA_SSL_CERT', undef, undef, $::os_service_default)
$rabbit_host = lookup('CONFIG_AMQP_HOST_URL')
$rabbit_port = lookup('CONFIG_AMQP_CLIENTS_PORT')
$rabbit_userid = lookup('CONFIG_AMQP_AUTH_USER')
$rabbit_password = lookup('CONFIG_AMQP_AUTH_PASSWORD')
if ! is_service_default($kombu_ssl_keyfile) {
$files_to_set_owner = [ $kombu_ssl_keyfile, $kombu_ssl_certfile ]
file { $files_to_set_owner:
owner => 'sahara',
group => 'sahara',
require => Package['sahara-common'],
}
File[$files_to_set_owner] ~> Service<| tag == 'sahara-service' |>
}
Service<| name == 'rabbitmq-server' |> -> Service<| tag == 'sahara-service' |>
class { 'sahara::keystone::authtoken':
username => 'sahara',
password => lookup('CONFIG_SAHARA_KS_PW'),
project_name => 'services',
www_authenticate_uri => lookup('CONFIG_KEYSTONE_PUBLIC_URL'),
auth_url => lookup('CONFIG_KEYSTONE_ADMIN_URL'),
}
class { 'sahara::logging':
debug => lookup('CONFIG_DEBUG_MODE'),
}
class { 'sahara::db':
database_connection => "mysql+pymysql://sahara:${sahara_cfg_sahara_db_pw}@${sahara_cfg_sahara_mariadb_host}/sahara",
}
class { 'sahara':
host => lookup('CONFIG_SAHARA_HOST'),
rabbit_use_ssl => lookup('CONFIG_AMQP_SSL_ENABLED'),
default_transport_url => "rabbit://${rabbit_userid}:${rabbit_password}@${rabbit_host}:${rabbit_port}/",
kombu_ssl_ca_certs => $kombu_ssl_ca_certs,
kombu_ssl_keyfile => $kombu_ssl_keyfile,
kombu_ssl_certfile => $kombu_ssl_certfile,
}
}

View File

@ -189,12 +189,3 @@ if lookup('CONFIG_TROVE_INSTALL') == 'y' {
include 'packstack::trove::rabbitmq'
include 'packstack::trove'
}
if lookup('CONFIG_SAHARA_INSTALL') == 'y' {
include 'packstack::keystone::sahara'
include 'packstack::sahara::rabbitmq'
include 'packstack::sahara'
if lookup('CONFIG_CEILOMETER_INSTALL') == 'y' {
include 'packstack::sahara::ceilometer'
}
}

View File

@ -0,0 +1,5 @@
---
upgrade:
- |
Sahara support has been removed because the sahara project is no longer
maintained.

View File

@ -12,7 +12,6 @@ echo -e "Generating packstack config for:
- nova
- neutron (ovs+vxlan)
- swift
- sahara
- trove
- tempest (regex: 'smoke dashboard')"
echo "tempest will run if packstack's installation completes successfully."
@ -39,7 +38,6 @@ $SUDO packstack ${ADDITIONAL_ARGS} \
--os-neutron-ml2-type-drivers="vxlan,flat" \
--os-neutron-ml2-tenant-network-types="vxlan" \
--os-neutron-vpnaas-install=n \
--os-sahara-install=y \
--os-trove-install=y \
--nova-libvirt-virt-type=qemu \
--provision-image-url="/tmp/cirros/cirros-$CIRROS_VERSION-$CIRROS_ARCH-disk.img" \