Remove Midonet, Cassandra and Zookeeper
We removed Midonet from THT, we can now cleanup puppet-tripleo. It also removes the cassandra & zookeeper cluster manifests, created by the Midonet integrators. Note that Contrail is also using Cassandra and Zookeeper but not the removed code to deploy these components. Change-Id: If68485390dc11295872f7c3b859234cbf40a7796
This commit is contained in:
parent
8e4de1b75c
commit
1fa66c49c0
@ -1,73 +0,0 @@
|
||||
#
|
||||
# Copyright (C) 2015 Midokura SARL
|
||||
#
|
||||
# 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.
|
||||
#
|
||||
# == Class: tripleo::cluster::cassandra
|
||||
#
|
||||
# Deploys a cassandra service that belongs to a cluster. Uses puppet-cassandra
|
||||
#
|
||||
# == Parameters:
|
||||
#
|
||||
# [*cassandra_servers*]
|
||||
# (required) All the IP addresses of the cassandra cluster.
|
||||
# Array of strings value.
|
||||
#
|
||||
# [*cassandra_ip*]
|
||||
# (required) IP address of the current host.
|
||||
# String value
|
||||
#
|
||||
# [*storage_port*]
|
||||
# (optional) Inter-node cluster communication port.
|
||||
# Defaults to 7000.
|
||||
#
|
||||
# [*ssl_storage_port*]
|
||||
# (optional) SSL Inter-node cluster communication port.
|
||||
# Defaults to 7001.
|
||||
#
|
||||
# [*client_port*]
|
||||
# (optional) Cassandra client port.
|
||||
# Defaults to 9042.
|
||||
#
|
||||
# [*client_port_thrift*]
|
||||
# (optional) Cassandra client port thrift.
|
||||
# Defaults to 9160.
|
||||
#
|
||||
class tripleo::cluster::cassandra(
|
||||
$cassandra_servers,
|
||||
$cassandra_ip,
|
||||
$storage_port = '7000',
|
||||
$ssl_storage_port = '7001',
|
||||
$client_port = '9042',
|
||||
$client_port_thrift = '9160'
|
||||
)
|
||||
{
|
||||
|
||||
# TODO: Remove this comment once we can guarantee that all the distros
|
||||
# deploying TripleO use Puppet > 3.7 because of this bug:
|
||||
# https://tickets.puppetlabs.com/browse/PUP-1299
|
||||
#
|
||||
# validate_array($cassandra_servers)
|
||||
validate_legacy(Stdlib::IP::Address::V4, 'validate_ipv4_address', $cassandra_ip)
|
||||
|
||||
class {'::cassandra':
|
||||
cluster_name => 'TripleO',
|
||||
seeds => $cassandra_servers,
|
||||
listen_address => $cassandra_ip,
|
||||
storage_port => $storage_port,
|
||||
ssl_storage_port => $ssl_storage_port,
|
||||
native_transport_port => $client_port,
|
||||
rpc_port => $client_port_thrift
|
||||
}
|
||||
|
||||
}
|
@ -1,69 +0,0 @@
|
||||
#
|
||||
# Copyright (C) 2015 Midokura SARL
|
||||
#
|
||||
# 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.
|
||||
#
|
||||
# == Class: tripleo::cluster::zookeeper
|
||||
#
|
||||
# Deploys a zookeeper service that belongs to a cluster. Uses deric-zookeeper
|
||||
#
|
||||
# == Parameters:
|
||||
#
|
||||
# [*zookeeper_server_ips*]
|
||||
# (required) List of IP addresses of the zookeeper cluster.
|
||||
# Arrays of strings value.
|
||||
#
|
||||
# [*zookeeper_client_ip*]
|
||||
# (required) IP address of the host where zookeeper will listen IP addresses.
|
||||
# String (IPv4) value.
|
||||
#
|
||||
# [*zookeeper_hostnames*]
|
||||
# (required) List of hostnames of the zookeeper cluster. The hostname of the
|
||||
# node will be used to define the ID of the zookeeper configuration
|
||||
# Array of strings value.
|
||||
#
|
||||
|
||||
class tripleo::cluster::zookeeper(
|
||||
$zookeeper_server_ips,
|
||||
$zookeeper_client_ip,
|
||||
$zookeeper_hostnames
|
||||
)
|
||||
{
|
||||
# TODO: Remove comments below once we can guarantee that all the distros
|
||||
# deploying TripleO use Puppet > 3.7 because of this bug:
|
||||
# https://tickets.puppetlabs.com/browse/PUP-1299
|
||||
|
||||
# validate_array($zookeeper_server_ips)
|
||||
validate_legacy(Stdlib::IP::Address::V4, 'validate_ipv4_address', $zookeeper_client_ip)
|
||||
# validate_array($zookeeper_hostnames)
|
||||
|
||||
# TODO(devvesa) Zookeeper package should provide these paths,
|
||||
# remove this lines as soon as it will.
|
||||
file {['/usr/lib', '/usr/lib/zookeeper', '/usr/lib/zookeeper/bin/']:
|
||||
ensure => directory
|
||||
}
|
||||
|
||||
file {'/usr/lib/zookeeper/bin/zkEnv.sh':
|
||||
ensure => link,
|
||||
target => '/usr/libexec/zkEnv.sh'
|
||||
}
|
||||
|
||||
class {'::zookeeper':
|
||||
servers => $zookeeper_server_ips,
|
||||
client_ip => $zookeeper_client_ip,
|
||||
id => extract_id($zookeeper_hostnames, $::hostname),
|
||||
cfg_dir => '/etc/zookeeper/conf',
|
||||
}
|
||||
|
||||
File['/usr/lib/zookeeper/bin/zkEnv.sh'] -> Class['::zookeeper']
|
||||
}
|
@ -331,10 +331,6 @@
|
||||
# specific monitoring we do from HAProxy for Redis
|
||||
# Defaults to undef
|
||||
#
|
||||
# [*midonet_api*]
|
||||
# (optional) Enable or not MidoNet API binding
|
||||
# Defaults to false
|
||||
#
|
||||
# [*zaqar_api*]
|
||||
# (optional) Enable or not Zaqar Api binding
|
||||
# Defaults to hiera('zaqar_api_enabled', false)
|
||||
@ -671,7 +667,6 @@ class tripleo::haproxy (
|
||||
$docker_registry = hiera('enable_docker_registry', false),
|
||||
$redis = hiera('redis_enabled', false),
|
||||
$redis_password = undef,
|
||||
$midonet_api = false,
|
||||
$zaqar_api = hiera('zaqar_api_enabled', false),
|
||||
$ceph_rgw = hiera('ceph_rgw_enabled', false),
|
||||
$opendaylight = hiera('opendaylight_api_enabled', false),
|
||||
@ -754,7 +749,6 @@ class tripleo::haproxy (
|
||||
keystone_public_api_ssl_port => 13000,
|
||||
manila_api_port => 8786,
|
||||
manila_api_ssl_port => 13786,
|
||||
midonet_cluster_port => 8181,
|
||||
neutron_api_port => 9696,
|
||||
neutron_api_ssl_port => 13696,
|
||||
nova_api_port => 8774,
|
||||
@ -1509,25 +1503,6 @@ class tripleo::haproxy (
|
||||
}
|
||||
}
|
||||
|
||||
$midonet_cluster_vip = hiera('midonet_cluster_vip', $controller_virtual_ip)
|
||||
$midonet_bind_opts = {
|
||||
"${midonet_cluster_vip}:${ports[midonet_cluster_port]}" => [],
|
||||
"${public_virtual_ip}:${ports[midonet_cluster_port]}" => [],
|
||||
}
|
||||
|
||||
if $midonet_api {
|
||||
haproxy::listen { 'midonet_api':
|
||||
bind => $midonet_bind_opts,
|
||||
collect_exported => false,
|
||||
}
|
||||
haproxy::balancermember { 'midonet_api':
|
||||
listening_service => 'midonet_api',
|
||||
ports => $ports[midonet_cluster_port],
|
||||
ipaddresses => hiera('midonet_api_node_ips', $controller_hosts_real),
|
||||
server_names => hiera('midonet_api_node_names', $controller_hosts_names_real),
|
||||
options => $haproxy_member_options,
|
||||
}
|
||||
}
|
||||
if $zaqar_api {
|
||||
::tripleo::haproxy::endpoint { 'zaqar_api':
|
||||
public_virtual_ip => $public_virtual_ip,
|
||||
|
@ -1,66 +0,0 @@
|
||||
#
|
||||
# Copyright (C) 2015 Midokura SARL
|
||||
#
|
||||
# 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.
|
||||
#
|
||||
# == Class: tripleo::network::midonet::agent
|
||||
#
|
||||
# Configure the midonet agent
|
||||
#
|
||||
# == Parameters:
|
||||
#
|
||||
# [*zookeeper_servers*]
|
||||
# (required) List of IPs of the zookeeper server cluster. It will configure
|
||||
# the connection using the 2181 port.
|
||||
# Array of strings value.
|
||||
#
|
||||
# [*cassandra_seeds*]
|
||||
# (required) List of IPs of the cassandra cluster.
|
||||
# Array of strings value.
|
||||
#
|
||||
class tripleo::network::midonet::agent (
|
||||
$zookeeper_servers,
|
||||
$cassandra_seeds
|
||||
) {
|
||||
|
||||
# TODO: Remove comments below once we can guarantee that all the distros
|
||||
# deploying TripleO use Puppet > 3.7 because of this bug:
|
||||
# https://tickets.puppetlabs.com/browse/PUP-1299
|
||||
|
||||
# validate_array($zookeeper_servers)
|
||||
# validate_array($cassandra_seeds)
|
||||
|
||||
|
||||
# FIXME: This statement should be controlled by hiera on heat templates
|
||||
# project
|
||||
# Make sure openvswitch service is not running
|
||||
service {'openvswitch':
|
||||
ensure => stopped,
|
||||
enable => false
|
||||
}
|
||||
|
||||
exec {'delete datapaths':
|
||||
command => '/usr/bin/mm-dpctl --delete-dp ovs-system',
|
||||
path => '/usr/bin:/usr/sbin:/bin',
|
||||
onlyif => '/usr/bin/mm-dpctl --show-dp ovs-system'
|
||||
}
|
||||
|
||||
# Configure and run the agent
|
||||
class {'::midonet::midonet_agent':
|
||||
zk_servers => list_to_zookeeper_hash($zookeeper_servers),
|
||||
cassandra_seeds => $cassandra_seeds
|
||||
}
|
||||
|
||||
Service['openvswitch'] -> Class['::midonet::midonet_agent::run']
|
||||
Exec['delete datapaths'] -> Class['::midonet::midonet_agent::run']
|
||||
}
|
@ -1,52 +0,0 @@
|
||||
# Copyright 2016 Red Hat, 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.
|
||||
#
|
||||
# == Class: tripleo::profile::base::neutron::agents::midonet
|
||||
#
|
||||
# Midonet Neutron agent profile
|
||||
#
|
||||
# === Parameters
|
||||
#
|
||||
# [*midonet_libvirt_qemu_data*]
|
||||
# (Optional) qemu.conf data for midonet.
|
||||
# Defaults to hiera('midonet_libvirt_qemu_data')
|
||||
#
|
||||
# [*neutron_api_node_ips*]
|
||||
# (Optional) The IPs of the Neutron API hosts
|
||||
# Defaults to hiera('neutron_api_node_ips')
|
||||
#
|
||||
# [*step*]
|
||||
# (Optional) The current step of the deployment
|
||||
# Defaults to hiera('step')
|
||||
#
|
||||
class tripleo::profile::base::neutron::agents::midonet (
|
||||
$midonet_libvirt_qemu_data = hiera('midonet_libvirt_qemu_data', ''),
|
||||
$neutron_api_node_ips = hiera('neutron_api_node_ips', ''),
|
||||
$step = Integer(hiera('step')),
|
||||
) {
|
||||
if $step >= 4 {
|
||||
# TODO(devvesa) provide non-controller ips for these services
|
||||
class { '::tripleo::network::midonet::agent':
|
||||
zookeeper_servers => $neutron_api_node_ips,
|
||||
cassandra_seeds => $neutron_api_node_ips
|
||||
}
|
||||
|
||||
if defined(Service['libvirt']) {
|
||||
file { '/etc/libvirt/qemu.conf':
|
||||
ensure => present,
|
||||
content => hiera('midonet_libvirt_qemu_data')
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
@ -1,116 +0,0 @@
|
||||
# Copyright 2016 Red Hat, 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.
|
||||
#
|
||||
# == Class: tripleo::profile::base::neutron::midonet
|
||||
#
|
||||
# Midonet Neutron profile for tripleo
|
||||
#
|
||||
# === Parameters
|
||||
#
|
||||
# [*admin_password*]
|
||||
# (Optional) Admin Password for Midonet API
|
||||
# Defaults to hiera('admin_password')
|
||||
#
|
||||
# [*bind_address*]
|
||||
# (Optional) The address to bind Cassandra and Midonet API to
|
||||
# Defaults to hiera('neutron::bind_host')
|
||||
#
|
||||
# [*keystone_admin_token*]
|
||||
# (Optional) The Keystone Admin Token
|
||||
# Defaults to hiera('keystone::admin_token')
|
||||
#
|
||||
# [*neutron_api_node_ips*]
|
||||
# (Optional) The IPs of the Neutron API hosts
|
||||
# Defaults to hiera('neutron_api_node_ips')
|
||||
#
|
||||
# [*neutron_auth_password*]
|
||||
# (Optional) Password to use for Neutron authentication
|
||||
# Defaults to hiera('neutron::server::password')
|
||||
#
|
||||
# [*neutron_auth_tenant*]
|
||||
# (Optional) Tenant to use for Neutron authentication
|
||||
# Defaults to hiera('neutron::server::project_name')
|
||||
#
|
||||
# [*step*]
|
||||
# (Optional) The current step of the deployment
|
||||
# Defaults to hiera('step')
|
||||
#
|
||||
# [*vip*]
|
||||
# (Optional) Public Virtual IP Address for this cloud
|
||||
# Defaults to hiera('public_virtual_ip')
|
||||
#
|
||||
# [*zk_on_controller*]
|
||||
# (Optional) Whether to put zookeeper on the controllers
|
||||
# Defaults to hiera('enable_zookeeper_on_controller')
|
||||
#
|
||||
# [*zookeeper_client_ip*]
|
||||
# (Optional) The IP of the Zookeeper Client
|
||||
# Defaults to hiera('neutron::bind_host')
|
||||
#
|
||||
# [*zookeeper_hostnames*]
|
||||
# (Optional) The IPs of the Zookeeper Servers
|
||||
# Defaults to hiera('controller_node_names')
|
||||
#
|
||||
class tripleo::profile::base::neutron::midonet (
|
||||
$admin_password = hiera('admin_password', ''),
|
||||
$bind_address = hiera('neutron::bind_host', ''),
|
||||
$keystone_admin_token = hiera('keystone::admin_token', ''),
|
||||
$neutron_api_node_ips = hiera('neutron_api_node_ips', ''),
|
||||
$neutron_auth_password = hiera('neutron::keystone::authtoken::password', ''),
|
||||
$neutron_auth_tenant = hiera('neutron::keystone::authtoken::project_name', ''),
|
||||
$step = Integer(hiera('step')),
|
||||
$vip = hiera('public_virtual_ip'),
|
||||
$zk_on_controller = hiera('enable_zookeeper_on_controller', ''),
|
||||
$zookeeper_client_ip = hiera('neutron::bind_host', ''),
|
||||
$zookeeper_hostnames = hiera('controller_node_names', ''),
|
||||
) {
|
||||
include ::tripleo::profile::base::neutron
|
||||
include ::tripleo::profile::base::neutron::agents::midonet
|
||||
|
||||
if $step >= 4 {
|
||||
|
||||
# Run zookeeper in the controller if configured
|
||||
if zk_on_controller {
|
||||
class {'::tripleo::cluster::zookeeper':
|
||||
zookeeper_server_ips => $neutron_api_node_ips,
|
||||
# TODO: create a 'bind' hiera key for zookeeper
|
||||
zookeeper_client_ip => $zookeeper_client_ip,
|
||||
zookeeper_hostnames => split($zookeeper_hostnames, ',')
|
||||
}
|
||||
}
|
||||
|
||||
# Run cassandra in the controller if configured
|
||||
if hiera('enable_cassandra_on_controller') {
|
||||
class {'::tripleo::cluster::cassandra':
|
||||
cassandra_servers => $neutron_api_node_ips,
|
||||
cassandra_ip => $bind_address,
|
||||
}
|
||||
}
|
||||
|
||||
class {'::tripleo::network::midonet::api':
|
||||
zookeeper_servers => $neutron_api_node_ips,
|
||||
vip => $vip,
|
||||
keystone_ip => $vip,
|
||||
keystone_admin_token => $keystone_admin_token,
|
||||
bind_address => $bind_address,
|
||||
admin_password => $admin_password,
|
||||
}
|
||||
|
||||
class {'::neutron::plugins::midonet':
|
||||
midonet_api_ip => $vip,
|
||||
keystone_tenant => $neutron_auth_tenant,
|
||||
keystone_password => $neutron_auth_password
|
||||
}
|
||||
}
|
||||
}
|
Loading…
x
Reference in New Issue
Block a user