Change flat network name for nosdn fdio scenario
[apex-tripleo-heat-templates.git] / puppet / services / nova-migration-target.yaml
1 heat_template_version: ocata
2
3 description: >
4   OpenStack Nova migration target configured with Puppet
5
6 parameters:
7   ServiceData:
8     default: {}
9     description: Dictionary packing service data
10     type: json
11   ServiceNetMap:
12     default: {}
13     description: Mapping of service_name -> network name. Typically set
14                  via parameter_defaults in the resource registry.  This
15                  mapping overrides those in ServiceNetMapDefaults.
16     type: json
17   DefaultPasswords:
18     default: {}
19     type: json
20   RoleName:
21     default: ''
22     description: Role name on which the service is applied
23     type: string
24   RoleParameters:
25     default: {}
26     description: Parameters specific to the role
27     type: json
28   EndpointMap:
29     default: {}
30     description: Mapping of service endpoint -> protocol. Typically set
31                  via parameter_defaults in the resource registry.
32     type: json
33   MigrationSshKey:
34     type: json
35     description: >
36       SSH key for migration.
37       Expects a dictionary with keys 'public_key' and 'private_key'.
38       Values should be identical to SSH public/private key files.
39     default:
40       public_key: ''
41       private_key: ''
42   MigrationSshPort:
43     default: 2022
44     description: Target port for migration over ssh
45     type: number
46
47 outputs:
48   role_data:
49     description: Role data for the Nova migration target service.
50     value:
51       service_name: nova_migration_target
52       config_settings:
53         tripleo::profile::base::nova::migration::target::ssh_authorized_keys:
54           - {get_param: [ MigrationSshKey, public_key ]}
55         tripleo::profile::base::nova::migration::target::ssh_localaddrs:
56           - "%{hiera('cold_migration_ssh_inbound_addr')}"
57           - "%{hiera('live_migration_ssh_inbound_addr')}"
58         live_migration_ssh_inbound_addr:
59           get_param:
60             - ServiceNetMap
61             - str_replace:
62                 template: "ROLENAMEHostnameResolveNetwork"
63                 params:
64                   ROLENAME: {get_param: RoleName}
65         cold_migration_ssh_inbound_addr: {get_param: [ServiceNetMap, NovaApiNetwork]}
66         tripleo::profile::base::sshd::port:
67           - 22
68           - {get_param: MigrationSshPort}
69         tripleo.nova_migration_target.firewall_rules:
70           '113 nova_migration_target':
71             dport:
72               - {get_param: MigrationSshPort}
73       step_config: |
74         include tripleo::profile::base::nova::migration::target