Merge "Composable firewall rules"
[apex-tripleo-heat-templates.git] / puppet / services / neutron-server.yaml
1 heat_template_version: 2016-04-08
2
3 description: >
4   OpenStack Neutron Server configured with Puppet
5
6 parameters:
7   EndpointMap:
8     default: {}
9     description: Mapping of service endpoint -> protocol. Typically set
10                  via parameter_defaults in the resource registry.
11     type: json
12   NeutronWorkers:
13     default: 0
14     description: Number of workers for Neutron service.
15     type: number
16   NeutronPassword:
17     description: The password for the neutron service and db account, used by neutron agents.
18     type: string
19     hidden: true
20   NeutronAllowL3AgentFailover:
21     default: 'True'
22     description: Allow automatic l3-agent failover
23     type: string
24   NeutronL3HA:
25     default: false
26     description: Whether to enable HA for virtual routers
27     type: boolean
28   NovaPassword:
29     description: The password for the nova service and db account, used by nova-api.
30     type: string
31     hidden: true
32
33 resources:
34
35   NeutronBase:
36     type: ./neutron-base.yaml
37
38 outputs:
39   role_data:
40     description: Role data for the Neutron Server agent service.
41     value:
42       service_name: neutron-server
43       config_settings:
44         map_merge:
45           - get_attr: [NeutronBase, role_data, config_settings]
46             neutron::server::database_connection:
47               list_join:
48                 - ''
49                 - - {get_param: [EndpointMap, MysqlInternal, protocol]}
50                   - '://neutron:'
51                   - {get_param: NeutronPassword}
52                   - '@'
53                   - {get_param: [EndpointMap, MysqlInternal, host]}
54                   - '/ovs_neutron?charset=utf8'
55             neutron::server::auth_uri: {get_param: [EndpointMap, KeystoneInternal, uri] }
56             neutron::server::auth_url: {get_param: [EndpointMap, KeystoneAdmin, uri_no_suffix]}
57             neutron::server::identity_uri: { get_param: [EndpointMap, KeystoneAdmin, uri_no_suffix] }
58             neutron::server::api_workers: {get_param: NeutronWorkers}
59             neutron::server::allow_automatic_l3agent_failover: {get_param: NeutronAllowL3AgentFailover}
60             neutron::server::l3_ha: {get_param: NeutronL3HA}
61             neutron::server::auth_password: {get_param: NeutronPassword}
62
63             neutron::server::notifications::nova_url: { get_param: [ EndpointMap, NovaInternal, uri ] }
64             neutron::server::notifications::auth_url: { get_param: [ EndpointMap, KeystoneV3Admin, uri ] }
65             neutron::server::notifications::tenant_name: 'service'
66             neutron::server::notifications::project_name: 'service'
67             neutron::server::notifications::password: {get_param: NovaPassword}
68             neutron::db::mysql::password: {get_param: NeutronPassword}
69             neutron::db::mysql::user: neutron
70             neutron::db::mysql::host: {get_param: [EndpointMap, MysqlNoBracketsInternal, host]}
71             neutron::db::mysql::dbname: ovs_neutron
72             neutron::db::mysql::allowed_hosts:
73               - '%'
74               - "%{hiera('mysql_bind_host')}"
75             tripleo.neutron_server.firewall_rules:
76               '114 neutron server':
77                 dport:
78                   - 9696
79                   - 13696
80               '118 neutron vxlan networks':
81                 proto: 'udp'
82                 dport: 4789
83               '106 vrrp':
84                 proto: vrrp
85       step_config: |
86         include tripleo::profile::base::neutron::server