Puppet Class: tripleo::profile::base::octavia

Defined in:
manifests/profile/base/octavia.pp

Overview

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::octavia

Octavia server profile for tripleo

Parameters

step

(Optional) The current step of the deployment Defaults to Integer(lookup(‘step’))

oslomsg_rpc_proto

Protocol driver for the oslo messaging rpc service Defaults to lookup(‘oslo_messaging_rpc_scheme’, undef, undef, ‘rabbit’)

oslomsg_rpc_hosts

list of the oslo messaging rpc host fqdns Defaults to any2array(lookup(‘oslo_messaging_rpc_node_names’, undef, undef, undef))

oslomsg_rpc_port

IP port for oslo messaging rpc service Defaults to lookup(‘oslo_messaging_rpc_port’, undef, undef, ‘5672’)

oslomsg_rpc_username

Username for oslo messaging rpc service Defaults to lookup(‘oslo_messaging_rpc_user_name’, undef, undef, ‘guest’)

oslomsg_rpc_password

Password for oslo messaging rpc service Defaults to lookup(‘oslo_messaging_rpc_password’)

oslomsg_rpc_use_ssl

Enable ssl oslo messaging services Defaults to lookup(‘oslo_messaging_rpc_use_ssl’, undef, undef, ‘0’)

enable_driver_agent

Enable the driver agent Defaults to false

Parameters:

  • step (Any) (defaults to: Integer(lookup('step')))
  • oslomsg_rpc_proto (Any) (defaults to: lookup('oslo_messaging_rpc_scheme', undef, undef, 'rabbit'))
  • oslomsg_rpc_hosts (Any) (defaults to: any2array(lookup('oslo_messaging_rpc_node_names', undef, undef, undef)))
  • oslomsg_rpc_password (Any) (defaults to: lookup('oslo_messaging_rpc_password'))
  • oslomsg_rpc_port (Any) (defaults to: lookup('oslo_messaging_rpc_port', undef, undef, '5672'))
  • oslomsg_rpc_username (Any) (defaults to: lookup('oslo_messaging_rpc_user_name', undef, undef, 'guest'))
  • oslomsg_rpc_use_ssl (Any) (defaults to: lookup('oslo_messaging_rpc_use_ssl', undef, undef, '0'))
  • enable_driver_agent (Any) (defaults to: false)


53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
# File 'manifests/profile/base/octavia.pp', line 53

class tripleo::profile::base::octavia (
  $step                 = Integer(lookup('step')),
  $oslomsg_rpc_proto    = lookup('oslo_messaging_rpc_scheme', undef, undef, 'rabbit'),
  $oslomsg_rpc_hosts    = any2array(lookup('oslo_messaging_rpc_node_names', undef, undef, undef)),
  $oslomsg_rpc_password = lookup('oslo_messaging_rpc_password'),
  $oslomsg_rpc_port     = lookup('oslo_messaging_rpc_port', undef, undef, '5672'),
  $oslomsg_rpc_username = lookup('oslo_messaging_rpc_user_name', undef, undef, 'guest'),
  $oslomsg_rpc_use_ssl  = lookup('oslo_messaging_rpc_use_ssl', undef, undef, '0'),
  $enable_driver_agent  = false
) {
  if $step >= 3 {
    $oslomsg_rpc_use_ssl_real = sprintf('%s', bool2num(str2bool($oslomsg_rpc_use_ssl)))
    class { 'octavia' :
      default_transport_url => os_transport_url({
        'transport' => $oslomsg_rpc_proto,
        'hosts'     => $oslomsg_rpc_hosts,
        'port'      => sprintf('%s', $oslomsg_rpc_port),
        'username'  => $oslomsg_rpc_username,
        'password'  => $oslomsg_rpc_password,
        'ssl'       => $oslomsg_rpc_use_ssl_real,
        }),
    }
    include octavia::config
    include octavia::db
    include octavia::logging
    include octavia::networking
    include octavia::service_auth

    if $enable_driver_agent {
      include octavia::driver_agent
    }
  }
}