flatten opendaylight-api service
This change combines the previous puppet and docker files into a single file that performs the docker service installation and configuration for the opendaylight-api service. Related-Blueprint: services-yaml-flattening Change-Id: I86b36756bade09529921d59f13b0ef950fa00a96
This commit is contained in:
parent
9c5e403e94
commit
3997198c2a
@ -1,7 +1,7 @@
|
||||
resource_registry:
|
||||
OS::TripleO::Controller::Net::SoftwareConfig: ../common/net-config-multinode.yaml
|
||||
OS::TripleO::Compute::Net::SoftwareConfig: ../common/net-config-multinode.yaml
|
||||
OS::TripleO::Services::OpenDaylightApi: ../../docker/services/opendaylight-api.yaml
|
||||
OS::TripleO::Services::OpenDaylightApi: ../../deployment/deprecated/opendaylight/opendaylight-api-container-puppet.yaml
|
||||
OS::TripleO::Services::OpenDaylightOvs: ../../puppet/services/opendaylight-ovs.yaml
|
||||
OS::TripleO::Docker::NeutronMl2PluginBase: ../../puppet/services/neutron-plugin-ml2-odl.yaml
|
||||
# Disable OVN services
|
||||
|
@ -52,6 +52,60 @@ parameters:
|
||||
- allowed_values:
|
||||
- 1
|
||||
- 2
|
||||
OpenDaylightUsername:
|
||||
default: 'admin'
|
||||
description: The username for the opendaylight server.
|
||||
type: string
|
||||
OpenDaylightPassword:
|
||||
type: string
|
||||
description: The password for the opendaylight server.
|
||||
hidden: true
|
||||
OpenDaylightFeatures:
|
||||
description: List of features to install with ODL
|
||||
type: comma_delimited_list
|
||||
default: ["odl-netvirt-openstack","odl-jolokia"]
|
||||
OpenDaylightManageRepositories:
|
||||
description: Whether to manage the OpenDaylight repository
|
||||
type: boolean
|
||||
default: false
|
||||
OpenDaylightSNATMechanism:
|
||||
description: SNAT mechanism to be used
|
||||
default: 'conntrack'
|
||||
type: string
|
||||
constraints:
|
||||
- allowed_values:
|
||||
- conntrack
|
||||
- controller
|
||||
OpenDaylightLogMechanism:
|
||||
description: Logging mechanism to be used
|
||||
default: 'file'
|
||||
type: string
|
||||
constraints:
|
||||
- allowed_values:
|
||||
- file
|
||||
- console
|
||||
OpenDaylightTLSKeystorePassword:
|
||||
default: 'opendaylight'
|
||||
type: string
|
||||
description: The password for the opendaylight TLS keystore.
|
||||
Must be at least 6 characters.
|
||||
hidden: true
|
||||
OpenDaylightInheritDSCPMarking:
|
||||
description: Enable DSCP marking for VXLAN/GRE tunnels
|
||||
type: boolean
|
||||
default: false
|
||||
OpenDaylightJavaOpts:
|
||||
default: ''
|
||||
type: string
|
||||
description: Specifies the Java options to run ODL with as a string.
|
||||
Note, these options are in addition to the default Java
|
||||
options set by the karaf/ODL boot scripts and IP version
|
||||
based flag set by 'opendaylight' class.
|
||||
OpenDaylightInactivityProbe:
|
||||
description: Time in millseconds before an inactivity probe is sent via
|
||||
OVSDB to OVS
|
||||
type: number
|
||||
default: 180000
|
||||
|
||||
conditions:
|
||||
|
||||
@ -60,17 +114,7 @@ conditions:
|
||||
resources:
|
||||
|
||||
ContainersCommon:
|
||||
type: ./containers-common.yaml
|
||||
|
||||
OpenDaylightBase:
|
||||
type: ../../puppet/services/opendaylight-api.yaml
|
||||
properties:
|
||||
EndpointMap: {get_param: EndpointMap}
|
||||
ServiceData: {get_param: ServiceData}
|
||||
ServiceNetMap: {get_param: ServiceNetMap}
|
||||
DefaultPasswords: {get_param: DefaultPasswords}
|
||||
RoleName: {get_param: RoleName}
|
||||
RoleParameters: {get_param: RoleParameters}
|
||||
type: ../../../docker/services/containers-common.yaml
|
||||
|
||||
OpenDaylightApiLogging:
|
||||
type: OS::TripleO::Services::Logging::OpenDaylightApi
|
||||
@ -79,14 +123,55 @@ outputs:
|
||||
role_data:
|
||||
description: Role data for the OpenDaylight API role.
|
||||
value:
|
||||
service_name: {get_attr: [OpenDaylightBase, role_data, service_name]}
|
||||
service_name: opendaylight_api
|
||||
config_settings:
|
||||
map_merge:
|
||||
- get_attr: [OpenDaylightBase, role_data, config_settings]
|
||||
- if:
|
||||
- internal_tls_enabled
|
||||
- tripleo::certmonger::opendaylight::postsave_cmd: "true" # TODO: restart the odl container here
|
||||
- {}
|
||||
-
|
||||
opendaylight::odl_rest_port: {get_param: [EndpointMap, OpenDaylightInternal, port]}
|
||||
opendaylight::username: {get_param: OpenDaylightUsername}
|
||||
opendaylight::password: {get_param: OpenDaylightPassword}
|
||||
opendaylight::extra_features: {get_param: OpenDaylightFeatures}
|
||||
opendaylight::odl_bind_ip:
|
||||
str_replace:
|
||||
template:
|
||||
"%{hiera('$NETWORK')}"
|
||||
params:
|
||||
$NETWORK: {get_param: [ServiceNetMap, OpendaylightApiNetwork]}
|
||||
opendaylight::manage_repositories: {get_param: OpenDaylightManageRepositories}
|
||||
tripleo::opendaylight_api::firewall_rules:
|
||||
'137 opendaylight api':
|
||||
dport:
|
||||
- {get_param: [EndpointMap, OpenDaylightInternal, port]}
|
||||
- 6640
|
||||
- 6653
|
||||
- 2550
|
||||
- 8185
|
||||
opendaylight::snat_mechanism: {get_param: OpenDaylightSNATMechanism}
|
||||
opendaylight::log_mechanism: {get_param: OpenDaylightLogMechanism}
|
||||
opendaylight::inherit_dscp_marking: {get_param: OpenDaylightInheritDSCPMarking}
|
||||
opendaylight::java_opts: {get_param: OpenDaylightJavaOpts}
|
||||
opendaylight::inactivity_probe: {get_param: OpenDaylightInactivityProbe}
|
||||
-
|
||||
if:
|
||||
- internal_tls_enabled
|
||||
- generate_service_certificates: true
|
||||
tripleo::profile::base::neutron::opendaylight::certificate_specs:
|
||||
service_certificate: '/etc/pki/tls/certs/odl.crt'
|
||||
service_key: '/etc/pki/tls/private/odl.key'
|
||||
hostname:
|
||||
str_replace:
|
||||
template: "%{hiera('fqdn_NETWORK')}"
|
||||
params:
|
||||
NETWORK: {get_param: [ServiceNetMap, OpendaylightApiNetwork]}
|
||||
principal:
|
||||
str_replace:
|
||||
template: "odl/%{hiera('fqdn_NETWORK')}"
|
||||
params:
|
||||
NETWORK: {get_param: [ServiceNetMap, OpendaylightApiNetwork]}
|
||||
opendaylight::tls_ca_cert_file: {get_param: InternalTLSCAFile}
|
||||
opendaylight::tls_keystore_password: {get_param: OpenDaylightTLSKeystorePassword}
|
||||
tripleo::certmonger::opendaylight::postsave_cmd: "true" # TODO: restart the odl container here
|
||||
- {}
|
||||
# BEGIN DOCKER SETTINGS
|
||||
puppet_config:
|
||||
config_volume: opendaylight
|
||||
@ -104,8 +189,8 @@ outputs:
|
||||
- null
|
||||
# 'file,concat,file_line,augeas' are included by default
|
||||
puppet_tags: odl_user,odl_keystore
|
||||
step_config:
|
||||
get_attr: [OpenDaylightBase, role_data, step_config]
|
||||
step_config: |
|
||||
include tripleo::profile::base::neutron::opendaylight
|
||||
config_image: {get_param: DockerOpendaylightConfigImage}
|
||||
kolla_config:
|
||||
/var/lib/kolla/config_files/opendaylight_api.json:
|
||||
@ -143,7 +228,13 @@ outputs:
|
||||
environment:
|
||||
- KOLLA_CONFIG_STRATEGY=COPY_ALWAYS
|
||||
metadata_settings:
|
||||
get_attr: [OpenDaylightBase, role_data, metadata_settings]
|
||||
if:
|
||||
- internal_tls_enabled
|
||||
-
|
||||
- service: odl
|
||||
network: {get_param: [ServiceNetMap, OpendaylightApiNetwork]}
|
||||
type: node
|
||||
- null
|
||||
host_prep_tasks:
|
||||
list_concat:
|
||||
- {get_attr: [OpenDaylightApiLogging, host_prep_tasks]}
|
||||
@ -239,8 +330,8 @@ outputs:
|
||||
$ODL_URI/restconf/config/genius-mdsalutil:config
|
||||
-d "{ "upgradeInProgress": false }"
|
||||
params:
|
||||
$ODL_USERNAME: {get_attr: [OpenDaylightBase, role_data, config_settings, 'opendaylight::username']}
|
||||
$ODL_PASSWORD: {get_attr: [OpenDaylightBase, role_data, config_settings, 'opendaylight::password']}
|
||||
$ODL_USERNAME: {get_param: OpenDaylightUsername}
|
||||
$ODL_PASSWORD: {get_param: OpenDaylightPassword}
|
||||
$ODL_URI: {get_param: [EndpointMap, OpenDaylightInternal, uri]}
|
||||
when: step|int == 0
|
||||
run_once: true
|
@ -5,7 +5,7 @@ resource_registry:
|
||||
OS::TripleO::Services::ComputeNeutronCorePlugin: OS::Heat::None
|
||||
OS::TripleO::Services::OVNDBs: OS::Heat::None
|
||||
OS::TripleO::Services::OVNController: OS::Heat::None
|
||||
OS::TripleO::Services::OpenDaylightApi: ../../puppet/services/opendaylight-api.yaml
|
||||
OS::TripleO::Services::OpenDaylightApi: ../../deployment/deprecated/opendaylight/opendaylight-api-container-puppet.yaml
|
||||
OS::TripleO::Services::OpenDaylightOvs: ../../puppet/services/opendaylight-ovs.yaml
|
||||
OS::TripleO::Services::NeutronL3Agent: OS::Heat::None
|
||||
OS::TripleO::Docker::NeutronMl2PluginBase: ../../puppet/services/neutron-plugin-ml2-odl.yaml
|
||||
|
@ -5,7 +5,7 @@ resource_registry:
|
||||
OS::TripleO::Services::ComputeNeutronCorePlugin: OS::Heat::None
|
||||
OS::TripleO::Services::OVNDBs: OS::Heat::None
|
||||
OS::TripleO::Services::OVNController: OS::Heat::None
|
||||
OS::TripleO::Services::OpenDaylightApi: ../../docker/services/opendaylight-api.yaml
|
||||
OS::TripleO::Services::OpenDaylightApi: ../../deployment/deprecated/opendaylight/opendaylight-api-container-puppet.yaml
|
||||
# FIXME(bogdando): switch it, once it is containerized
|
||||
OS::TripleO::Services::OpenDaylightOvs: ../../puppet/services/opendaylight-ovs.yaml
|
||||
OS::TripleO::Services::NeutronL3Agent: OS::Heat::None
|
||||
|
@ -352,7 +352,7 @@ resource_registry:
|
||||
OS::TripleO::Services::Logging::NovaCommon: docker/services/logging/files/nova-common.yaml
|
||||
OS::TripleO::Services::Logging::NovaLibvirt: OS::Heat::None
|
||||
OS::TripleO::Services::Logging::NovaPlacement: docker/services/logging/files/nova-placement.yaml
|
||||
OS::TripleO::Services::Logging::OpenDaylightApi: docker/services/logging/files/opendaylight-api.yaml
|
||||
OS::TripleO::Services::Logging::OpenDaylightApi: deployment/deprecated/opendaylight/opendaylight-api-container-puppet.yaml
|
||||
OS::TripleO::Services::Logging::PankoApi: docker/services/logging/files/panko-api.yaml
|
||||
|
||||
# Tempest
|
||||
|
@ -1,168 +0,0 @@
|
||||
heat_template_version: rocky
|
||||
|
||||
description: >
|
||||
OpenDaylight SDN Controller.
|
||||
|
||||
parameters:
|
||||
OpenDaylightUsername:
|
||||
default: 'admin'
|
||||
description: The username for the opendaylight server.
|
||||
type: string
|
||||
OpenDaylightPassword:
|
||||
type: string
|
||||
description: The password for the opendaylight server.
|
||||
hidden: true
|
||||
OpenDaylightFeatures:
|
||||
description: List of features to install with ODL
|
||||
type: comma_delimited_list
|
||||
default: ["odl-netvirt-openstack","odl-jolokia"]
|
||||
EndpointMap:
|
||||
default: {}
|
||||
description: Mapping of service endpoint -> protocol. Typically set
|
||||
via parameter_defaults in the resource registry.
|
||||
type: json
|
||||
ServiceData:
|
||||
default: {}
|
||||
description: Dictionary packing service data
|
||||
type: json
|
||||
ServiceNetMap:
|
||||
default: {}
|
||||
description: Mapping of service_name -> network name. Typically set
|
||||
via parameter_defaults in the resource registry. This
|
||||
mapping overrides those in ServiceNetMapDefaults.
|
||||
type: json
|
||||
DefaultPasswords:
|
||||
default: {}
|
||||
type: json
|
||||
RoleName:
|
||||
default: ''
|
||||
description: Role name on which the service is applied
|
||||
type: string
|
||||
RoleParameters:
|
||||
default: {}
|
||||
description: Parameters specific to the role
|
||||
type: json
|
||||
OpenDaylightManageRepositories:
|
||||
description: Whether to manage the OpenDaylight repository
|
||||
type: boolean
|
||||
default: false
|
||||
OpenDaylightSNATMechanism:
|
||||
description: SNAT mechanism to be used
|
||||
default: 'conntrack'
|
||||
type: string
|
||||
constraints:
|
||||
- allowed_values:
|
||||
- conntrack
|
||||
- controller
|
||||
OpenDaylightLogMechanism:
|
||||
description: Logging mechanism to be used
|
||||
default: 'file'
|
||||
type: string
|
||||
constraints:
|
||||
- allowed_values:
|
||||
- file
|
||||
- console
|
||||
OpenDaylightTLSKeystorePassword:
|
||||
default: 'opendaylight'
|
||||
type: string
|
||||
description: The password for the opendaylight TLS keystore.
|
||||
Must be at least 6 characters.
|
||||
hidden: true
|
||||
EnableInternalTLS:
|
||||
type: boolean
|
||||
default: false
|
||||
InternalTLSCAFile:
|
||||
default: '/etc/ipa/ca.crt'
|
||||
type: string
|
||||
description: Specifies the default CA cert to use if TLS is used for
|
||||
services in the internal network.
|
||||
OpenDaylightInheritDSCPMarking:
|
||||
description: Enable DSCP marking for VXLAN/GRE tunnels
|
||||
type: boolean
|
||||
default: false
|
||||
OpenDaylightJavaOpts:
|
||||
default: ''
|
||||
type: string
|
||||
description: Specifies the Java options to run ODL with as a string.
|
||||
Note, these options are in addition to the default Java
|
||||
options set by the karaf/ODL boot scripts and IP version
|
||||
based flag set by 'opendaylight' class.
|
||||
OpenDaylightInactivityProbe:
|
||||
description: Time in millseconds before an inactivity probe is sent via
|
||||
OVSDB to OVS
|
||||
type: number
|
||||
default: 180000
|
||||
|
||||
conditions:
|
||||
|
||||
internal_tls_enabled: {equals: [{get_param: EnableInternalTLS}, true]}
|
||||
|
||||
outputs:
|
||||
role_data:
|
||||
description: Role data for the OpenDaylight service.
|
||||
value:
|
||||
service_name: opendaylight_api
|
||||
config_settings:
|
||||
map_merge:
|
||||
-
|
||||
opendaylight::odl_rest_port: {get_param: [EndpointMap, OpenDaylightInternal, port]}
|
||||
opendaylight::username: {get_param: OpenDaylightUsername}
|
||||
opendaylight::password: {get_param: OpenDaylightPassword}
|
||||
opendaylight::extra_features: {get_param: OpenDaylightFeatures}
|
||||
opendaylight::odl_bind_ip:
|
||||
str_replace:
|
||||
template:
|
||||
"%{hiera('$NETWORK')}"
|
||||
params:
|
||||
$NETWORK: {get_param: [ServiceNetMap, OpendaylightApiNetwork]}
|
||||
opendaylight::manage_repositories: {get_param: OpenDaylightManageRepositories}
|
||||
tripleo::opendaylight_api::firewall_rules:
|
||||
'137 opendaylight api':
|
||||
dport:
|
||||
- {get_param: [EndpointMap, OpenDaylightInternal, port]}
|
||||
- 6640
|
||||
- 6653
|
||||
- 2550
|
||||
- 8185
|
||||
opendaylight::snat_mechanism: {get_param: OpenDaylightSNATMechanism}
|
||||
opendaylight::log_mechanism: {get_param: OpenDaylightLogMechanism}
|
||||
opendaylight::inherit_dscp_marking: {get_param: OpenDaylightInheritDSCPMarking}
|
||||
opendaylight::java_opts: {get_param: OpenDaylightJavaOpts}
|
||||
opendaylight::inactivity_probe: {get_param: OpenDaylightInactivityProbe}
|
||||
-
|
||||
if:
|
||||
- internal_tls_enabled
|
||||
- generate_service_certificates: true
|
||||
tripleo::profile::base::neutron::opendaylight::certificate_specs:
|
||||
service_certificate: '/etc/pki/tls/certs/odl.crt'
|
||||
service_key: '/etc/pki/tls/private/odl.key'
|
||||
hostname:
|
||||
str_replace:
|
||||
template: "%{hiera('fqdn_NETWORK')}"
|
||||
params:
|
||||
NETWORK: {get_param: [ServiceNetMap, OpendaylightApiNetwork]}
|
||||
principal:
|
||||
str_replace:
|
||||
template: "odl/%{hiera('fqdn_NETWORK')}"
|
||||
params:
|
||||
NETWORK: {get_param: [ServiceNetMap, OpendaylightApiNetwork]}
|
||||
opendaylight::tls_ca_cert_file: {get_param: InternalTLSCAFile}
|
||||
opendaylight::tls_keystore_password: {get_param: OpenDaylightTLSKeystorePassword}
|
||||
- {}
|
||||
service_config_settings:
|
||||
neutron_dhcp:
|
||||
if:
|
||||
- internal_tls_enabled
|
||||
- neutron::agents::dhcp::ovsdb_connection: 'ssl:127.0.0.1:6639'
|
||||
- neutron::agents::dhcp::ovsdb_connection: 'tcp:127.0.0.1:6639'
|
||||
step_config: |
|
||||
include tripleo::profile::base::neutron::opendaylight
|
||||
upgrade_tasks: []
|
||||
metadata_settings:
|
||||
if:
|
||||
- internal_tls_enabled
|
||||
-
|
||||
- service: odl
|
||||
network: {get_param: [ServiceNetMap, OpendaylightApiNetwork]}
|
||||
type: node
|
||||
- null
|
Loading…
Reference in New Issue
Block a user