diff options
44 files changed, 1118 insertions, 826 deletions
diff --git a/environments/docker.yaml b/environments/docker.yaml index be21d842..a7e2504c 100644 --- a/environments/docker.yaml +++ b/environments/docker.yaml @@ -3,7 +3,7 @@ resource_registry: OS::TripleO::ComputePostDeployment: ../docker/compute-post.yaml OS::TripleO::NodeUserData: ../docker/firstboot/install_docker_agents.yaml -parameters: +parameter_defaults: NovaImage: atomic-image parameter_defaults: diff --git a/environments/enable-tls.yaml b/environments/enable-tls.yaml index 70181278..e708688f 100644 --- a/environments/enable-tls.yaml +++ b/environments/enable-tls.yaml @@ -17,6 +17,10 @@ parameter_defaults: GlanceAdmin: {protocol: 'http', port: '9292', host: 'IP_ADDRESS'} GlanceInternal: {protocol: 'http', port: '9292', host: 'IP_ADDRESS'} GlancePublic: {protocol: 'https', port: '13292', host: 'CLOUDNAME'} + GlanceRegistryInternal: {protocol: 'http', port: '9191', host: 'IP_ADDRESS'} + GnocchiAdmin: {protocol: 'http', port: '8041', host: 'IP_ADDRESS'} + GnocchiInternal: {protocol: 'http', port: '8041', host: 'IP_ADDRESS'} + GnocchiPublic: {protocol: 'https', port: '13041', host: 'CLOUDNAME'} HeatAdmin: {protocol: 'http', port: '8004', host: 'IP_ADDRESS'} HeatInternal: {protocol: 'http', port: '8004', host: 'IP_ADDRESS'} HeatPublic: {protocol: 'https', port: '13004', host: 'CLOUDNAME'} @@ -24,9 +28,6 @@ parameter_defaults: KeystoneAdmin: {protocol: 'http', port: '35357', host: 'IP_ADDRESS'} KeystoneInternal: {protocol: 'http', port: '5000', host: 'IP_ADDRESS'} KeystonePublic: {protocol: 'https', port: '13000', host: 'CLOUDNAME'} - KeystoneV3Admin: {protocol: 'http', port: '35357', host: 'IP_ADDRESS'} - KeystoneV3Internal: {protocol: 'http', port: '5000', host: 'IP_ADDRESS'} - KeystoneV3Public: {protocol: 'https', port: '13000', host: 'CLOUDNAME'} NeutronAdmin: {protocol: 'http', port: '9696', host: 'IP_ADDRESS'} NeutronInternal: {protocol: 'http', port: '9696', host: 'IP_ADDRESS'} NeutronPublic: {protocol: 'https', port: '13696', host: 'CLOUDNAME'} @@ -41,7 +42,7 @@ parameter_defaults: NovaVNCProxyPublic: {protocol: 'https', port: '13080', host: 'CLOUDNAME'} SaharaAdmin: {protocol: 'http', port: '8386', host: 'IP_ADDRESS'} SaharaInternal: {protocol: 'http', port: '8386', host: 'IP_ADDRESS'} - SaharaPublic: {protocol: 'https', port: '13786', host: 'CLOUDNAME'} + SaharaPublic: {protocol: 'https', port: '13386', host: 'CLOUDNAME'} SwiftAdmin: {protocol: 'http', port: '8080', host: 'IP_ADDRESS'} SwiftInternal: {protocol: 'http', port: '8080', host: 'IP_ADDRESS'} SwiftPublic: {protocol: 'https', port: '13808', host: 'CLOUDNAME'} diff --git a/environments/manage-firewall.yaml b/environments/manage-firewall.yaml index 071f4108..5d48698e 100644 --- a/environments/manage-firewall.yaml +++ b/environments/manage-firewall.yaml @@ -1,2 +1,2 @@ -parameters: +parameter_defaults: ManageFirewall: true diff --git a/environments/mongodb-nojournal.yaml b/environments/mongodb-nojournal.yaml index 1e13e452..92cef532 100644 --- a/environments/mongodb-nojournal.yaml +++ b/environments/mongodb-nojournal.yaml @@ -1,5 +1,5 @@ # A Heat environment file which can be used to disable journal in MongoDb. # Since, when journaling is enabled, MongoDb will create big journal file # it can take time. In a CI environment for example journaling is not necessary. -parameters: +parameter_defaults: MongoDbNoJournal: true diff --git a/environments/net-bond-with-vlans-no-external.yaml b/environments/net-bond-with-vlans-no-external.yaml index 0da119d9..75959a0b 100644 --- a/environments/net-bond-with-vlans-no-external.yaml +++ b/environments/net-bond-with-vlans-no-external.yaml @@ -12,7 +12,7 @@ resource_registry: # Set external ports to noop - OS::TripleO::Network::External: ../network/noop.yaml + OS::TripleO::Network::External: OS::Heat::None OS::TripleO::Controller::Ports::ExternalPort: ../network/ports/noop.yaml OS::TripleO::BlockStorage::Net::SoftwareConfig: ../network/config/bond-with-vlans/cinder-storage.yaml diff --git a/environments/net-single-nic-with-vlans-no-external.yaml b/environments/net-single-nic-with-vlans-no-external.yaml index a173df4e..c7594b32 100644 --- a/environments/net-single-nic-with-vlans-no-external.yaml +++ b/environments/net-single-nic-with-vlans-no-external.yaml @@ -10,7 +10,7 @@ resource_registry: # Set external ports to noop - OS::TripleO::Network::External: ../network/noop.yaml + OS::TripleO::Network::External: OS::Heat::None OS::TripleO::Controller::Ports::ExternalPort: ../network/ports/noop.yaml # Configure other ports as normal diff --git a/environments/network-isolation.yaml b/environments/network-isolation.yaml index 87fc22f5..c0420c5c 100644 --- a/environments/network-isolation.yaml +++ b/environments/network-isolation.yaml @@ -10,7 +10,7 @@ resource_registry: OS::TripleO::Network::Storage: ../network/storage.yaml OS::TripleO::Network::Tenant: ../network/tenant.yaml # Management network is optional and disabled by default - OS::TripleO::Network::Management: ../network/noop.yaml + OS::TripleO::Network::Management: OS::Heat::None # Port assignments for the VIPs OS::TripleO::Network::Ports::ExternalVipPort: ../network/ports/external.yaml diff --git a/environments/puppet-ceph-devel.yaml b/environments/puppet-ceph-devel.yaml index fc4b8c7d..a2d1100f 100644 --- a/environments/puppet-ceph-devel.yaml +++ b/environments/puppet-ceph-devel.yaml @@ -1,7 +1,7 @@ # A Heat environment file which can be used to enable a Ceph # storage cluster using the controller and ceph nodes. -# Rbd backends are enabled for Cinder, Glance, and Nova. -parameters: +# Rbd backends are enabled for Cinder, Glance, Gnocchi and Nova. +parameter_defaults: #NOTE: These ID's and keys should be regenerated for # a production deployment. What is here is suitable for # developer and CI testing only. @@ -11,5 +11,6 @@ parameters: NovaEnableRbdBackend: true CinderEnableRbdBackend: true GlanceBackend: rbd + GnocchiBackend: rbd CinderEnableIscsiBackend: false ControllerEnableCephStorage: true diff --git a/environments/puppet-ceph-external.yaml b/environments/puppet-ceph-external.yaml index 7f5b5080..865e0b98 100644 --- a/environments/puppet-ceph-external.yaml +++ b/environments/puppet-ceph-external.yaml @@ -9,16 +9,18 @@ parameter_defaults: #CephClientKey: 'AQDLOh1VgEp6FRAAFzT7Zw+Y9V6JJExQAsRnRQ==' #CephExternalMonHost: '172.16.1.7, 172.16.1.8' - # the following parameters enable Ceph backends for Cinder, Glance, and Nova + # the following parameters enable Ceph backends for Cinder, Glance, Gnocchi and Nova NovaEnableRbdBackend: true CinderEnableRbdBackend: true GlanceBackend: rbd + GnocchiBackend: rbd # If the Ceph pools which host VMs, Volumes and Images do not match these # names OR the client keyring to use is not named 'openstack', edit the # following as needed. NovaRbdPoolName: vms CinderRbdPoolName: volumes GlanceRbdPoolName: images + GnocchiRbdPoolName: metrics CephClientUserName: openstack # finally we disable the Cinder LVM backend diff --git a/environments/puppet-pacemaker.yaml b/environments/puppet-pacemaker.yaml index 8986e35f..2e6e5ec9 100644 --- a/environments/puppet-pacemaker.yaml +++ b/environments/puppet-pacemaker.yaml @@ -4,3 +4,11 @@ resource_registry: OS::TripleO::ControllerConfig: ../puppet/controller-config-pacemaker.yaml OS::TripleO::Tasks::ControllerPrePuppet: ../extraconfig/tasks/pre_puppet_pacemaker.yaml OS::TripleO::Tasks::ControllerPostPuppet: ../extraconfig/tasks/post_puppet_pacemaker.yaml + + # custom pacemaker services + # NOTE: For now we will need to specify overrides to all services + # which use pacemaker. In the future (with upcoming HA light work) this + # list will hopefully be much smaller however. + OS::TripleO::Services::Keystone: ../puppet/services/pacemaker/keystone.yaml + OS::TripleO::Services::GlanceApi: ../puppet/services/pacemaker/glance-api.yaml + OS::TripleO::Services::GlanceRegistry: ../puppet/services/pacemaker/glance-registry.yaml diff --git a/environments/puppet-tenant-vlan.yaml b/environments/puppet-tenant-vlan.yaml index 0df63caf..ed948bc5 100644 --- a/environments/puppet-tenant-vlan.yaml +++ b/environments/puppet-tenant-vlan.yaml @@ -1,4 +1,4 @@ -parameters: +parameter_defaults: NeutronNetworkType: vlan NeutronEnableTunnelling: false - NeutronNetworkVLANRanges: datacentre:1:1000
\ No newline at end of file + NeutronNetworkVLANRanges: datacentre:1:1000 diff --git a/environments/storage-environment.yaml b/environments/storage-environment.yaml index bd320bd9..e1cafd2b 100644 --- a/environments/storage-environment.yaml +++ b/environments/storage-environment.yaml @@ -15,6 +15,8 @@ parameter_defaults: NovaEnableRbdBackend: true ## Glance backend can be either 'rbd' (Ceph), 'swift' or 'file'. GlanceBackend: rbd + ## Gnocchi backend can be either 'rbd' (Ceph), 'swift' or 'file'. + GnocchiBackend: rbd #### CINDER NFS SETTINGS #### diff --git a/environments/updates/update-from-keystone-admin-internal-api.yaml b/environments/updates/update-from-keystone-admin-internal-api.yaml index 3c71ef1b..a9fa2bea 100644 --- a/environments/updates/update-from-keystone-admin-internal-api.yaml +++ b/environments/updates/update-from-keystone-admin-internal-api.yaml @@ -1,7 +1,7 @@ # This environment file provides a default value for ServiceNetMap where # Keystone Admin API service is running on the Internal API network -parameters: +parameter_defaults: ServiceNetMap: NeutronTenantNetwork: tenant CeilometerApiNetwork: internal_api diff --git a/extraconfig/tasks/major_upgrade_pacemaker_migrations.sh b/extraconfig/tasks/major_upgrade_pacemaker_migrations.sh index 1f420b32..b63198db 100644 --- a/extraconfig/tasks/major_upgrade_pacemaker_migrations.sh +++ b/extraconfig/tasks/major_upgrade_pacemaker_migrations.sh @@ -13,6 +13,42 @@ # been already applied, it should be possible to call the function # again without damaging the deployment or failing the upgrade. +function add_missing_openstack_core_constraints { + # The CIBs are saved under /root as they might contain sensitive data + CIB="/root/migration.cib" + CIB_BACKUP="/root/backup.cib" + CIB_PUSH_NEEDED=n + + rm -f "$CIB" "$CIB_BACKUP" || /bin/true + pcs cluster cib "$CIB" + cp "$CIB" "$CIB_BACKUP" + + if ! pcs -f "$CIB" constraint --full | grep 'start openstack-sahara-api-clone then start openstack-sahara-engine-clone'; then + pcs -f "$CIB" constraint order start openstack-sahara-api-clone then start openstack-sahara-engine-clone + CIB_PUSH_NEEDED=y + fi + + if ! pcs -f "$CIB" constraint --full | grep 'start openstack-core-clone then start openstack-ceilometer-notification-clone'; then + pcs -f "$CIB" constraint order start openstack-core-clone then start openstack-ceilometer-notification-clone + CIB_PUSH_NEEDED=y + fi + + if ! pcs -f "$CIB" constraint --full | grep 'start openstack-aodh-evaluator-clone then start openstack-aodh-listener-clone'; then + pcs -f "$CIB" constraint order start openstack-aodh-evaluator-clone then start openstack-aodh-listener-clone + CIB_PUSH_NEEDED=y + fi + + if pcs -f "$CIB" constraint --full | grep 'start openstack-core-clone then start openstack-heat-api-clone'; then + CID=$(pcs -f "$CIB" constraint --full | grep 'start openstack-core-clone then start openstack-heat-api-clone' | sed -e 's/.*id\://g' -e 's/)//g') + pcs -f "$CIB" constraint remove $CID + CIB_PUSH_NEEDED=y + fi + + if [ "$CIB_PUSH_NEEDED" = 'y' ]; then + pcs cluster cib-push "$CIB" + fi +} + function remove_ceilometer_alarm { if pcs status | grep openstack-ceilometer-alarm; then # Disable pacemaker resources for ceilometer-alarms diff --git a/extraconfig/tasks/noop.yaml b/extraconfig/tasks/noop.yaml deleted file mode 100644 index dbb863be..00000000 --- a/extraconfig/tasks/noop.yaml +++ /dev/null @@ -1,26 +0,0 @@ -heat_template_version: 2014-10-16 -description: 'No-op task' - -parameters: - servers: - type: json - default: [] - controller_servers: - type: json - default: [] - compute_servers: - type: json - default: [] - blockstorage_servers: - type: json - default: [] - objectstorage_servers: - type: json - default: [] - cephstorage_servers: - type: json - default: [] - input_values: - type: json - default: {} - description: input values for the software deployments diff --git a/extraconfig/tasks/yum_update.sh b/extraconfig/tasks/yum_update.sh index 4a8aa431..b045e5ea 100755 --- a/extraconfig/tasks/yum_update.sh +++ b/extraconfig/tasks/yum_update.sh @@ -23,7 +23,7 @@ update_identifier=${update_identifier//[^a-zA-Z0-9-_]/} # seconds to wait for this node to rejoin the cluster after update cluster_start_timeout=600 -galera_sync_timeout=360 +galera_sync_timeout=1800 cluster_settle_timeout=1800 timestamp_file="$timestamp_dir/$update_identifier" diff --git a/network/config/bond-with-vlans/controller-no-external.yaml b/network/config/bond-with-vlans/controller-no-external.yaml index 375d40be..d9532439 100644 --- a/network/config/bond-with-vlans/controller-no-external.yaml +++ b/network/config/bond-with-vlans/controller-no-external.yaml @@ -5,6 +5,10 @@ description: > with VLANs attached for the controller role. parameters: + ControlPlaneIp: + default: '' + description: IP address/subnet on the ctlplane network + type: string ExternalIpSubnet: default: '' description: IP address/subnet on the external network @@ -62,6 +66,18 @@ parameters: default: '10.0.0.1' description: default route for the external network type: string + ControlPlaneSubnetCidr: # Override this via parameter_defaults + default: '24' + description: The subnet CIDR of the control plane network. + type: string + DnsServers: # Override this via parameter_defaults + default: [] + description: A list of DNS servers (2 max for some implementations) that will be added to resolv.conf. + type: comma_delimited_list + EC2MetadataIp: # Override this via parameter_defaults + description: The IP address of the EC2 metadata server. + type: string + resources: OsNetConfigImpl: @@ -72,6 +88,21 @@ resources: os_net_config: network_config: - + type: interface + name: nic1 + use_dhcp: false + addresses: + - + ip_netmask: + list_join: + - '/' + - - {get_param: ControlPlaneIp} + - {get_param: ControlPlaneSubnetCidr} + routes: + - + ip_netmask: 169.254.169.254/32 + next_hop: {get_param: EC2MetadataIp} + - type: ovs_bridge name: {get_input: bridge_name} use_dhcp: true diff --git a/network/endpoints/endpoint_data.yaml b/network/endpoints/endpoint_data.yaml index edcfaca1..bd4e2281 100644 --- a/network/endpoints/endpoint_data.yaml +++ b/network/endpoints/endpoint_data.yaml @@ -19,6 +19,15 @@ Ceilometer: vip_param: CeilometerApi port: 8777 +Gnocchi: + Internal: + vip_param: GnocchiApi + Public: + vip_param: Public + Admin: + vip_param: GnocchiApi + port: 8041 + Cinder: Internal: vip_param: CinderApi @@ -46,6 +55,11 @@ Glance: vip_param: GlanceApi port: 9292 +GlanceRegistry: + Internal: + vip_param: GlanceRegistry + port: 9191 + Mysql: '': vip_param: Mysql @@ -72,40 +86,27 @@ Horizon: '': /dashboard port: 80 +# TODO(ayoung): V3 is a temporary fix. Endpoints should be versionless. +# Required for https://bugs.launchpad.net/puppet-nova/+bug/1542486 Keystone: Internal: vip_param: KeystonePublicApi uri_suffixes: '': /v2.0 EC2: /v2.0/ec2tokens + V3: /v3 names: EC2: KeystoneEC2 Public: vip_param: Public uri_suffixes: '': /v2.0 + V3: /v3 Admin: vip_param: KeystoneAdminApi uri_suffixes: '': /v2.0 - port: 35357 - port: 5000 - -# TODO(ayoung): V3 is a temporary fix. Endpoints should be versionless. -# Required for https://bugs.launchpad.net/puppet-nova/+bug/1542486 -KeystoneV3: - Internal: - vip_param: KeystonePublicApi - uri_suffixes: - '': /v3 - Public: - vip_param: Public - uri_suffixes: - '': /v3 - Admin: - vip_param: KeystoneAdminApi - uri_suffixes: - '': /v3 + V3: /v3 port: 35357 port: 5000 diff --git a/network/endpoints/endpoint_map.yaml b/network/endpoints/endpoint_map.yaml index 07266f98..f9a8b83c 100644 --- a/network/endpoints/endpoint_map.yaml +++ b/network/endpoints/endpoint_map.yaml @@ -12,6 +12,8 @@ parameters: CeilometerApiVirtualIP: {type: string, default: ''} CinderApiVirtualIP: {type: string, default: ''} GlanceApiVirtualIP: {type: string, default: ''} + GlanceRegistryVirtualIP: {type: string, default: ''} + GnocchiApiVirtualIP: {type: string, default: ''} HeatApiVirtualIP: {type: string, default: ''} KeystoneAdminApiVirtualIP: {type: string, default: ''} KeystonePublicApiVirtualIP: {type: string, default: ''} @@ -36,6 +38,10 @@ parameters: GlanceAdmin: {protocol: http, port: '9292', host: IP_ADDRESS} GlanceInternal: {protocol: http, port: '9292', host: IP_ADDRESS} GlancePublic: {protocol: http, port: '9292', host: IP_ADDRESS} + GlanceRegistryInternal: {protocol: http, port: '9191', host: IP_ADDRESS} + GnocchiAdmin: {protocol: http, port: '8041', host: IP_ADDRESS} + GnocchiInternal: {protocol: http, port: '8041', host: IP_ADDRESS} + GnocchiPublic: {protocol: http, port: '8041', host: IP_ADDRESS} HeatAdmin: {protocol: http, port: '8004', host: IP_ADDRESS} HeatInternal: {protocol: http, port: '8004', host: IP_ADDRESS} HeatPublic: {protocol: http, port: '8004', host: IP_ADDRESS} @@ -43,9 +49,6 @@ parameters: KeystoneAdmin: {protocol: http, port: '35357', host: IP_ADDRESS} KeystoneInternal: {protocol: http, port: '5000', host: IP_ADDRESS} KeystonePublic: {protocol: http, port: '5000', host: IP_ADDRESS} - KeystoneV3Admin: {protocol: http, port: '35357', host: IP_ADDRESS} - KeystoneV3Internal: {protocol: http, port: '5000', host: IP_ADDRESS} - KeystoneV3Public: {protocol: http, port: '5000', host: IP_ADDRESS} NeutronAdmin: {protocol: http, port: '9696', host: IP_ADDRESS} NeutronInternal: {protocol: http, port: '9696', host: IP_ADDRESS} NeutronPublic: {protocol: http, port: '9696', host: IP_ADDRESS} @@ -647,6 +650,158 @@ outputs: IP_ADDRESS: {get_param: PublicVirtualIP} - ':' - get_param: [EndpointMap, GlancePublic, port] + GlanceRegistryInternal: + host: + str_replace: + template: + get_param: [EndpointMap, GlanceRegistryInternal, host] + params: + CLOUDNAME: {get_param: CloudName} + IP_ADDRESS: {get_param: GlanceRegistryVirtualIP} + port: + get_param: [EndpointMap, GlanceRegistryInternal, port] + protocol: + get_param: [EndpointMap, GlanceRegistryInternal, protocol] + uri: + list_join: + - '' + - - get_param: [EndpointMap, GlanceRegistryInternal, protocol] + - :// + - str_replace: + template: + get_param: [EndpointMap, GlanceRegistryInternal, host] + params: + CLOUDNAME: {get_param: CloudName} + IP_ADDRESS: {get_param: GlanceRegistryVirtualIP} + - ':' + - get_param: [EndpointMap, GlanceRegistryInternal, port] + uri_no_suffix: + list_join: + - '' + - - get_param: [EndpointMap, GlanceRegistryInternal, protocol] + - :// + - str_replace: + template: + get_param: [EndpointMap, GlanceRegistryInternal, host] + params: + CLOUDNAME: {get_param: CloudName} + IP_ADDRESS: {get_param: GlanceRegistryVirtualIP} + - ':' + - get_param: [EndpointMap, GlanceRegistryInternal, port] + GnocchiAdmin: + host: + str_replace: + template: + get_param: [EndpointMap, GnocchiAdmin, host] + params: + CLOUDNAME: {get_param: CloudName} + IP_ADDRESS: {get_param: GnocchiApiVirtualIP} + port: + get_param: [EndpointMap, GnocchiAdmin, port] + protocol: + get_param: [EndpointMap, GnocchiAdmin, protocol] + uri: + list_join: + - '' + - - get_param: [EndpointMap, GnocchiAdmin, protocol] + - :// + - str_replace: + template: + get_param: [EndpointMap, GnocchiAdmin, host] + params: + CLOUDNAME: {get_param: CloudName} + IP_ADDRESS: {get_param: GnocchiApiVirtualIP} + - ':' + - get_param: [EndpointMap, GnocchiAdmin, port] + uri_no_suffix: + list_join: + - '' + - - get_param: [EndpointMap, GnocchiAdmin, protocol] + - :// + - str_replace: + template: + get_param: [EndpointMap, GnocchiAdmin, host] + params: + CLOUDNAME: {get_param: CloudName} + IP_ADDRESS: {get_param: GnocchiApiVirtualIP} + - ':' + - get_param: [EndpointMap, GnocchiAdmin, port] + GnocchiInternal: + host: + str_replace: + template: + get_param: [EndpointMap, GnocchiInternal, host] + params: + CLOUDNAME: {get_param: CloudName} + IP_ADDRESS: {get_param: GnocchiApiVirtualIP} + port: + get_param: [EndpointMap, GnocchiInternal, port] + protocol: + get_param: [EndpointMap, GnocchiInternal, protocol] + uri: + list_join: + - '' + - - get_param: [EndpointMap, GnocchiInternal, protocol] + - :// + - str_replace: + template: + get_param: [EndpointMap, GnocchiInternal, host] + params: + CLOUDNAME: {get_param: CloudName} + IP_ADDRESS: {get_param: GnocchiApiVirtualIP} + - ':' + - get_param: [EndpointMap, GnocchiInternal, port] + uri_no_suffix: + list_join: + - '' + - - get_param: [EndpointMap, GnocchiInternal, protocol] + - :// + - str_replace: + template: + get_param: [EndpointMap, GnocchiInternal, host] + params: + CLOUDNAME: {get_param: CloudName} + IP_ADDRESS: {get_param: GnocchiApiVirtualIP} + - ':' + - get_param: [EndpointMap, GnocchiInternal, port] + GnocchiPublic: + host: + str_replace: + template: + get_param: [EndpointMap, GnocchiPublic, host] + params: + CLOUDNAME: {get_param: CloudName} + IP_ADDRESS: {get_param: PublicVirtualIP} + port: + get_param: [EndpointMap, GnocchiPublic, port] + protocol: + get_param: [EndpointMap, GnocchiPublic, protocol] + uri: + list_join: + - '' + - - get_param: [EndpointMap, GnocchiPublic, protocol] + - :// + - str_replace: + template: + get_param: [EndpointMap, GnocchiPublic, host] + params: + CLOUDNAME: {get_param: CloudName} + IP_ADDRESS: {get_param: PublicVirtualIP} + - ':' + - get_param: [EndpointMap, GnocchiPublic, port] + uri_no_suffix: + list_join: + - '' + - - get_param: [EndpointMap, GnocchiPublic, protocol] + - :// + - str_replace: + template: + get_param: [EndpointMap, GnocchiPublic, host] + params: + CLOUDNAME: {get_param: CloudName} + IP_ADDRESS: {get_param: PublicVirtualIP} + - ':' + - get_param: [EndpointMap, GnocchiPublic, port] HeatAdmin: host: str_replace: @@ -963,119 +1118,119 @@ outputs: host: str_replace: template: - get_param: [EndpointMap, KeystoneV3Admin, host] + get_param: [EndpointMap, KeystoneAdmin, host] params: CLOUDNAME: {get_param: CloudName} IP_ADDRESS: {get_param: KeystoneAdminApiVirtualIP} port: - get_param: [EndpointMap, KeystoneV3Admin, port] + get_param: [EndpointMap, KeystoneAdmin, port] protocol: - get_param: [EndpointMap, KeystoneV3Admin, protocol] + get_param: [EndpointMap, KeystoneAdmin, protocol] uri: list_join: - '' - - - get_param: [EndpointMap, KeystoneV3Admin, protocol] + - - get_param: [EndpointMap, KeystoneAdmin, protocol] - :// - str_replace: template: - get_param: [EndpointMap, KeystoneV3Admin, host] + get_param: [EndpointMap, KeystoneAdmin, host] params: CLOUDNAME: {get_param: CloudName} IP_ADDRESS: {get_param: KeystoneAdminApiVirtualIP} - ':' - - get_param: [EndpointMap, KeystoneV3Admin, port] + - get_param: [EndpointMap, KeystoneAdmin, port] - /v3 uri_no_suffix: list_join: - '' - - - get_param: [EndpointMap, KeystoneV3Admin, protocol] + - - get_param: [EndpointMap, KeystoneAdmin, protocol] - :// - str_replace: template: - get_param: [EndpointMap, KeystoneV3Admin, host] + get_param: [EndpointMap, KeystoneAdmin, host] params: CLOUDNAME: {get_param: CloudName} IP_ADDRESS: {get_param: KeystoneAdminApiVirtualIP} - ':' - - get_param: [EndpointMap, KeystoneV3Admin, port] + - get_param: [EndpointMap, KeystoneAdmin, port] KeystoneV3Internal: host: str_replace: template: - get_param: [EndpointMap, KeystoneV3Internal, host] + get_param: [EndpointMap, KeystoneInternal, host] params: CLOUDNAME: {get_param: CloudName} IP_ADDRESS: {get_param: KeystonePublicApiVirtualIP} port: - get_param: [EndpointMap, KeystoneV3Internal, port] + get_param: [EndpointMap, KeystoneInternal, port] protocol: - get_param: [EndpointMap, KeystoneV3Internal, protocol] + get_param: [EndpointMap, KeystoneInternal, protocol] uri: list_join: - '' - - - get_param: [EndpointMap, KeystoneV3Internal, protocol] + - - get_param: [EndpointMap, KeystoneInternal, protocol] - :// - str_replace: template: - get_param: [EndpointMap, KeystoneV3Internal, host] + get_param: [EndpointMap, KeystoneInternal, host] params: CLOUDNAME: {get_param: CloudName} IP_ADDRESS: {get_param: KeystonePublicApiVirtualIP} - ':' - - get_param: [EndpointMap, KeystoneV3Internal, port] + - get_param: [EndpointMap, KeystoneInternal, port] - /v3 uri_no_suffix: list_join: - '' - - - get_param: [EndpointMap, KeystoneV3Internal, protocol] + - - get_param: [EndpointMap, KeystoneInternal, protocol] - :// - str_replace: template: - get_param: [EndpointMap, KeystoneV3Internal, host] + get_param: [EndpointMap, KeystoneInternal, host] params: CLOUDNAME: {get_param: CloudName} IP_ADDRESS: {get_param: KeystonePublicApiVirtualIP} - ':' - - get_param: [EndpointMap, KeystoneV3Internal, port] + - get_param: [EndpointMap, KeystoneInternal, port] KeystoneV3Public: host: str_replace: template: - get_param: [EndpointMap, KeystoneV3Public, host] + get_param: [EndpointMap, KeystonePublic, host] params: CLOUDNAME: {get_param: CloudName} IP_ADDRESS: {get_param: PublicVirtualIP} port: - get_param: [EndpointMap, KeystoneV3Public, port] + get_param: [EndpointMap, KeystonePublic, port] protocol: - get_param: [EndpointMap, KeystoneV3Public, protocol] + get_param: [EndpointMap, KeystonePublic, protocol] uri: list_join: - '' - - - get_param: [EndpointMap, KeystoneV3Public, protocol] + - - get_param: [EndpointMap, KeystonePublic, protocol] - :// - str_replace: template: - get_param: [EndpointMap, KeystoneV3Public, host] + get_param: [EndpointMap, KeystonePublic, host] params: CLOUDNAME: {get_param: CloudName} IP_ADDRESS: {get_param: PublicVirtualIP} - ':' - - get_param: [EndpointMap, KeystoneV3Public, port] + - get_param: [EndpointMap, KeystonePublic, port] - /v3 uri_no_suffix: list_join: - '' - - - get_param: [EndpointMap, KeystoneV3Public, protocol] + - - get_param: [EndpointMap, KeystonePublic, protocol] - :// - str_replace: template: - get_param: [EndpointMap, KeystoneV3Public, host] + get_param: [EndpointMap, KeystonePublic, host] params: CLOUDNAME: {get_param: CloudName} IP_ADDRESS: {get_param: PublicVirtualIP} - ':' - - get_param: [EndpointMap, KeystoneV3Public, port] + - get_param: [EndpointMap, KeystonePublic, port] NeutronAdmin: host: str_replace: diff --git a/network/noop.yaml b/network/noop.yaml deleted file mode 100644 index 0963d2ce..00000000 --- a/network/noop.yaml +++ /dev/null @@ -1,3 +0,0 @@ -heat_template_version: 2015-04-30 - -description: A stack which creates no network(s). diff --git a/overcloud-resource-registry-puppet.yaml b/overcloud-resource-registry-puppet.yaml index bc3b7241..4f79e516 100644 --- a/overcloud-resource-registry-puppet.yaml +++ b/overcloud-resource-registry-puppet.yaml @@ -23,10 +23,10 @@ resource_registry: OS::TripleO::BootstrapNode::SoftwareConfig: puppet/bootstrap-config.yaml # Tasks (for internal TripleO usage) - OS::TripleO::Tasks::UpdateWorkflow: extraconfig/tasks/noop.yaml + OS::TripleO::Tasks::UpdateWorkflow: OS::Heat::None OS::TripleO::Tasks::PackageUpdate: extraconfig/tasks/yum_update.yaml - OS::TripleO::Tasks::ControllerPrePuppet: extraconfig/tasks/noop.yaml - OS::TripleO::Tasks::ControllerPostPuppet: extraconfig/tasks/noop.yaml + OS::TripleO::Tasks::ControllerPrePuppet: OS::Heat::None + OS::TripleO::Tasks::ControllerPostPuppet: OS::Heat::None # This creates the "heat-admin" user for all OS images by default # To disable, replace with firstboot/userdata_default.yaml @@ -56,13 +56,12 @@ resource_registry: OS::TripleO::Network: network/networks.yaml OS::TripleO::VipConfig: puppet/vip-config.yaml - - OS::TripleO::Network::External: network/noop.yaml - OS::TripleO::Network::InternalApi: network/noop.yaml - OS::TripleO::Network::StorageMgmt: network/noop.yaml - OS::TripleO::Network::Storage: network/noop.yaml - OS::TripleO::Network::Tenant: network/noop.yaml - OS::TripleO::Network::Management: network/noop.yaml + OS::TripleO::Network::External: OS::Heat::None + OS::TripleO::Network::InternalApi: OS::Heat::None + OS::TripleO::Network::StorageMgmt: OS::Heat::None + OS::TripleO::Network::Storage: OS::Heat::None + OS::TripleO::Network::Tenant: OS::Heat::None + OS::TripleO::Network::Management: OS::Heat::None OS::TripleO::Network::Ports::NetVipMap: network/ports/net_ip_map.yaml OS::TripleO::Network::Ports::NetIpMap: network/ports/net_ip_map.yaml @@ -124,6 +123,9 @@ resource_registry: # services OS::TripleO::Services: puppet/services/services.yaml + OS::TripleO::Services::Keystone: puppet/services/keystone.yaml + OS::TripleO::Services::GlanceApi: puppet/services/glance-api.yaml + OS::TripleO::Services::GlanceRegistry: puppet/services/glance-registry.yaml parameter_defaults: EnablePackageInstall: false diff --git a/overcloud.yaml b/overcloud.yaml index cd724b3e..e1520477 100644 --- a/overcloud.yaml +++ b/overcloud.yaml @@ -32,6 +32,12 @@ parameters: description: The password for the ceilometer service account. type: string hidden: true + CeilometerMeterDispatcher: + default: 'database' + description: Dispatcher to process meter data + type: string + constraints: + - allowed_values: ['gnocchi', 'database'] # This has to be an UUID so for now we generate it outside the template CephClusterFSID: default: '' @@ -355,10 +361,6 @@ parameters: type: json # Controller-specific params - AdminToken: - description: The keystone auth secret. - type: string - hidden: true CinderLVMLoopDeviceSize: default: 10280 description: The size of the loopback file used by the cinder LVM driver. @@ -468,25 +470,21 @@ parameters: ] } type: json - GlanceLogFile: - description: The filepath of the file to use for logging messages from Glance. - type: string - default: '' - GlanceNotifierStrategy: - description: Strategy to use for Glance notification queue - type: string - default: noop - GlancePassword: - description: The password for the glance service account, used by the glance services. - type: string - hidden: true - GlanceBackend: - default: swift - description: The short name of the Glance backend to use. Should be one + GnocchiBackend: + default: file + description: The short name of the Gnocchi backend to use. Should be one of swift, rbd or file type: string constraints: - allowed_values: ['swift', 'file', 'rbd'] + GnocchiIndexerBackend: + default: 'mysql' + description: The short name of the Gnocchi indexer backend to use. + type: string + GnocchiPassword: + description: The password for the gnocchi service account. + type: string + hidden: true HeatPassword: description: The password for the Heat service account, used by the Heat services. type: string @@ -499,38 +497,6 @@ parameters: default: 'instance-%08x' description: Template string to be used to generate instance names type: string - KeystoneCACertificate: - default: '' - description: Keystone self-signed certificate authority certificate. - type: string - KeystoneSigningCertificate: - default: '' - description: Keystone certificate for verifying token validity. - type: string - KeystoneSigningKey: - default: '' - description: Keystone key for signing tokens. - type: string - hidden: true - KeystoneSSLCertificate: - default: '' - description: Keystone certificate for verifying token validity. - type: string - KeystoneSSLCertificateKey: - default: '' - description: Keystone key for signing tokens. - type: string - hidden: true - KeystoneNotificationDriver: - description: Comma-separated list of Oslo notification drivers used by Keystone - default: ['messaging'] - type: comma_delimited_list - KeystoneNotificationFormat: - description: The Keystone notification format - default: 'basic' - type: string - constraints: - - allowed_values: [ 'basic', 'cadf' ] ManageFirewall: default: false description: Whether to manage IPtables rules. @@ -680,6 +646,7 @@ parameters: NeutronTenantNetwork: tenant CeilometerApiNetwork: internal_api AodhApiNetwork: internal_api + GnocchiApiNetwork: internal_api MongoDbNetwork: internal_api CinderApiNetwork: internal_api CinderIscsiNetwork: storage @@ -712,7 +679,10 @@ parameters: type: json ControllerServices: - default: [] + default: + - OS::TripleO::Services::Keystone + - OS::TripleO::Services::GlanceApi + - OS::TripleO::Services::GlanceRegistry description: A list of service resources (configured in the Heat resource_registry) which represent nested stacks for each service that should get installed on the Controllers. @@ -889,6 +859,8 @@ resources: AodhApiVirtualIP: {get_attr: [VipMap, net_ip_uri_map, {get_param: [ServiceNetMap, AodhApiNetwork]}]} CinderApiVirtualIP: {get_attr: [VipMap, net_ip_uri_map, {get_param: [ServiceNetMap, CinderApiNetwork]}]} GlanceApiVirtualIP: {get_attr: [VipMap, net_ip_uri_map, {get_param: [ServiceNetMap, GlanceApiNetwork]}]} + GlanceRegistryVirtualIP: {get_attr: [VipMap, net_ip_uri_map, {get_param: [ServiceNetMap, GlanceRegistryNetwork]}]} + GnocchiApiVirtualIP: {get_attr: [VipMap, net_ip_uri_map, {get_param: [ServiceNetMap, GnocchiApiNetwork]}]} HeatApiVirtualIP: {get_attr: [VipMap, net_ip_uri_map, {get_param: [ServiceNetMap, HeatApiNetwork]}]} KeystoneAdminApiVirtualIP: {get_attr: [VipMap, net_ip_uri_map, {get_param: [ServiceNetMap, KeystoneAdminApiNetwork]}]} KeystonePublicApiVirtualIP: {get_attr: [VipMap, net_ip_uri_map, {get_param: [ServiceNetMap, KeystonePublicApiNetwork]}]} @@ -916,11 +888,11 @@ resources: type: OS::TripleO::Controller properties: AdminPassword: {get_param: AdminPassword} - AdminToken: {get_param: AdminToken} AodhPassword: {get_param: AodhPassword} CeilometerBackend: {get_param: CeilometerBackend} CeilometerMeteringSecret: {get_param: CeilometerMeteringSecret} CeilometerPassword: {get_param: CeilometerPassword} + CeilometerMeterDispatcher: {get_param: CeilometerMeterDispatcher} CinderLVMLoopDeviceSize: {get_param: CinderLVMLoopDeviceSize} CinderNfsMountOptions: {get_param: CinderNfsMountOptions} CinderNfsServers: {get_param: CinderNfsServers} @@ -943,10 +915,9 @@ resources: ExtraConfig: {get_param: ExtraConfig} FencingConfig: {get_param: FencingConfig} Flavor: {get_param: OvercloudControlFlavor} - GlancePassword: {get_param: GlancePassword} - GlanceBackend: {get_param: GlanceBackend} - GlanceNotifierStrategy: {get_param: GlanceNotifierStrategy} - GlanceLogFile: {get_param: GlanceLogFile} + GnocchiPassword: {get_param: GnocchiPassword} + GnocchiBackend: {get_param: GnocchiBackend} + GnocchiIndexerBackend: {get_param: GnocchiIndexerBackend} HAProxySyslogAddress: {get_param: HAProxySyslogAddress} HeatPassword: {get_param: HeatPassword} HeatStackDomainAdminPassword: {get_param: HeatStackDomainAdminPassword} @@ -957,13 +928,6 @@ resources: ImageUpdatePolicy: {get_param: ImageUpdatePolicy} InstanceNameTemplate: {get_param: InstanceNameTemplate} KeyName: {get_param: KeyName} - KeystoneCACertificate: {get_param: KeystoneCACertificate} - KeystoneSigningCertificate: {get_param: KeystoneSigningCertificate} - KeystoneSigningKey: {get_param: KeystoneSigningKey} - KeystoneSSLCertificate: {get_param: KeystoneSSLCertificate} - KeystoneSSLCertificateKey: {get_param: KeystoneSSLCertificateKey} - KeystoneNotificationDriver: {get_param: KeystoneNotificationDriver} - KeystoneNotificationFormat: {get_param: KeystoneNotificationFormat} MemcachedIPv6: {get_param: MemcachedIPv6} MysqlClusterUniquePart: {get_attr: [MysqlClusterUniquePart, value]} MysqlInnodbBufferPoolSize: {get_param: MysqlInnodbBufferPoolSize} @@ -1034,17 +998,14 @@ resources: EndpointMap: {get_attr: [EndpointMap, endpoint_map]} CeilometerApiVirtualIP: {get_attr: [VipMap, net_ip_map, {get_param: [ServiceNetMap, CeilometerApiNetwork]}]} AodhApiVirtualIP: {get_attr: [VipMap, net_ip_map, {get_param: [ServiceNetMap, AodhApiNetwork]}]} + GnocchiApiVirtualIP: {get_attr: [VipMap, net_ip_map, {get_param: [ServiceNetMap, GnocchiApiNetwork]}]} CinderApiVirtualIP: {get_attr: [VipMap, net_ip_map, {get_param: [ServiceNetMap, CinderApiNetwork]}]} HeatApiVirtualIP: {get_attr: [VipMap, net_ip_map, {get_param: [ServiceNetMap, HeatApiNetwork]}]} HeatApiVirtualIPUri: {get_attr: [VipMap, net_ip_uri_map, {get_param: [ServiceNetMap, HeatApiNetwork]}]} - GlanceApiVirtualIP: {get_attr: [VipMap, net_ip_map, {get_param: [ServiceNetMap, GlanceApiNetwork]}]} - GlanceRegistryVirtualIP: {get_attr: [VipMap, net_ip_map, {get_param: [ServiceNetMap, GlanceRegistryNetwork]}]} NovaApiVirtualIP: {get_attr: [VipMap, net_ip_map, {get_param: [ServiceNetMap, NovaApiNetwork]}]} SwiftProxyVirtualIP: {get_attr: [VipMap, net_ip_map, {get_param: [ServiceNetMap, SwiftProxyNetwork]}]} MysqlVirtualIP: {get_attr: [VipMap, net_ip_map, {get_param: [ServiceNetMap, MysqlNetwork]}]} MysqlVirtualIPUri: {get_attr: [VipMap, net_ip_uri_map, {get_param: [ServiceNetMap, MysqlNetwork]}]} - KeystoneAdminApiVirtualIP: {get_attr: [VipMap, net_ip_map, {get_param: [ServiceNetMap, KeystoneAdminApiNetwork]}]} - KeystonePublicApiVirtualIP: {get_attr: [VipMap, net_ip_map, {get_param: [ServiceNetMap, KeystonePublicApiNetwork]}]} NeutronApiVirtualIP: {get_attr: [VipMap, net_ip_map, {get_param: [ServiceNetMap, NeutronApiNetwork]}]} NovaApiVirtualIP: {get_attr: [VipMap, net_ip_map, {get_param: [ServiceNetMap, NovaApiNetwork]}]} SaharaApiVirtualIP: {get_attr: [VipMap, net_ip_map, {get_param: [ServiceNetMap, SaharaApiNetwork]}]} @@ -1274,6 +1235,7 @@ resources: swift_proxy_node_ips: {get_attr: [ControllerIpListMap, net_ip_map, {get_param: [ServiceNetMap, SwiftProxyNetwork]}]} ceilometer_api_node_ips: {get_attr: [ControllerIpListMap, net_ip_map, {get_param: [ServiceNetMap, CeilometerApiNetwork]}]} aodh_api_node_ips: {get_attr: [ControllerIpListMap, net_ip_map, {get_param: [ServiceNetMap, AodhApiNetwork]}]} + gnocchi_api_node_ips: {get_attr: [ControllerIpListMap, net_ip_map, {get_param: [ServiceNetMap, GnocchiApiNetwork]}]} nova_api_node_ips: {get_attr: [ControllerIpListMap, net_ip_map, {get_param: [ServiceNetMap, NovaApiNetwork]}]} nova_metadata_node_ips: {get_attr: [ControllerIpListMap, net_ip_map, {get_param: [ServiceNetMap, NovaMetadataNetwork]}]} glance_api_node_ips: {get_attr: [ControllerIpListMap, net_ip_map, {get_param: [ServiceNetMap, GlanceApiNetwork]}]} @@ -1395,6 +1357,7 @@ resources: nova_metadata_vip: {get_attr: [VipMap, net_ip_map, {get_param: [ServiceNetMap, NovaMetadataNetwork]}]} ceilometer_api_vip: {get_attr: [VipMap, net_ip_map, {get_param: [ServiceNetMap, CeilometerApiNetwork]}]} aodh_api_vip: {get_attr: [VipMap, net_ip_map, {get_param: [ServiceNetMap, AodhApiNetwork]}]} + gnocchi_api_vip: {get_attr: [VipMap, net_ip_map, {get_param: [ServiceNetMap, GnocchiApiNetwork]}]} heat_api_vip: {get_attr: [VipMap, net_ip_map, {get_param: [ServiceNetMap, HeatApiNetwork]}]} horizon_vip: {get_attr: [VipMap, net_ip_map, {get_param: [ServiceNetMap, HorizonNetwork]}]} redis_vip: {get_attr: [RedisVirtualIP, ip_address]} @@ -1690,6 +1653,9 @@ outputs: GlanceInternalVip: description: VIP for Glance API internal endpoint value: {get_attr: [VipMap, net_ip_map, {get_param: [ServiceNetMap, GlanceApiNetwork]}]} + GnocchiInternalVip: + description: VIP for Gnocchi API internal endpoint + value: {get_attr: [VipMap, net_ip_map, {get_param: [ServiceNetMap, GnocchiApiNetwork]}]} HeatInternalVip: description: VIP for Heat API internal endpoint value: {get_attr: [VipMap, net_ip_map, {get_param: [ServiceNetMap, HeatApiNetwork]}]} @@ -1708,6 +1674,12 @@ outputs: SwiftInternalVip: description: VIP for Swift Proxy internal endpoint value: {get_attr: [VipMap, net_ip_map, {get_param: [ServiceNetMap, SwiftProxyNetwork]}]} + EndpointMap: + description: | + Mapping of the resources with the needed info for their endpoints. + This includes the protocol used, the IP, port and also a full + representation of the URI. + value: {get_attr: [EndpointMap, endpoint_map]} HostsEntry: description: | The content that should be appended to your /etc/hosts if you want to get diff --git a/puppet/all-nodes-config.yaml b/puppet/all-nodes-config.yaml index fed9dd31..90eb1b09 100644 --- a/puppet/all-nodes-config.yaml +++ b/puppet/all-nodes-config.yaml @@ -44,6 +44,8 @@ parameters: type: comma_delimited_list glance_registry_node_ips: type: comma_delimited_list + gnocchi_api_node_ips: + type: comma_delimited_list cinder_api_node_ips: type: comma_delimited_list neutron_api_node_ips: @@ -197,6 +199,14 @@ resources: list_join: - "','" - {get_param: aodh_api_node_ips} + gnocchi_api_node_ips: + str_replace: + template: "['SERVERS_LIST']" + params: + SERVERS_LIST: + list_join: + - "','" + - {get_param: gnocchi_api_node_ips} nova_api_node_ips: str_replace: template: "['SERVERS_LIST']" diff --git a/puppet/ceph-cluster-config.yaml b/puppet/ceph-cluster-config.yaml index dc2f98ed..fd161886 100644 --- a/puppet/ceph-cluster-config.yaml +++ b/puppet/ceph-cluster-config.yaml @@ -36,6 +36,9 @@ parameters: GlanceRbdPoolName: default: images type: string + GnocchiRbdPoolName: + default: metrics + type: string CephClientUserName: default: openstack type: string @@ -91,21 +94,25 @@ resources: cap_mon: 'allow profile bootstrap-osd' }, client.CLIENT_USER: { - secret: 'ADMIN_KEY', + secret: 'CLIENT_KEY', mode: '0644', cap_mon: 'allow r', - cap_osd: 'allow class-read object_prefix rbd_children, allow rwx pool=CINDER_POOL, allow rwx pool=NOVA_POOL, allow rwx pool=GLANCE_POOL' + cap_osd: 'allow class-read object_prefix rbd_children, allow rwx pool=CINDER_POOL, allow rwx pool=NOVA_POOL, allow rwx pool=GLANCE_POOL, allow rwx pool=GNOCCHI_POOL' } }" params: CLIENT_USER: {get_param: CephClientUserName} + CLIENT_KEY: {get_param: ceph_client_key} ADMIN_KEY: {get_param: ceph_admin_key} NOVA_POOL: {get_param: NovaRbdPoolName} CINDER_POOL: {get_param: CinderRbdPoolName} GLANCE_POOL: {get_param: GlanceRbdPoolName} + GNOCCHI_POOL: {get_param: GnocchiRbdPoolName} nova::compute::rbd::libvirt_images_rbd_pool: {get_param: NovaRbdPoolName} cinder_rbd_pool_name: {get_param: CinderRbdPoolName} glance::backend::rbd::rbd_store_pool: {get_param: GlanceRbdPoolName} + gnocchi::storage::ceph::ceph_pool: {get_param: GnocchiRbdPoolName} + gnocchi::storage::ceph::ceph_username: {get_param: CephClientUserName} nova::compute::rbd::libvirt_rbd_user: {get_param: CephClientUserName} glance::backend::rbd::rbd_store_user: {get_param: CephClientUserName} nova::compute::rbd::rbd_keyring: @@ -113,11 +120,17 @@ resources: - '.' - - 'client' - {get_param: CephClientUserName} + gnocchi::storage::ceph::ceph_keyring: + list_join: + - '.' + - - 'client' + - {get_param: CephClientUserName} ceph_client_user_name: {get_param: CephClientUserName} ceph_pools: - {get_param: CinderRbdPoolName} - {get_param: NovaRbdPoolName} - {get_param: GlanceRbdPoolName} + - {get_param: GnocchiRbdPoolName} outputs: config_id: diff --git a/puppet/ceph-storage.yaml b/puppet/ceph-storage.yaml index d2988926..f0eb71e4 100644 --- a/puppet/ceph-storage.yaml +++ b/puppet/ceph-storage.yaml @@ -256,6 +256,7 @@ resources: - ceph - '"%{::osfamily}"' - common + merge_behavior: deeper datafiles: common: raw_data: {get_file: hieradata/common.yaml} @@ -313,12 +314,12 @@ outputs: str_replace: template: | PRIMARYIP PRIMARYHOST.DOMAIN PRIMARYHOST - EXTERNALIP EXTERNALHOST - INTERNAL_APIIP INTERNAL_APIHOST - STORAGEIP STORAGEHOST - STORAGE_MGMTIP STORAGE_MGMTHOST - TENANTIP TENANTHOST - MANAGEMENTIP MANAGEMENTHOST + EXTERNALIP EXTERNALHOST.DOMAIN EXTERNALHOST + INTERNAL_APIIP INTERNAL_APIHOST.DOMAIN INTERNAL_APIHOST + STORAGEIP STORAGEHOST.DOMAIN STORAGEHOST + STORAGE_MGMTIP STORAGE_MGMTHOST.DOMAIN STORAGE_MGMTHOST + TENANTIP TENANTHOST.DOMAIN TENANTHOST + MANAGEMENTIP MANAGEMENTHOST.DOMAIN MANAGEMENTHOST params: PRIMARYIP: {get_attr: [NetIpMap, net_ip_map, {get_param: [ServiceNetMap, CephStorageHostnameResolveNetwork]}]} DOMAIN: {get_param: CloudDomain} @@ -326,37 +327,37 @@ outputs: EXTERNALIP: {get_attr: [ExternalPort, ip_address]} EXTERNALHOST: list_join: - - '-' + - '.' - - {get_attr: [CephStorage, name]} - external INTERNAL_APIIP: {get_attr: [InternalApiPort, ip_address]} INTERNAL_APIHOST: list_join: - - '-' + - '.' - - {get_attr: [CephStorage, name]} - internalapi STORAGEIP: {get_attr: [StoragePort, ip_address]} STORAGEHOST: list_join: - - '-' + - '.' - - {get_attr: [CephStorage, name]} - storage STORAGE_MGMTIP: {get_attr: [StorageMgmtPort, ip_address]} STORAGE_MGMTHOST: list_join: - - '-' + - '.' - - {get_attr: [CephStorage, name]} - storagemgmt TENANTIP: {get_attr: [TenantPort, ip_address]} TENANTHOST: list_join: - - '-' + - '.' - - {get_attr: [CephStorage, name]} - tenant MANAGEMENTIP: {get_attr: [ManagementPort, ip_address]} MANAGEMENTHOST: list_join: - - '-' + - '.' - - {get_attr: [CephStorage, name]} - management nova_server_resource: diff --git a/puppet/cinder-storage.yaml b/puppet/cinder-storage.yaml index b5694802..c1a04e24 100644 --- a/puppet/cinder-storage.yaml +++ b/puppet/cinder-storage.yaml @@ -316,6 +316,7 @@ resources: - all_nodes # provided by allNodesConfig - '"%{::osfamily}"' - common + merge_behavior: deeper datafiles: common: raw_data: {get_file: hieradata/common.yaml} @@ -379,12 +380,12 @@ outputs: str_replace: template: | PRIMARYIP PRIMARYHOST.DOMAIN PRIMARYHOST - EXTERNALIP EXTERNALHOST - INTERNAL_APIIP INTERNAL_APIHOST - STORAGEIP STORAGEHOST - STORAGE_MGMTIP STORAGE_MGMTHOST - TENANTIP TENANTHOST - MANAGEMENTIP MANAGEMENTHOST + EXTERNALIP EXTERNALHOST.DOMAIN EXTERNALHOST + INTERNAL_APIIP INTERNAL_APIHOST.DOMAIN INTERNAL_APIHOST + STORAGEIP STORAGEHOST.DOMAIN STORAGEHOST + STORAGE_MGMTIP STORAGE_MGMTHOST.DOMAIN STORAGE_MGMTHOST + TENANTIP TENANTHOST.DOMAIN TENANTHOST + MANAGEMENTIP MANAGEMENTHOST.DOMAIN MANAGEMENTHOST params: PRIMARYIP: {get_attr: [NetIpMap, net_ip_map, {get_param: [ServiceNetMap, BlockStorageHostnameResolveNetwork]}]} DOMAIN: {get_param: CloudDomain} @@ -392,37 +393,37 @@ outputs: EXTERNALIP: {get_attr: [ExternalPort, ip_address]} EXTERNALHOST: list_join: - - '-' + - '.' - - {get_attr: [BlockStorage, name]} - external INTERNAL_APIIP: {get_attr: [InternalApiPort, ip_address]} INTERNAL_APIHOST: list_join: - - '-' + - '.' - - {get_attr: [BlockStorage, name]} - internalapi STORAGEIP: {get_attr: [StoragePort, ip_address]} STORAGEHOST: list_join: - - '-' + - '.' - - {get_attr: [BlockStorage, name]} - storage STORAGE_MGMTIP: {get_attr: [StorageMgmtPort, ip_address]} STORAGE_MGMTHOST: list_join: - - '-' + - '.' - - {get_attr: [BlockStorage, name]} - storagemgmt TENANTIP: {get_attr: [TenantPort, ip_address]} TENANTHOST: list_join: - - '-' + - '.' - - {get_attr: [BlockStorage, name]} - tenant MANAGEMENTIP: {get_attr: [ManagementPort, ip_address]} MANAGEMENTHOST: list_join: - - '-' + - '.' - - {get_attr: [BlockStorage, name]} - management nova_server_resource: diff --git a/puppet/compute.yaml b/puppet/compute.yaml index f5c848c8..4c18067a 100644 --- a/puppet/compute.yaml +++ b/puppet/compute.yaml @@ -486,6 +486,7 @@ resources: - nova_nuage_data # Optionally provided by ComputeExtraConfigPre - midonet_data # Optionally provided by AllNodesExtraConfig - neutron_opencontrail_data # Optionally provided by ComputeExtraConfigPre + merge_behavior: deeper datafiles: compute_extraconfig: mapped_data: {get_param: NovaComputeExtraConfig} @@ -760,12 +761,12 @@ outputs: str_replace: template: | PRIMARYIP PRIMARYHOST.DOMAIN PRIMARYHOST - EXTERNALIP EXTERNALHOST - INTERNAL_APIIP INTERNAL_APIHOST - STORAGEIP STORAGEHOST - STORAGE_MGMTIP STORAGE_MGMTHOST - TENANTIP TENANTHOST - MANAGEMENTIP MANAGEMENTHOST + EXTERNALIP EXTERNALHOST.DOMAIN EXTERNALHOST + INTERNAL_APIIP INTERNAL_APIHOST.DOMAIN INTERNAL_APIHOST + STORAGEIP STORAGEHOST.DOMAIN STORAGEHOST + STORAGE_MGMTIP STORAGE_MGMTHOST.DOMAIN STORAGE_MGMTHOST + TENANTIP TENANTHOST.DOMAIN TENANTHOST + MANAGEMENTIP MANAGEMENTHOST.DOMAIN MANAGEMENTHOST params: PRIMARYIP: {get_attr: [NetIpMap, net_ip_map, {get_param: [ServiceNetMap, ComputeHostnameResolveNetwork]}]} DOMAIN: {get_param: CloudDomain} @@ -773,37 +774,37 @@ outputs: EXTERNALIP: {get_attr: [ExternalPort, ip_address]} EXTERNALHOST: list_join: - - '-' + - '.' - - {get_attr: [NovaCompute, name]} - external INTERNAL_APIIP: {get_attr: [InternalApiPort, ip_address]} INTERNAL_APIHOST: list_join: - - '-' + - '.' - - {get_attr: [NovaCompute, name]} - internalapi STORAGEIP: {get_attr: [StoragePort, ip_address]} STORAGEHOST: list_join: - - '-' + - '.' - - {get_attr: [NovaCompute, name]} - storage STORAGE_MGMTIP: {get_attr: [StorageMgmtPort, ip_address]} STORAGE_MGMTHOST: list_join: - - '-' + - '.' - - {get_attr: [NovaCompute, name]} - storagemgmt TENANTIP: {get_attr: [TenantPort, ip_address]} TENANTHOST: list_join: - - '-' + - '.' - - {get_attr: [NovaCompute, name]} - tenant MANAGEMENTIP: {get_attr: [ManagementPort, ip_address]} MANAGEMENTHOST: list_join: - - '-' + - '.' - - {get_attr: [NovaCompute, name]} - management nova_server_resource: diff --git a/puppet/controller.yaml b/puppet/controller.yaml index d966700f..04ce1c34 100644 --- a/puppet/controller.yaml +++ b/puppet/controller.yaml @@ -4,19 +4,10 @@ description: > OpenStack controller node configured by Puppet. parameters: - AdminEmail: - default: 'admin@example.com' - description: The email for the keystone admin account. - type: string - hidden: true AdminPassword: description: The password for the keystone admin account, used for monitoring, querying neutron etc. type: string hidden: true - AdminToken: - description: The keystone auth secret and db password. - type: string - hidden: true AodhApiVirtualIP: type: string default: '' @@ -43,6 +34,12 @@ parameters: default: false description: Whether to store events in ceilometer. type: boolean + CeilometerMeterDispatcher: + default: 'database' + description: Dispatcher to process meter data + type: string + constraints: + - allowed_values: ['gnocchi', 'database'] CinderApiVirtualIP: type: string default: '' @@ -189,49 +186,24 @@ parameters: type: string constraints: - custom_constraint: nova.flavor - GlanceNotifierStrategy: - description: Strategy to use for Glance notification queue - type: string - default: noop - GlanceLogFile: - description: The filepath of the file to use for logging messages from Glance. - type: string - default: '' - GlancePassword: - description: The password for the glance service and db account, used by the glance services. - type: string - hidden: true - GlanceBackend: - default: swift - description: The short name of the Glance backend to use. Should be one + GnocchiBackend: + default: file + description: The short name of the Gnocchi backend to use. Should be one of swift, rbd, or file type: string constraints: - allowed_values: ['swift', 'file', 'rbd'] - GlanceFilePcmkDevice: - default: '' - description: > - An exported storage device that should be mounted by Pacemaker - as Glance storage. Effective when GlanceFilePcmkManage is true. + GnocchiIndexerBackend: + default: 'mysql' + description: The short name of the Gnocchi indexer backend to use. type: string - GlanceFilePcmkFstype: - default: 'nfs' - description: > - Filesystem type for Pacemaker mount used as Glance storage. - Effective when GlanceFilePcmkManage is true. + GnocchiApiVirtualIP: type: string - GlanceFilePcmkManage: - default: false - description: > - Whether to make Glance file backend a mount managed by Pacemaker. - Effective when GlanceBackend is 'file'. - type: boolean - GlanceFilePcmkOptions: default: '' - description: > - Mount options for Pacemaker mount used as Glance storage. - Effective when GlanceFilePcmkManage is true. + GnocchiPassword: + description: The password for the gnocchi service and db account. type: string + hidden: true HAProxyStatsPassword: description: Password for HAProxy stats endpoint type: string @@ -243,10 +215,6 @@ parameters: default: /dev/log description: Syslog address where HAproxy will send its log type: string - GlanceWorkers: - default: 0 - description: Number of workers for Glance service. - type: number HeatPassword: description: The password for the Heat service and db account, used by the Heat services. type: string @@ -295,43 +263,6 @@ parameters: type: string constraints: - custom_constraint: nova.keypair - KeystoneCACertificate: - default: '' - description: Keystone self-signed certificate authority certificate. - type: string - KeystoneEnableDBPurge: - default: true - description: | - Whether to create cron job for purging soft deleted rows in Keystone database. - type: boolean - KeystoneSigningCertificate: - default: '' - description: Keystone certificate for verifying token validity. - type: string - KeystoneSigningKey: - default: '' - description: Keystone key for signing tokens. - type: string - hidden: true - KeystoneSSLCertificate: - default: '' - description: Keystone certificate for verifying token validity. - type: string - KeystoneSSLCertificateKey: - default: '' - description: Keystone key for signing tokens. - type: string - hidden: true - KeystoneNotificationDriver: - description: Comma-separated list of Oslo notification drivers used by Keystone - default: ['messaging'] - type: comma_delimited_list - KeystoneNotificationFormat: - description: The Keystone notification format - default: 'basic' - type: string - constraints: - - allowed_values: [ 'basic', 'cadf' ] KeystoneRegion: type: string default: 'regionOne' @@ -348,10 +279,6 @@ parameters: default: false description: Whether IPtables rules should be purged before setting up the new ones. type: boolean - KeystoneWorkers: - default: 0 - description: Number of workers for Keystone service. - type: number SaharaApiVirtualIP: type: string default: '' @@ -711,24 +638,12 @@ parameters: HeatApiVirtualIPUri: type: string default: '' - GlanceApiVirtualIP: - type: string - default: '' - GlanceRegistryVirtualIP: - type: string - default: '' MysqlVirtualIP: type: string default: '' MysqlVirtualIPUri: type: string default: '' - KeystoneAdminApiVirtualIP: - type: string - default: '' - KeystonePublicApiVirtualIP: - type: string - default: '' NeutronApiVirtualIP: type: string default: '' @@ -954,9 +869,7 @@ resources: bootstack_nodeid: {get_attr: [Controller, name]} ceilometer_workers: {get_param: CeilometerWorkers} cinder_workers: {get_param: CinderWorkers} - glance_workers: {get_param: GlanceWorkers} heat_workers: {get_param: HeatWorkers} - keystone_workers: {get_param: KeystoneWorkers} nova_workers: {get_param: NovaWorkers} neutron_workers: {get_param: NeutronWorkers} swift_workers: {get_param: SwiftWorkers} @@ -988,9 +901,7 @@ resources: heat_enable_db_purge: {get_param: HeatEnableDBPurge} horizon_allowed_hosts: {get_param: HorizonAllowedHosts} horizon_secret: {get_param: HorizonSecret} - admin_email: {get_param: AdminEmail} admin_password: {get_param: AdminPassword} - admin_token: {get_param: AdminToken} neutron_public_interface_ip: {get_param: NeutronPublicInterfaceIP} debug: {get_param: Debug} cinder_enable_db_purge: {get_param: CinderEnableDBPurge} @@ -1015,23 +926,6 @@ resources: - '@' - {get_param: MysqlVirtualIPUri} - '/cinder' - glance_port: {get_param: [EndpointMap, GlanceInternal, port]} - glance_password: {get_param: GlancePassword} - glance_backend: {get_param: GlanceBackend} - glance_file_pcmk_device: {get_param: GlanceFilePcmkDevice} - glance_file_pcmk_fstype: {get_param: GlanceFilePcmkFstype} - glance_file_pcmk_manage: {get_param: GlanceFilePcmkManage} - glance_file_pcmk_options: {get_param: GlanceFilePcmkOptions} - glance_notifier_strategy: {get_param: GlanceNotifierStrategy} - glance_log_file: {get_param: GlanceLogFile} - glance_dsn: - list_join: - - '' - - - 'mysql+pymysql://glance:' - - {get_param: GlancePassword} - - '@' - - {get_param: MysqlVirtualIPUri} - - '/glance' heat_password: {get_param: HeatPassword} heat_stack_domain_admin_password: {get_param: HeatStackDomainAdminPassword} heat_dsn: @@ -1042,26 +936,8 @@ resources: - '@' - {get_param: MysqlVirtualIPUri} - '/heat' - keystone_ca_certificate: {get_param: KeystoneCACertificate} - keystone_signing_key: {get_param: KeystoneSigningKey} - keystone_signing_certificate: {get_param: KeystoneSigningCertificate} - keystone_ssl_certificate: {get_param: KeystoneSSLCertificate} - keystone_ssl_certificate_key: {get_param: KeystoneSSLCertificateKey} - keystone_notification_driver: {get_param: KeystoneNotificationDriver} - keystone_notification_format: {get_param: KeystoneNotificationFormat} - keystone_enable_db_purge: {get_param: KeystoneEnableDBPurge} - keystone_dsn: - list_join: - - '' - - - 'mysql+pymysql://keystone:' - - {get_param: AdminToken} - - '@' - - {get_param: MysqlVirtualIPUri} - - '/keystone' keystone_identity_uri: { get_param: [EndpointMap, KeystoneAdmin, uri_no_suffix] } keystone_auth_uri: {get_param: [EndpointMap, KeystoneInternal, uri] } - keystone_public_url: { get_param: [EndpointMap, KeystonePublic, uri_no_suffix] } - keystone_internal_url: { get_param: [EndpointMap, KeystoneInternal, uri_no_suffix] } keystone_ec2_uri: { get_param: [EndpointMap, KeystoneEC2, uri] } enable_fencing: {get_param: EnableFencing} enable_galera: {get_param: EnableGalera} @@ -1175,6 +1051,10 @@ resources: ceilometer_password: {get_param: CeilometerPassword} ceilometer_store_events: {get_param: CeilometerStoreEvents} aodh_password: {get_param: AodhPassword} + ceilometer_meter_dispatcher: {get_param: CeilometerMeterDispatcher} + gnocchi_password: {get_param: GnocchiPassword} + gnocchi_backend: {get_param: GnocchiBackend} + gnocchi_indexer_backend: {get_param: GnocchiIndexerBackend} ceilometer_coordination_url: list_join: - '' @@ -1191,6 +1071,15 @@ resources: - '@' - {get_param: MysqlVirtualIPUri} - '/ceilometer' + gnocchi_dsn: + list_join: + - '' + - - 'mysql+pymysql://gnocchi:' + - {get_param: GnocchiPassword} + - '@' + - {get_param: MysqlVirtualIPUri} + - '/gnocchi' + gnocchi_internal_url: {get_param: [EndpointMap, GnocchiInternal, uri]} snmpd_readonly_user_name: {get_param: SnmpdReadonlyUserName} snmpd_readonly_user_password: {get_param: SnmpdReadonlyUserPassword} nova_enable_db_purge: {get_param: NovaEnableDBPurge} @@ -1260,7 +1149,6 @@ resources: glance_api_network: {get_attr: [NetIpMap, net_ip_map, {get_param: [ServiceNetMap, GlanceApiNetwork]}]} glance_registry_network: {get_attr: [NetIpMap, net_ip_map, {get_param: [ServiceNetMap, GlanceRegistryNetwork]}]} glance_api_servers: { get_param: [EndpointMap, GlanceInternal, uri]} - glance_registry_host: {get_param: GlanceRegistryVirtualIP} heat_api_network: {get_attr: [NetIpMap, net_ip_map, {get_param: [ServiceNetMap, HeatApiNetwork]}]} keystone_public_api_network: {get_attr: [NetIpMap, net_ip_map, {get_param: [ServiceNetMap, KeystonePublicApiNetwork]}]} keystone_admin_api_network: {get_attr: [NetIpMap, net_ip_map, {get_param: [ServiceNetMap, KeystoneAdminApiNetwork]}]} @@ -1270,9 +1158,15 @@ resources: neutron_local_ip: {get_attr: [NetIpMap, net_ip_map, {get_param: [ServiceNetMap, NeutronTenantNetwork]}]} ceilometer_api_network: {get_attr: [NetIpMap, net_ip_map, {get_param: [ServiceNetMap, CeilometerApiNetwork]}]} aodh_api_network: {get_attr: [NetIpMap, net_ip_map, {get_param: [ServiceNetMap, AodhApiNetwork]}]} + gnocchi_api_network: {get_attr: [NetIpMap, net_ip_map, {get_param: [ServiceNetMap, GnocchiApiNetwork]}]} nova_api_network: {get_attr: [NetIpMap, net_ip_map, {get_param: [ServiceNetMap, NovaApiNetwork]}]} nova_metadata_network: {get_attr: [NetIpMap, net_ip_map, {get_param: [ServiceNetMap, NovaMetadataNetwork]}]} horizon_network: {get_attr: [NetIpMap, net_ip_map, {get_param: [ServiceNetMap, HorizonNetwork]}]} + horizon_subnet: + str_replace: + template: "['SUBNET']" + params: + SUBNET: {get_attr: [NetIpSubnetMap, net_ip_subnet_map, {get_param: [ServiceNetMap, HorizonNetwork]}]} rabbitmq_network: {get_attr: [NetIpMap, net_ip_map, {get_param: [ServiceNetMap, RabbitMqNetwork]}]} redis_network: {get_attr: [NetIpMap, net_ip_map, {get_param: [ServiceNetMap, RedisNetwork]}]} redis_password: {get_param: RedisPassword} @@ -1319,6 +1213,7 @@ resources: - midonet_data #Optionally provided by AllNodesExtraConfig - neutron_opencontrail_data # Optionally provided by ControllerExtraConfigPre - neutron_plumgrid_data # Optionally provided by ControllerExtraConfigPre + merge_behavior: deeper datafiles: service_configs: mapped_data: {get_param: ServiceConfigSettings} @@ -1389,38 +1284,8 @@ resources: cinder::db::mysql::password: {get_input: cinder_password} # Glance - glance::api::bind_port: {get_input: glance_port} glance::api::bind_host: {get_input: glance_api_network} - glance::api::auth_uri: {get_input: keystone_auth_uri} - glance::api::identity_uri: {get_input: keystone_identity_uri} - glance::api::registry_host: {get_input: glance_registry_host} - glance::api::keystone_password: {get_input: glance_password} - glance::api::debug: {get_input: debug} - glance::api::workers: {get_input: glance_workers} - glance_notifier_strategy: {get_input: glance_notifier_strategy} - glance_log_file: {get_input: glance_log_file} - glance_log_file: {get_input: glance_log_file} - glance::api::database_connection: {get_input: glance_dsn} - glance::registry::keystone_password: {get_input: glance_password} - glance::registry::database_connection: {get_input: glance_dsn} glance::registry::bind_host: {get_input: glance_registry_network} - glance::registry::auth_uri: {get_input: keystone_auth_uri} - glance::registry::identity_uri: {get_input: keystone_identity_uri} - glance::registry::debug: {get_input: debug} - glance::backend::swift::swift_store_auth_address: {get_input: keystone_auth_uri} - glance::registry::workers: {get_input: glance_workers} - glance::backend::swift::swift_store_user: service:glance - glance::backend::swift::swift_store_key: {get_input: glance_password} - glance_backend: {get_input: glance_backend} - glance::db::mysql::password: {get_input: glance_password} - glance_file_pcmk_device: {get_input: glance_file_pcmk_device} - glance_file_pcmk_fstype: {get_input: glance_file_pcmk_fstype} - glance_file_pcmk_manage: {get_input: glance_file_pcmk_manage} - glance_file_pcmk_options: {get_input: glance_file_pcmk_options} - glance::notify::rabbitmq::rabbit_userid: {get_input: rabbit_username} - glance::notify::rabbitmq::rabbit_password: {get_input: rabbit_password} - glance::notify::rabbitmq::rabbit_use_ssl: {get_input: rabbit_client_use_ssl} - # Heat heat_stack_domain_admin_password: {get_input: heat_stack_domain_admin_password} heat::engine::heat_watch_server_url: {get_input: heat.watch_server_url} @@ -1441,43 +1306,17 @@ resources: heat::api_cloudwatch::workers: {get_input: heat_workers} heat::api_cfn::bind_host: {get_input: heat_api_network} heat::api_cfn::workers: {get_input: heat_workers} + heat::engine::num_engine_workers: {get_input: heat_workers} heat::database_connection: {get_input: heat_dsn} heat::debug: {get_input: debug} heat::db::mysql::password: {get_input: heat_password} heat_enable_db_purge: {get_input: heat_enable_db_purge} heat::keystone::domain::domain_password: {get_input: heat_stack_domain_admin_password} - # Keystone - keystone::admin_token: {get_input: admin_token} - keystone::roles::admin::password: {get_input: admin_password} - keystone_ca_certificate: {get_input: keystone_ca_certificate} - keystone_signing_key: {get_input: keystone_signing_key} - keystone_signing_certificate: {get_input: keystone_signing_certificate} - keystone_ssl_certificate: {get_input: keystone_ssl_certificate} - keystone_ssl_certificate_key: {get_input: keystone_ssl_certificate_key} - keystone::database_connection: {get_input: keystone_dsn} keystone::admin_bind_host: {get_input: keystone_admin_api_network} keystone::public_bind_host: {get_input: keystone_public_api_network} keystone::wsgi::apache::bind_host: {get_input: keystone_public_api_network} keystone::wsgi::apache::admin_bind_host: {get_input: keystone_admin_api_network} - keystone::debug: {get_input: debug} - keystone::db::mysql::password: {get_input: admin_token} - keystone::rabbit_userid: {get_input: rabbit_username} - keystone::rabbit_password: {get_input: rabbit_password} - keystone::rabbit_use_ssl: {get_input: rabbit_client_use_ssl} - keystone::rabbit_port: {get_input: rabbit_client_port} - keystone::notification_driver: {get_input: keystone_notification_driver} - keystone::notification_format: {get_input: keystone_notification_format} - keystone::roles::admin::email: {get_input: admin_email} - keystone::roles::admin::password: {get_input: admin_password} - keystone::endpoint::public_url: {get_input: keystone_public_url} - keystone::endpoint::internal_url: {get_input: keystone_internal_url} - keystone::endpoint::admin_url: {get_input: keystone_identity_uri} - keystone::endpoint::region: {get_input: keystone_region} - keystone::admin_workers: {get_input: keystone_workers} - keystone::public_workers: {get_input: keystone_workers} - keystone_enable_db_purge: {get_input: keystone_enable_db_purge} - keystone::public_endpoint: {get_input: keystone_public_url} # MongoDB mongodb::server::bind_ip: {get_input: mongo_db_network} mongodb::server::nojournal: {get_input: mongodb_no_journal} @@ -1575,6 +1414,11 @@ resources: ceilometer::agent::central::coordination_url: {get_input: ceilometer_coordination_url} ceilometer::agent::notification::store_events: {get_input: ceilometer_store_events} ceilometer::db::mysql::password: {get_input: ceilometer_password} + ceilometer::collector::meter_dispatcher: {get_input: ceilometer_meter_dispatcher} + ceilometer::dispatcher::gnocchi::url: {get_input: gnocchi_internal_url } + ceilometer::dispatcher::gnocchi::filter_project: 'service' + ceilometer::dispatcher::gnocchi::archive_policy: 'low' + ceilometer::dispatcher::gnocchi::resources_definition_file: 'gnocchi_resources.yaml' snmpd_readonly_user_name: {get_input: snmpd_readonly_user_name} snmpd_readonly_user_password: {get_input: snmpd_readonly_user_password} @@ -1596,6 +1440,22 @@ resources: # for a migration path from ceilometer-alarm to aodh, we use the same database & coordination aodh::evaluator::coordination_url: {get_input: ceilometer_coordination_url} + # Gnocchi + gnocchi_backend: {get_input: gnocchi_backend} + gnocchi_indexer_backend: {get_input: gnocchi_indexer_backend} + gnocchi_mysql_conn_string: {get_input: gnocchi_dsn} + gnocchi::debug: {get_input: debug} + gnocchi::wsgi::apache::ssl: false + gnocchi::wsgi::apache::bind_host: {get_input: gnocchi_api_network} + gnocchi::api::service_name: 'httpd' + gnocchi::api::host: {get_input: gnocchi_api_network} + gnocchi::api::keystone_password: {get_input: gnocchi_password} + gnocchi::api::keystone_auth_uri: {get_input: keystone_auth_uri} + gnocchi::api::keystone_identity_uri: {get_input: keystone_identity_uri} + gnocchi::db::mysql::password: {get_input: gnocchi_password} + gnocchi::storage::swift::swift_authurl: {get_input: keystone_auth_uri} + gnocchi::storage::swift::swift_key: {get_input: gnocchi_password} + # Nova nova::rabbit_userid: {get_input: rabbit_username} nova::rabbit_password: {get_input: rabbit_password} @@ -1627,6 +1487,7 @@ resources: nova_enable_db_purge: {get_input: nova_enable_db_purge} # Horizon + apache::mod::remoteip::proxy_ips: {get_input: horizon_subnet} apache::ip: {get_input: horizon_network} horizon::allowed_hosts: {get_input: horizon_allowed_hosts} horizon::django_debug: {get_input: debug} @@ -1758,12 +1619,12 @@ outputs: str_replace: template: | PRIMARYIP PRIMARYHOST.DOMAIN PRIMARYHOST - EXTERNALIP EXTERNALHOST - INTERNAL_APIIP INTERNAL_APIHOST - STORAGEIP STORAGEHOST - STORAGE_MGMTIP STORAGE_MGMTHOST - TENANTIP TENANTHOST - MANAGEMENTIP MANAGEMENTHOST + EXTERNALIP EXTERNALHOST.DOMAIN EXTERNALHOST + INTERNAL_APIIP INTERNAL_APIHOST.DOMAIN INTERNAL_APIHOST + STORAGEIP STORAGEHOST.DOMAIN STORAGEHOST + STORAGE_MGMTIP STORAGE_MGMTHOST.DOMAIN STORAGE_MGMTHOST + TENANTIP TENANTHOST.DOMAIN TENANTHOST + MANAGEMENTIP MANAGEMENTHOST.DOMAIN MANAGEMENTHOST params: PRIMARYIP: {get_attr: [NetIpMap, net_ip_map, {get_param: [ServiceNetMap, ControllerHostnameResolveNetwork]}]} DOMAIN: {get_param: CloudDomain} @@ -1771,37 +1632,37 @@ outputs: EXTERNALIP: {get_attr: [ExternalPort, ip_address]} EXTERNALHOST: list_join: - - '-' + - '.' - - {get_attr: [Controller, name]} - external INTERNAL_APIIP: {get_attr: [InternalApiPort, ip_address]} INTERNAL_APIHOST: list_join: - - '-' + - '.' - - {get_attr: [Controller, name]} - internalapi STORAGEIP: {get_attr: [StoragePort, ip_address]} STORAGEHOST: list_join: - - '-' + - '.' - - {get_attr: [Controller, name]} - storage STORAGE_MGMTIP: {get_attr: [StorageMgmtPort, ip_address]} STORAGE_MGMTHOST: list_join: - - '-' + - '.' - - {get_attr: [Controller, name]} - storagemgmt TENANTIP: {get_attr: [TenantPort, ip_address]} TENANTHOST: list_join: - - '-' + - '.' - - {get_attr: [Controller, name]} - tenant MANAGEMENTIP: {get_attr: [ManagementPort, ip_address]} MANAGEMENTHOST: list_join: - - '-' + - '.' - - {get_attr: [Controller, name]} - management nova_server_resource: diff --git a/puppet/extraconfig/ceph/ceph-external-config.yaml b/puppet/extraconfig/ceph/ceph-external-config.yaml index 312d49a0..5942088c 100644 --- a/puppet/extraconfig/ceph/ceph-external-config.yaml +++ b/puppet/extraconfig/ceph/ceph-external-config.yaml @@ -38,6 +38,9 @@ parameters: GlanceRbdPoolName: default: images type: string + GnocchiRbdPoolName: + default: metrics + type: string CephClientUserName: default: openstack type: string @@ -68,7 +71,7 @@ resources: secret: 'CLIENT_KEY', mode: '0644', cap_mon: 'allow r', - cap_osd: 'allow class-read object_prefix rbd_children, allow rwx pool=CINDER_POOL, allow rwx pool=NOVA_POOL, allow rwx pool=GLANCE_POOL' + cap_osd: 'allow class-read object_prefix rbd_children, allow rwx pool=CINDER_POOL, allow rwx pool=NOVA_POOL, allow rwx pool=GLANCE_POOL, allow rwx pool=GNOCCHI_POOL' } }" params: @@ -77,10 +80,13 @@ resources: NOVA_POOL: {get_param: NovaRbdPoolName} CINDER_POOL: {get_param: CinderRbdPoolName} GLANCE_POOL: {get_param: GlanceRbdPoolName} + GNOCCHI_POOL: {get_param: GnocchiRbdPoolName} ceph::profile::params::ms_bind_ipv6: {get_param: CephIPv6} nova::compute::rbd::libvirt_images_rbd_pool: {get_param: NovaRbdPoolName} cinder_rbd_pool_name: {get_param: CinderRbdPoolName} glance::backend::rbd::rbd_store_pool: {get_param: GlanceRbdPoolName} + gnocchi::storage::ceph::ceph_pool: {get_param: GnocchiRbdPoolName} + gnocchi::storage::ceph::ceph_username: {get_param: CephClientUserName} nova::compute::rbd::libvirt_rbd_user: {get_param: CephClientUserName} glance::backend::rbd::rbd_store_user: {get_param: CephClientUserName} nova::compute::rbd::rbd_keyring: @@ -88,11 +94,17 @@ resources: - '.' - - 'client' - {get_param: CephClientUserName} + gnocchi::storage::ceph::ceph_keyring: + list_join: + - '.' + - - 'client' + - {get_param: CephClientUserName} ceph_client_user_name: {get_param: CephClientUserName} ceph_pools: - {get_param: CinderRbdPoolName} - {get_param: NovaRbdPoolName} - {get_param: GlanceRbdPoolName} + - {get_param: GnocchiRbdPoolName} outputs: config_id: diff --git a/puppet/extraconfig/tls/tls-cert-inject.yaml b/puppet/extraconfig/tls/tls-cert-inject.yaml index 77b11378..e281ef51 100644 --- a/puppet/extraconfig/tls/tls-cert-inject.yaml +++ b/puppet/extraconfig/tls/tls-cert-inject.yaml @@ -63,6 +63,14 @@ resources: openssl rsa -noout -modulus -in ${cert_path} \ | openssl md5 | cut -c 10- \ > ${heat_outputs_path}.key_modulus + # We need to reload haproxy in case the certificate changed because + # puppet doesn't know the contents of the cert file. The pacemaker + # case is handled separately in a pacemaker-specific resource. + pacemaker_status=$(systemctl is-active pacemaker) + haproxy_status=$(systemctl is-active haproxy) + if [ "$pacemaker_status" != "active" -a "$haproxy_status" = "active"]; then + systemctl reload haproxy + fi ControllerTLSDeployment: type: OS::Heat::SoftwareDeployment diff --git a/puppet/hieradata/common.yaml b/puppet/hieradata/common.yaml index 46471c3b..34965959 100644 --- a/puppet/hieradata/common.yaml +++ b/puppet/hieradata/common.yaml @@ -8,6 +8,9 @@ ceilometer::agent::auth::auth_tenant_name: 'service' aodh::auth::auth_region: 'regionOne' aodh::auth::auth_tenant_name: 'service' +gnocchi::auth::auth_region: 'regionOne' +gnocchi::auth::auth_tenant_name: 'service' + nova::api::admin_tenant_name: 'service' nova::network::neutron::neutron_project_name: 'service' nova::network::neutron::neutron_username: 'neutron' diff --git a/puppet/hieradata/controller.yaml b/puppet/hieradata/controller.yaml index 8766263a..9316cf17 100644 --- a/puppet/hieradata/controller.yaml +++ b/puppet/hieradata/controller.yaml @@ -6,6 +6,16 @@ nova::consoleauth::enabled: true nova::vncproxy::enabled: true nova::scheduler::enabled: true +# gnocchi +gnocchi::db::sync::extra_opts: '--skip-storage' +gnocchi::storage::swift::swift_user: 'service:gnocchi' +gnocchi::storage::swift::swift_auth_version: 2 +gnocchi::statsd::resource_id: '0a8b55df-f90f-491c-8cb9-7cdecec6fc26' +gnocchi::statsd::user_id: '27c0d3f8-e7ee-42f0-8317-72237d1c5ae3' +gnocchi::statsd::project_id: '6c38cd8d-099a-4cb2-aecf-17be688e8616' +gnocchi::statsd::flush_delay: 10 +gnocchi::statsd::archive_policy_name: 'low' + # rabbitmq rabbitmq::delete_guest_user: false rabbitmq::wipe_db_on_cookie_change: true @@ -44,6 +54,7 @@ neutron::agents::dhcp::dhcp_delete_namespaces: True cinder::api::keystone_tenant: 'service' swift::proxy::authtoken::admin_tenant_name: 'service' ceilometer::api::keystone_tenant: 'service' +gnocchi::api::keystone_tenant: 'service' heat::keystone_tenant: 'service' sahara::admin_tenant_name: 'service' @@ -130,6 +141,7 @@ horizon::django_session_engine: 'django.contrib.sessions.backends.cache' horizon::vhost_extra_params: add_listen: false priority: 10 + access_log_format: '%a %l %u %t \"%r\" %>s %b \"%%{}{Referer}i\" \"%%{}{User-Agent}i\"' # mysql mysql::server::manage_config_file: true @@ -151,6 +163,7 @@ tripleo::loadbalancer::sahara: true tripleo::loadbalancer::swift_proxy_server: true tripleo::loadbalancer::ceilometer: true tripleo::loadbalancer::aodh: true +tripleo::loadbalancer::gnocchi: true tripleo::loadbalancer::heat_api: true tripleo::loadbalancer::heat_cloudwatch: true tripleo::loadbalancer::heat_cfn: true @@ -267,3 +280,7 @@ tripleo::firewall::firewall_rules: port: - 8042 - 13042 + '129 gnocchi-api': + port: + - 8041 + - 13041 diff --git a/puppet/hieradata/database.yaml b/puppet/hieradata/database.yaml index 61714691..4eb199c8 100644 --- a/puppet/hieradata/database.yaml +++ b/puppet/hieradata/database.yaml @@ -61,6 +61,14 @@ ceilometer::db::mysql::allowed_hosts: - '%' - "%{hiera('mysql_bind_host')}" +# Gnocchi +gnocchi::db::mysql::user: gnocchi +gnocchi::db::mysql::host: "%{hiera('mysql_virtual_ip')}" +gnocchi::db::mysql::dbname: gnocchi +gnocchi::db::mysql::allowed_hosts: + - '%' + - "%{hiera('mysql_bind_host')}" + sahara::db::mysql::user: sahara sahara::db::mysql::host: "%{hiera('mysql_virtual_ip')}" sahara::db::mysql::dbname: sahara diff --git a/puppet/manifests/overcloud_controller.pp b/puppet/manifests/overcloud_controller.pp index c6667ae6..910617fa 100644 --- a/puppet/manifests/overcloud_controller.pp +++ b/puppet/manifests/overcloud_controller.pp @@ -121,6 +121,9 @@ if hiera('step') >= 2 { include ::cinder::db::mysql include ::heat::db::mysql include ::sahara::db::mysql + if downcase(hiera('gnocchi_indexer_backend')) == 'mysql' { + include ::gnocchi::db::mysql + } if downcase(hiera('ceilometer_backend')) == 'mysql' { include ::ceilometer::db::mysql include ::aodh::db::mysql @@ -212,62 +215,6 @@ if hiera('step') >= 2 { if hiera('step') >= 4 { - include ::keystone - include ::keystone::config - include ::keystone::roles::admin - include ::keystone::endpoint - include ::keystone::wsgi::apache - - #TODO: need a cleanup-keystone-tokens.sh solution here - - file { [ '/etc/keystone/ssl', '/etc/keystone/ssl/certs', '/etc/keystone/ssl/private' ]: - ensure => 'directory', - owner => 'keystone', - group => 'keystone', - require => Package['keystone'], - } - file { '/etc/keystone/ssl/certs/signing_cert.pem': - content => hiera('keystone_signing_certificate'), - owner => 'keystone', - group => 'keystone', - notify => Service['keystone'], - require => File['/etc/keystone/ssl/certs'], - } - file { '/etc/keystone/ssl/private/signing_key.pem': - content => hiera('keystone_signing_key'), - owner => 'keystone', - group => 'keystone', - notify => Service['keystone'], - require => File['/etc/keystone/ssl/private'], - } - file { '/etc/keystone/ssl/certs/ca.pem': - content => hiera('keystone_ca_certificate'), - owner => 'keystone', - group => 'keystone', - notify => Service['keystone'], - require => File['/etc/keystone/ssl/certs'], - } - - $glance_backend = downcase(hiera('glance_backend', 'swift')) - case $glance_backend { - 'swift': { $backend_store = 'glance.store.swift.Store' } - 'file': { $backend_store = 'glance.store.filesystem.Store' } - 'rbd': { $backend_store = 'glance.store.rbd.Store' } - default: { fail('Unrecognized glance_backend parameter.') } - } - $http_store = ['glance.store.http.Store'] - $glance_store = concat($http_store, $backend_store) - - # TODO: scrubber and other additional optional features - include ::glance - include ::glance::config - class { '::glance::api': - known_stores => $glance_store, - } - include ::glance::registry - include ::glance::notify::rabbitmq - include join(['::glance::backend::', $glance_backend]) - $nova_ipv6 = hiera('nova::use_ipv6', false) if $nova_ipv6 { $memcached_servers = suffix(hiera('memcache_node_ips_v6'), ':11211') @@ -468,6 +415,7 @@ if hiera('step') >= 4 { $cinder_rbd_backend = 'tripleo_ceph' cinder::backend::rbd { $cinder_rbd_backend : + backend_host => hiera('cinder::host'), rbd_pool => hiera('cinder_rbd_pool_name'), rbd_user => hiera('ceph_client_user_name'), rbd_secret_uuid => hiera('ceph::profile::params::fsid'), @@ -613,6 +561,7 @@ if hiera('step') >= 4 { include ::ceilometer::expirer include ::ceilometer::collector include ::ceilometer::agent::auth + include ::ceilometer::dispatcher::gnocchi class { '::ceilometer::db' : database_connection => $ceilometer_database_connection, } @@ -650,6 +599,7 @@ if hiera('step') >= 4 { include ::sahara::service::engine # Horizon + include ::apache::mod::remoteip if 'cisco_n1kv' in hiera('neutron::plugins::ml2::mechanism_drivers') { $_profile_support = 'cisco' } else { @@ -669,6 +619,26 @@ if hiera('step') >= 4 { neutron_options => $neutron_options, } + # Gnocchi + $gnocchi_database_connection = hiera('gnocchi_mysql_conn_string') + class { '::gnocchi': + database_connection => $gnocchi_database_connection, + } + include ::gnocchi::api + include ::gnocchi::wsgi::apache + include ::gnocchi::client + include ::gnocchi::db::sync + include ::gnocchi::storage + include ::gnocchi::metricd + include ::gnocchi::statsd + $gnocchi_backend = downcase(hiera('gnocchi_backend', 'swift')) + case $gnocchi_backend { + 'swift': { include ::gnocchi::storage::swift } + 'file': { include ::gnocchi::storage::file } + 'rbd': { include ::gnocchi::storage::ceph } + default: { fail('Unrecognized gnocchi_backend parameter.') } + } + $snmpd_user = hiera('snmpd_readonly_user_name') snmp::snmpv3_user { $snmpd_user: authtype => 'MD5', @@ -684,14 +654,10 @@ if hiera('step') >= 4 { } #END STEP 4 if hiera('step') >= 5 { - $keystone_enable_db_purge = hiera('keystone_enable_db_purge', true) $nova_enable_db_purge = hiera('nova_enable_db_purge', true) $cinder_enable_db_purge = hiera('cinder_enable_db_purge', true) $heat_enable_db_purge = hiera('heat_enable_db_purge', true) - if $keystone_enable_db_purge { - include ::keystone::cron::token_flush - } if $nova_enable_db_purge { include ::nova::cron::archive_deleted_rows } @@ -703,7 +669,6 @@ if hiera('step') >= 5 { } if downcase(hiera('bootstrap_nodeid')) == $::hostname { - include ::keystone::roles::admin # Class ::heat::keystone::domain has to run on bootstrap node # because it creates DB entities via API calls. include ::heat::keystone::domain diff --git a/puppet/manifests/overcloud_controller_pacemaker.pp b/puppet/manifests/overcloud_controller_pacemaker.pp index 54176231..b3b6ce54 100644 --- a/puppet/manifests/overcloud_controller_pacemaker.pp +++ b/puppet/manifests/overcloud_controller_pacemaker.pp @@ -24,6 +24,7 @@ Service <| tag == 'cinder-service' or tag == 'ceilometer-service' or tag == 'glance-service' or + tag == 'gnocchi-service' or tag == 'heat-service' or tag == 'keystone-service' or tag == 'neutron-service' or @@ -254,183 +255,46 @@ if hiera('step') >= 2 { } $control_vip = hiera('tripleo::loadbalancer::controller_virtual_ip') - if is_ipv6_address($control_vip) { - $control_vip_netmask = '64' - } else { - $control_vip_netmask = '32' - } - pacemaker::resource::ip { 'control_vip': - ip_address => $control_vip, - cidr_netmask => $control_vip_netmask, - } - pacemaker::constraint::base { 'control_vip-then-haproxy': - constraint_type => 'order', - first_resource => "ip-${control_vip}", - second_resource => 'haproxy-clone', - first_action => 'start', - second_action => 'start', - constraint_params => 'kind=Optional', - require => [Pacemaker::Resource::Service['haproxy'], - Pacemaker::Resource::Ip['control_vip']], - } - pacemaker::constraint::colocation { 'control_vip-with-haproxy': - source => "ip-${control_vip}", - target => 'haproxy-clone', - score => 'INFINITY', - require => [Pacemaker::Resource::Service['haproxy'], - Pacemaker::Resource::Ip['control_vip']], + tripleo::pacemaker::haproxy_with_vip { 'haproxy_and_control_vip': + vip_name => 'control', + ip_address => $control_vip, } $public_vip = hiera('tripleo::loadbalancer::public_virtual_ip') - if is_ipv6_address($public_vip) { - $public_vip_netmask = '64' - } else { - $public_vip_netmask = '32' - } - if $public_vip and $public_vip != $control_vip { - pacemaker::resource::ip { 'public_vip': - ip_address => $public_vip, - cidr_netmask => $public_vip_netmask, - } - pacemaker::constraint::base { 'public_vip-then-haproxy': - constraint_type => 'order', - first_resource => "ip-${public_vip}", - second_resource => 'haproxy-clone', - first_action => 'start', - second_action => 'start', - constraint_params => 'kind=Optional', - require => [Pacemaker::Resource::Service['haproxy'], - Pacemaker::Resource::Ip['public_vip']], - } - pacemaker::constraint::colocation { 'public_vip-with-haproxy': - source => "ip-${public_vip}", - target => 'haproxy-clone', - score => 'INFINITY', - require => [Pacemaker::Resource::Service['haproxy'], - Pacemaker::Resource::Ip['public_vip']], - } + tripleo::pacemaker::haproxy_with_vip { 'haproxy_and_public_vip': + ensure => $public_vip and $public_vip != $control_vip, + vip_name => 'public', + ip_address => $public_vip, } $redis_vip = hiera('redis_vip') - if is_ipv6_address($redis_vip) { - $redis_vip_netmask = '64' - } else { - $redis_vip_netmask = '32' - } - if $redis_vip and $redis_vip != $control_vip { - pacemaker::resource::ip { 'redis_vip': - ip_address => $redis_vip, - cidr_netmask => $redis_vip_netmask, - } - pacemaker::constraint::base { 'redis_vip-then-haproxy': - constraint_type => 'order', - first_resource => "ip-${redis_vip}", - second_resource => 'haproxy-clone', - first_action => 'start', - second_action => 'start', - constraint_params => 'kind=Optional', - require => [Pacemaker::Resource::Service['haproxy'], - Pacemaker::Resource::Ip['redis_vip']], - } - pacemaker::constraint::colocation { 'redis_vip-with-haproxy': - source => "ip-${redis_vip}", - target => 'haproxy-clone', - score => 'INFINITY', - require => [Pacemaker::Resource::Service['haproxy'], - Pacemaker::Resource::Ip['redis_vip']], - } + tripleo::pacemaker::haproxy_with_vip { 'haproxy_and_redis_vip': + ensure => $redis_vip and $redis_vip != $control_vip, + vip_name => 'redis', + ip_address => $redis_vip, } + $internal_api_vip = hiera('tripleo::loadbalancer::internal_api_virtual_ip') - if is_ipv6_address($internal_api_vip) { - $internal_api_vip_netmask = '64' - } else { - $internal_api_vip_netmask = '32' - } - if $internal_api_vip and $internal_api_vip != $control_vip { - pacemaker::resource::ip { 'internal_api_vip': - ip_address => $internal_api_vip, - cidr_netmask => $internal_api_vip_netmask, - } - pacemaker::constraint::base { 'internal_api_vip-then-haproxy': - constraint_type => 'order', - first_resource => "ip-${internal_api_vip}", - second_resource => 'haproxy-clone', - first_action => 'start', - second_action => 'start', - constraint_params => 'kind=Optional', - require => [Pacemaker::Resource::Service['haproxy'], - Pacemaker::Resource::Ip['internal_api_vip']], - } - pacemaker::constraint::colocation { 'internal_api_vip-with-haproxy': - source => "ip-${internal_api_vip}", - target => 'haproxy-clone', - score => 'INFINITY', - require => [Pacemaker::Resource::Service['haproxy'], - Pacemaker::Resource::Ip['internal_api_vip']], - } + tripleo::pacemaker::haproxy_with_vip { 'haproxy_and_internal_api_vip': + ensure => $internal_api_vip and $internal_api_vip != $control_vip, + vip_name => 'internal_api', + ip_address => $internal_api_vip, } $storage_vip = hiera('tripleo::loadbalancer::storage_virtual_ip') - if is_ipv6_address($storage_vip) { - $storage_vip_netmask = '64' - } else { - $storage_vip_netmask = '32' - } - if $storage_vip and $storage_vip != $control_vip { - pacemaker::resource::ip { 'storage_vip': - ip_address => $storage_vip, - cidr_netmask => $storage_vip_netmask, - } - pacemaker::constraint::base { 'storage_vip-then-haproxy': - constraint_type => 'order', - first_resource => "ip-${storage_vip}", - second_resource => 'haproxy-clone', - first_action => 'start', - second_action => 'start', - constraint_params => 'kind=Optional', - require => [Pacemaker::Resource::Service['haproxy'], - Pacemaker::Resource::Ip['storage_vip']], - } - pacemaker::constraint::colocation { 'storage_vip-with-haproxy': - source => "ip-${storage_vip}", - target => 'haproxy-clone', - score => 'INFINITY', - require => [Pacemaker::Resource::Service['haproxy'], - Pacemaker::Resource::Ip['storage_vip']], - } + tripleo::pacemaker::haproxy_with_vip { 'haproxy_and_storage_vip': + ensure => $storage_vip and $storage_vip != $control_vip, + vip_name => 'storage', + ip_address => $storage_vip, } $storage_mgmt_vip = hiera('tripleo::loadbalancer::storage_mgmt_virtual_ip') - if is_ipv6_address($storage_mgmt_vip) { - $storage_mgmt_vip_netmask = '64' - } else { - $storage_mgmt_vip_netmask = '32' - } - if $storage_mgmt_vip and $storage_mgmt_vip != $control_vip { - pacemaker::resource::ip { 'storage_mgmt_vip': - ip_address => $storage_mgmt_vip, - cidr_netmask => $storage_mgmt_vip_netmask, - } - pacemaker::constraint::base { 'storage_mgmt_vip-then-haproxy': - constraint_type => 'order', - first_resource => "ip-${storage_mgmt_vip}", - second_resource => 'haproxy-clone', - first_action => 'start', - second_action => 'start', - constraint_params => 'kind=Optional', - require => [Pacemaker::Resource::Service['haproxy'], - Pacemaker::Resource::Ip['storage_mgmt_vip']], - } - pacemaker::constraint::colocation { 'storage_mgmt_vip-with-haproxy': - source => "ip-${storage_mgmt_vip}", - target => 'haproxy-clone', - score => 'INFINITY', - require => [Pacemaker::Resource::Service['haproxy'], - Pacemaker::Resource::Ip['storage_mgmt_vip']], - } + tripleo::pacemaker::haproxy_with_vip { 'haproxy_and_storage_mgmt_vip': + ensure => $storage_mgmt_vip and $storage_mgmt_vip != $control_vip, + vip_name => 'storage_mgmt', + ip_address => $storage_mgmt_vip, } - } pacemaker::resource::service { $::memcached::params::service_name : @@ -543,6 +407,11 @@ MYSQL_HOST=localhost\n", } } + if downcase(hiera('gnocchi_indexer_backend')) == 'mysql' { + class { '::gnocchi::db::mysql': + require => Exec['galera-ready'], + } + } class { '::sahara::db::mysql': require => Exec['galera-ready'], } @@ -606,81 +475,6 @@ MYSQL_HOST=localhost\n", if hiera('step') >= 4 { - class { '::keystone': - sync_db => $sync_db, - manage_service => false, - enabled => false, - enable_bootstrap => $pacemaker_master, - } - include ::keystone::config - - #TODO: need a cleanup-keystone-tokens.sh solution here - - file { [ '/etc/keystone/ssl', '/etc/keystone/ssl/certs', '/etc/keystone/ssl/private' ]: - ensure => 'directory', - owner => 'keystone', - group => 'keystone', - require => Package['keystone'], - } - file { '/etc/keystone/ssl/certs/signing_cert.pem': - content => hiera('keystone_signing_certificate'), - owner => 'keystone', - group => 'keystone', - notify => Service['keystone'], - require => File['/etc/keystone/ssl/certs'], - } - file { '/etc/keystone/ssl/private/signing_key.pem': - content => hiera('keystone_signing_key'), - owner => 'keystone', - group => 'keystone', - notify => Service['keystone'], - require => File['/etc/keystone/ssl/private'], - } - file { '/etc/keystone/ssl/certs/ca.pem': - content => hiera('keystone_ca_certificate'), - owner => 'keystone', - group => 'keystone', - notify => Service['keystone'], - require => File['/etc/keystone/ssl/certs'], - } - - $glance_backend = downcase(hiera('glance_backend', 'swift')) - case $glance_backend { - 'swift': { $backend_store = 'glance.store.swift.Store' } - 'file': { $backend_store = 'glance.store.filesystem.Store' } - 'rbd': { $backend_store = 'glance.store.rbd.Store' } - default: { fail('Unrecognized glance_backend parameter.') } - } - $http_store = ['glance.store.http.Store'] - $glance_store = concat($http_store, $backend_store) - - if $glance_backend == 'file' and hiera('glance_file_pcmk_manage', false) { - $secontext = 'context="system_u:object_r:glance_var_lib_t:s0"' - pacemaker::resource::filesystem { 'glance-fs': - device => hiera('glance_file_pcmk_device'), - directory => hiera('glance_file_pcmk_directory'), - fstype => hiera('glance_file_pcmk_fstype'), - fsoptions => join([$secontext, hiera('glance_file_pcmk_options', '')],','), - clone_params => '', - } - } - - # TODO: notifications, scrubber, etc. - include ::glance - include ::glance::config - class { '::glance::api': - known_stores => $glance_store, - manage_service => false, - enabled => false, - } - class { '::glance::registry' : - sync_db => $sync_db, - manage_service => false, - enabled => false, - } - include ::glance::notify::rabbitmq - include join(['::glance::backend::', $glance_backend]) - $nova_ipv6 = hiera('nova::use_ipv6', false) if $nova_ipv6 { $memcached_servers = suffix(hiera('memcache_node_ips_v6'), ':11211') @@ -919,6 +713,7 @@ if hiera('step') >= 4 { $cinder_rbd_backend = 'tripleo_ceph' cinder::backend::rbd { $cinder_rbd_backend : + backend_host => hiera('cinder::host'), rbd_pool => hiera('cinder_rbd_pool_name'), rbd_user => hiera('ceph_client_user_name'), rbd_secret_uuid => hiera('ceph::profile::params::fsid'), @@ -1106,6 +901,7 @@ if hiera('step') >= 4 { sync_db => $sync_db, } include ::ceilometer::agent::auth + include ::ceilometer::dispatcher::gnocchi Cron <| title == 'ceilometer-expirer' |> { command => "sleep $((\$(od -A n -t d -N 3 /dev/urandom) % 86400)) && ${::ceilometer::params::expirer_command}" } @@ -1138,7 +934,7 @@ if hiera('step') >= 4 { service_enable => false, # service_manage => false, # <-- not supported with horizon&apache mod_wsgi? } - include ::keystone::wsgi::apache + include ::apache::mod::remoteip include ::apache::mod::status if 'cisco_n1kv' in hiera('neutron::plugins::ml2::mechanism_drivers') { $_profile_support = 'cisco' @@ -1185,6 +981,40 @@ if hiera('step') >= 4 { enabled => false, } + # Gnocchi + $gnocchi_database_connection = hiera('gnocchi_mysql_conn_string') + include ::gnocchi::client + if $sync_db { + include ::gnocchi::db::sync + } + include ::gnocchi::storage + $gnocchi_backend = downcase(hiera('gnocchi_backend', 'swift')) + case $gnocchi_backend { + 'swift': { include ::gnocchi::storage::swift } + 'file': { include ::gnocchi::storage::file } + 'rbd': { include ::gnocchi::storage::ceph } + default: { fail('Unrecognized gnocchi_backend parameter.') } + } + class { '::gnocchi': + database_connection => $gnocchi_database_connection, + } + class { '::gnocchi::api' : + manage_service => false, + enabled => false, + service_name => 'httpd', + } + class { '::gnocchi::wsgi::apache' : + ssl => false, + } + class { '::gnocchi::metricd' : + manage_service => false, + enabled => false, + } + class { '::gnocchi::statsd' : + manage_service => false, + enabled => false, + } + $snmpd_user = hiera('snmpd_readonly_user_name') snmp::snmpv3_user { $snmpd_user: authtype => 'MD5', @@ -1200,14 +1030,10 @@ if hiera('step') >= 4 { } #END STEP 4 if hiera('step') >= 5 { - $keystone_enable_db_purge = hiera('keystone_enable_db_purge', true) $nova_enable_db_purge = hiera('nova_enable_db_purge', true) $cinder_enable_db_purge = hiera('cinder_enable_db_purge', true) $heat_enable_db_purge = hiera('heat_enable_db_purge', true) - if $keystone_enable_db_purge { - include ::keystone::cron::token_flush - } if $nova_enable_db_purge { include ::nova::cron::archive_deleted_rows } @@ -1220,18 +1046,6 @@ if hiera('step') >= 5 { if $pacemaker_master { - if $enable_load_balancer { - pacemaker::constraint::base { 'haproxy-then-keystone-constraint': - constraint_type => 'order', - first_resource => 'haproxy-clone', - second_resource => 'openstack-core-clone', - first_action => 'start', - second_action => 'start', - require => [Pacemaker::Resource::Service['haproxy'], - Pacemaker::Resource::Ocf['openstack-core']], - } - } - pacemaker::constraint::base { 'openstack-core-then-httpd-constraint': constraint_type => 'order', first_resource => 'openstack-core-clone', @@ -1241,15 +1055,6 @@ if hiera('step') >= 5 { require => [Pacemaker::Resource::Service[$::apache::params::service_name], Pacemaker::Resource::Ocf['openstack-core']], } - pacemaker::constraint::base { 'rabbitmq-then-keystone-constraint': - constraint_type => 'order', - first_resource => 'rabbitmq-clone', - second_resource => 'openstack-core-clone', - first_action => 'start', - second_action => 'start', - require => [Pacemaker::Resource::Ocf['rabbitmq'], - Pacemaker::Resource::Ocf['openstack-core']], - } pacemaker::constraint::base { 'memcached-then-openstack-core-constraint': constraint_type => 'order', first_resource => 'memcached-clone', @@ -1338,40 +1143,14 @@ if hiera('step') >= 5 { require => [Pacemaker::Resource::Service[$::sahara::params::api_service_name], Pacemaker::Resource::Ocf['openstack-core']], } - - # Glance - pacemaker::resource::service { $::glance::params::registry_service_name : - clone_params => 'interleave=true', - require => Pacemaker::Resource::Ocf['openstack-core'], - } - pacemaker::resource::service { $::glance::params::api_service_name : - clone_params => 'interleave=true', - } - - pacemaker::constraint::base { 'keystone-then-glance-registry-constraint': + pacemaker::constraint::base { 'sahara-api-then-sahara-engine-constraint': constraint_type => 'order', - first_resource => 'openstack-core-clone', - second_resource => "${::glance::params::registry_service_name}-clone", + first_resource => "${::sahara::params::api_service_name}-clone", + second_resource => "${::sahara::params::engine_service_name}-clone", first_action => 'start', second_action => 'start', - require => [Pacemaker::Resource::Service[$::glance::params::registry_service_name], - Pacemaker::Resource::Ocf['openstack-core']], - } - pacemaker::constraint::base { 'glance-registry-then-glance-api-constraint': - constraint_type => 'order', - first_resource => "${::glance::params::registry_service_name}-clone", - second_resource => "${::glance::params::api_service_name}-clone", - first_action => 'start', - second_action => 'start', - require => [Pacemaker::Resource::Service[$::glance::params::registry_service_name], - Pacemaker::Resource::Service[$::glance::params::api_service_name]], - } - pacemaker::constraint::colocation { 'glance-api-with-glance-registry-colocation': - source => "${::glance::params::api_service_name}-clone", - target => "${::glance::params::registry_service_name}-clone", - score => 'INFINITY', - require => [Pacemaker::Resource::Service[$::glance::params::registry_service_name], - Pacemaker::Resource::Service[$::glance::params::api_service_name]], + require => [Pacemaker::Resource::Service[$::sahara::params::api_service_name], + Pacemaker::Resource::Service[$::sahara::params::engine_service_name]], } if hiera('step') == 5 { @@ -1509,7 +1288,7 @@ if hiera('step') >= 5 { Pacemaker::Resource::Service[$::neutron::params::dhcp_agent_service]], } } - if hiera('neutron::enable_dhcp_agent',true) and hiera('l3_agent_service',true) { + if hiera('neutron::enable_dhcp_agent',true) and hiera('neutron::enable_l3_agent',true) { pacemaker::constraint::base { 'neutron-dhcp-agent-to-l3-agent-constraint': constraint_type => 'order', first_resource => "${::neutron::params::dhcp_agent_service}-clone", @@ -1742,6 +1521,15 @@ if hiera('step') >= 5 { require => [Pacemaker::Resource::Service[$::ceilometer::params::agent_central_service_name], Pacemaker::Resource::Ocf['openstack-core']], } + pacemaker::constraint::base { 'keystone-then-ceilometer-notification-constraint': + constraint_type => 'order', + first_resource => 'openstack-core-clone', + second_resource => "${::ceilometer::params::agent_notification_service_name}-clone", + first_action => 'start', + second_action => 'start', + require => [Pacemaker::Resource::Service[$::ceilometer::params::agent_central_service_name], + Pacemaker::Resource::Ocf['openstack-core']], + } pacemaker::constraint::base { 'ceilometer-central-then-ceilometer-collector-constraint': constraint_type => 'order', first_resource => "${::ceilometer::params::agent_central_service_name}-clone", @@ -1825,6 +1613,15 @@ if hiera('step') >= 5 { require => [Pacemaker::Resource::Service[$::aodh::params::evaluator_service_name], Pacemaker::Resource::Service[$::aodh::params::notifier_service_name]], } + pacemaker::constraint::base { 'aodh-evaluator-then-aodh-listener-constraint': + constraint_type => 'order', + first_resource => "${::aodh::params::evaluator_service_name}-clone", + second_resource => "${::aodh::params::listener_service_name}-clone", + first_action => 'start', + second_action => 'start', + require => [Pacemaker::Resource::Service[$::aodh::params::evaluator_service_name], + Pacemaker::Resource::Service[$::aodh::params::listener_service_name]], + } pacemaker::constraint::colocation { 'aodh-listener-with-aodh-evaluator-colocation': source => "${::aodh::params::listener_service_name}-clone", target => "${::aodh::params::evaluator_service_name}-clone", @@ -1844,6 +1641,30 @@ if hiera('step') >= 5 { } } + # gnocchi + pacemaker::resource::service { $::gnocchi::params::metricd_service_name : + clone_params => 'interleave=true', + } + pacemaker::resource::service { $::gnocchi::params::statsd_service_name : + clone_params => 'interleave=true', + } + pacemaker::constraint::base { 'gnocchi-metricd-then-gnocchi-statsd-constraint': + constraint_type => 'order', + first_resource => "${::gnocchi::params::metricd_service_name}-clone", + second_resource => "${::gnocchi::params::statsd_service_name}-clone", + first_action => 'start', + second_action => 'start', + require => [Pacemaker::Resource::Service[$::gnocchi::params::metricd_service_name], + Pacemaker::Resource::Service[$::gnocchi::params::statsd_service_name]], + } + pacemaker::constraint::colocation { 'gnocchi-statsd-with-metricd-colocation': + source => "${::gnocchi::params::statsd_service_name}-clone", + target => "${::gnocchi::params::metricd_service_name}-clone", + score => 'INFINITY', + require => [Pacemaker::Resource::Service[$::gnocchi::params::metricd_service_name], + Pacemaker::Resource::Service[$::gnocchi::params::statsd_service_name]], + } + # Heat pacemaker::resource::service { $::heat::params::api_service_name : clone_params => 'interleave=true', @@ -1857,15 +1678,6 @@ if hiera('step') >= 5 { pacemaker::resource::service { $::heat::params::engine_service_name : clone_params => 'interleave=true', } - pacemaker::constraint::base { 'keystone-then-heat-api-constraint': - constraint_type => 'order', - first_resource => 'openstack-core-clone', - second_resource => "${::heat::params::api_service_name}-clone", - first_action => 'start', - second_action => 'start', - require => [Pacemaker::Resource::Service[$::heat::params::api_service_name], - Pacemaker::Resource::Ocf['openstack-core']], - } pacemaker::constraint::base { 'heat-api-then-heat-api-cfn-constraint': constraint_type => 'order', first_resource => "${::heat::params::api_service_name}-clone", @@ -1962,29 +1774,5 @@ if hiera('step') >= 5 { } #END STEP 5 -if hiera('step') >= 6 { - - if $pacemaker_master { - - class {'::keystone::roles::admin' : - require => Pacemaker::Resource::Service[$::apache::params::service_name], - } -> - class {'::keystone::endpoint' : - require => Pacemaker::Resource::Service[$::apache::params::service_name], - } - include ::heat::keystone::domain - Class['::keystone::roles::admin'] -> Class['::heat::keystone::domain'] - - } else { - # On non-master controller we don't need to create Keystone resources again - class { '::heat::keystone::domain': - manage_domain => false, - manage_user => false, - manage_role => false, - } - } - -} #END STEP 6 - $package_manifest_name = join(['/var/lib/tripleo/installed-packages/overcloud_controller_pacemaker', hiera('step')]) package_manifest{$package_manifest_name: ensure => present} diff --git a/puppet/services/glance-api.yaml b/puppet/services/glance-api.yaml new file mode 100644 index 00000000..a1ab1a20 --- /dev/null +++ b/puppet/services/glance-api.yaml @@ -0,0 +1,93 @@ +heat_template_version: 2016-04-08 + +description: > + OpenStack Glance API service configured with Puppet + +parameters: + EndpointMap: + default: {} + description: Mapping of service endpoint -> protocol. Typically set + via parameter_defaults in the resource registry. + type: json + MysqlVirtualIPUri: + type: string + default: '' + Debug: + default: '' + description: Set to True to enable debugging on all services. + type: string + GlanceNotifierStrategy: + description: Strategy to use for Glance notification queue + type: string + default: noop + GlanceLogFile: + description: The filepath of the file to use for logging messages from Glance. + type: string + default: '' + GlancePassword: + description: The password for the glance service and db account, used by the glance services. + type: string + hidden: true + GlanceBackend: + default: swift + description: The short name of the Glance backend to use. Should be one + of swift, rbd, or file + type: string + constraints: + - allowed_values: ['swift', 'file', 'rbd'] + GlanceWorkers: + default: 0 + description: Number of workers for Glance service. + type: number + RabbitPassword: + description: The password for RabbitMQ + type: string + hidden: true + RabbitUserName: + default: guest + description: The username for RabbitMQ + type: string + RabbitClientUseSSL: + default: false + description: > + Rabbit client subscriber parameter to specify + an SSL connection to the RabbitMQ host. + type: string + +outputs: + role_data: + description: Role data for the Glance API role. + value: + config_settings: + glance_dsn: &glance_dsn + list_join: + - '' + - - 'mysql+pymysql://glance:' + - {get_param: GlancePassword} + - '@' + - {get_param: MysqlVirtualIPUri} + - '/glance' + glance::api::bind_port: {get_param: [EndpointMap, GlanceInternal, port]} + glance::api::auth_uri: {get_param: [EndpointMap, KeystoneInternal, uri] } + glance::api::identity_uri: { get_param: [EndpointMap, KeystoneAdmin, uri_no_suffix] } + glance::api::registry_host: + str_replace: + template: "'REGISTRY_HOST'" + params: + REGISTRY_HOST: {get_param: [EndpointMap, GlanceRegistryInternal, host]} + glance::api::keystone_password: {get_param: GlancePassword} + glance::api::debug: {get_param: Debug} + glance::api::workers: {get_param: GlanceWorkers} + glance_notifier_strategy: {get_param: GlanceNotifierStrategy} + glance_log_file: {get_param: GlanceLogFile} + glance::api::database_connection: *glance_dsn + glance::backend::swift::swift_store_auth_address: {get_param: [EndpointMap, KeystoneInternal, uri] } + glance::backend::swift::swift_store_user: service:glance + glance::backend::swift::swift_store_key: {get_param: GlancePassword} + glance_backend: {get_param: GlanceBackend} + glance::db::mysql::password: {get_param: GlancePassword} + glance::notify::rabbitmq::rabbit_userid: {get_param: RabbitUserName} + glance::notify::rabbitmq::rabbit_password: {get_param: RabbitPassword} + glance::notify::rabbitmq::rabbit_use_ssl: {get_param: RabbitClientUseSSL} + step_config: | + include ::tripleo::profile::base::glance::api diff --git a/puppet/services/glance-registry.yaml b/puppet/services/glance-registry.yaml new file mode 100644 index 00000000..1a1a515a --- /dev/null +++ b/puppet/services/glance-registry.yaml @@ -0,0 +1,48 @@ +heat_template_version: 2016-04-08 + +description: > + OpenStack Glance Registry service configured with Puppet + +parameters: + EndpointMap: + default: {} + description: Mapping of service endpoint -> protocol. Typically set + via parameter_defaults in the resource registry. + type: json + MysqlVirtualIPUri: + type: string + default: '' + Debug: + default: '' + description: Set to True to enable debugging on all services. + type: string + GlancePassword: + description: The password for the glance service and db account, used by the glance services. + type: string + hidden: true + GlanceWorkers: + default: 0 + description: Number of workers for Glance service. + type: number + +outputs: + role_data: + description: Role data for the Glance Registry role. + value: + config_settings: + glance_dsn: &glance_dsn + list_join: + - '' + - - 'mysql+pymysql://glance:' + - {get_param: GlancePassword} + - '@' + - {get_param: MysqlVirtualIPUri} + - '/glance' + glance::registry::keystone_password: {get_param: GlancePassword} + glance::registry::database_connection: *glance_dsn + glance::registry::auth_uri: {get_param: [EndpointMap, KeystoneInternal, uri] } + glance::registry::identity_uri: { get_param: [EndpointMap, KeystoneAdmin, uri_no_suffix] } + glance::registry::debug: {get_param: Debug} + glance::registry::workers: {get_param: GlanceWorkers} + step_config: | + include ::tripleo::profile::base::glance::registry diff --git a/puppet/services/keystone.yaml b/puppet/services/keystone.yaml new file mode 100644 index 00000000..1654f0e7 --- /dev/null +++ b/puppet/services/keystone.yaml @@ -0,0 +1,135 @@ +heat_template_version: 2016-04-08 + +description: > + OpenStack Keystone service configured with Puppet + +parameters: + KeystoneCACertificate: + default: '' + description: Keystone self-signed certificate authority certificate. + type: string + KeystoneEnableDBPurge: + default: true + description: | + Whether to create cron job for purging soft deleted rows in Keystone database. + type: boolean + KeystoneSigningCertificate: + default: '' + description: Keystone certificate for verifying token validity. + type: string + KeystoneSigningKey: + default: '' + description: Keystone key for signing tokens. + type: string + hidden: true + KeystoneSSLCertificate: + default: '' + description: Keystone certificate for verifying token validity. + type: string + KeystoneSSLCertificateKey: + default: '' + description: Keystone key for signing tokens. + type: string + hidden: true + KeystoneNotificationDriver: + description: Comma-separated list of Oslo notification drivers used by Keystone + default: ['messaging'] + type: comma_delimited_list + KeystoneNotificationFormat: + description: The Keystone notification format + default: 'basic' + type: string + constraints: + - allowed_values: [ 'basic', 'cadf' ] + KeystoneRegion: + type: string + default: 'regionOne' + description: Keystone region for endpoint + KeystoneWorkers: + default: 0 + description: Number of workers for Keystone service. + type: number + EndpointMap: + default: {} + description: Mapping of service endpoint -> protocol. Typically set + via parameter_defaults in the resource registry. + type: json + MysqlVirtualIPUri: + type: string + default: '' + Debug: + type: string + default: '' + AdminEmail: + default: 'admin@example.com' + description: The email for the keystone admin account. + type: string + hidden: true + AdminPassword: + description: The password for the keystone admin account, used for monitoring, querying neutron etc. + type: string + hidden: true + AdminToken: + description: The keystone auth secret and db password. + type: string + hidden: true + RabbitPassword: + description: The password for RabbitMQ + type: string + hidden: true + RabbitUserName: + default: guest + description: The username for RabbitMQ + type: string + RabbitClientUseSSL: + default: false + description: > + Rabbit client subscriber parameter to specify + an SSL connection to the RabbitMQ host. + type: string + RabbitClientPort: + default: 5672 + description: Set rabbit subscriber port, change this if using SSL + type: number + +outputs: + role_data: + description: Role data for the Keystone role. + value: + config_settings: + keystone_dsn: &keystone_dsn + list_join: + - '' + - - 'mysql+pymysql://keystone:' + - {get_param: AdminToken} + - '@' + - {get_param: MysqlVirtualIPUri} + - '/keystone' + keystone::database_connection: *keystone_dsn + keystone::admin_token: {get_param: AdminToken} + keystone::roles::admin::password: {get_param: AdminPassword} + keystone_ca_certificate: {get_param: KeystoneCACertificate} + keystone_signing_key: {get_param: KeystoneSigningKey} + keystone_signing_certificate: {get_param: KeystoneSigningCertificate} + keystone_ssl_certificate: {get_param: KeystoneSSLCertificate} + keystone_ssl_certificate_key: {get_param: KeystoneSSLCertificateKey} + keystone::debug: {get_param: Debug} + keystone::db::mysql::password: {get_param: AdminToken} + keystone::rabbit_userid: {get_param: RabbitUserName} + keystone::rabbit_password: {get_param: RabbitPassword} + keystone::rabbit_use_ssl: {get_param: RabbitClientUseSSL} + keystone::rabbit_port: {get_param: RabbitClientPort} + keystone::notification_driver: {get_param: KeystoneNotificationDriver} + keystone::notification_format: {get_param: KeystoneNotificationFormat} + keystone::roles::admin::email: {get_param: AdminEmail} + keystone::roles::admin::password: {get_param: AdminPassword} + keystone::endpoint::public_url: {get_param: [EndpointMap, KeystonePublic, uri_no_suffix]} + keystone::endpoint::internal_url: {get_param: [EndpointMap, KeystoneInternal, uri_no_suffix]} + keystone::endpoint::admin_url: {get_param: [EndpointMap, KeystoneAdmin, uri_no_suffix]} + keystone::endpoint::region: {get_param: KeystoneRegion} + keystone::admin_workers: {get_param: KeystoneWorkers} + keystone::public_workers: {get_param: KeystoneWorkers} + keystone_enable_db_purge: {get_param: KeystoneEnableDBPurge} + keystone::public_endpoint: {get_param: [EndpointMap, KeystonePublic, uri_no_suffix]} + step_config: | + include ::tripleo::profile::base::keystone diff --git a/puppet/services/pacemaker/glance-api.yaml b/puppet/services/pacemaker/glance-api.yaml new file mode 100644 index 00000000..815eb5bf --- /dev/null +++ b/puppet/services/pacemaker/glance-api.yaml @@ -0,0 +1,60 @@ +heat_template_version: 2016-04-08 + +description: > + OpenStack Glance API service with Pacemaker configured with Puppet. + +parameters: + EndpointMap: + default: {} + description: Mapping of service endpoint -> protocol. Typically set + via parameter_defaults in the resource registry. + type: json + MysqlVirtualIPUri: + type: string + default: '' + GlanceFilePcmkDevice: + default: '' + description: > + An exported storage device that should be mounted by Pacemaker + as Glance storage. Effective when GlanceFilePcmkManage is true. + type: string + GlanceFilePcmkFstype: + default: 'nfs' + description: > + Filesystem type for Pacemaker mount used as Glance storage. + Effective when GlanceFilePcmkManage is true. + type: string + GlanceFilePcmkManage: + default: false + description: > + Whether to make Glance file backend a mount managed by Pacemaker. + Effective when GlanceBackend is 'file'. + type: boolean + GlanceFilePcmkOptions: + default: '' + description: > + Mount options for Pacemaker mount used as Glance storage. + Effective when GlanceFilePcmkManage is true. + type: string + +resources: + + GlanceApiBase: + type: ../glance-api.yaml + properties: + EndpointMap: {get_param: EndpointMap} + MysqlVirtualIPUri: {get_param: MysqlVirtualIPUri} + +outputs: + role_data: + description: Role data for the Glance role. + value: + config_settings: + map_merge: + - get_attr: [GlanceApiBase, role_data, config_settings] + - glance_file_pcmk_device: {get_param: GlanceFilePcmkDevice} + glance_file_pcmk_fstype: {get_param: GlanceFilePcmkFstype} + glance_file_pcmk_manage: {get_param: GlanceFilePcmkManage} + glance_file_pcmk_options: {get_param: GlanceFilePcmkOptions} + step_config: | + include ::tripleo::profile::pacemaker::glance diff --git a/puppet/services/pacemaker/glance-registry.yaml b/puppet/services/pacemaker/glance-registry.yaml new file mode 100644 index 00000000..56353459 --- /dev/null +++ b/puppet/services/pacemaker/glance-registry.yaml @@ -0,0 +1,33 @@ +heat_template_version: 2016-04-08 + +description: > + OpenStack Glance Registry service with Pacemaker configured with Puppet + +parameters: + EndpointMap: + default: {} + description: Mapping of service endpoint -> protocol. Typically set + via parameter_defaults in the resource registry. + type: json + MysqlVirtualIPUri: + type: string + default: '' + +resources: + + GlanceRegistryBase: + type: ../glance-registry.yaml + properties: + EndpointMap: {get_param: EndpointMap} + MysqlVirtualIPUri: {get_param: MysqlVirtualIPUri} + +outputs: + role_data: + description: Role data for the Glance role. + value: + config_settings: + get_attr: [GlanceRegistryBase, role_data, config_settings] + # No puppet manifests since glance-registry is included in + # ::tripleo::profile::pacemaker::glance which is maintained alongside of + # pacemaker/glance-api.yaml. + step_config: diff --git a/puppet/services/pacemaker/keystone.yaml b/puppet/services/pacemaker/keystone.yaml new file mode 100644 index 00000000..8fcab15f --- /dev/null +++ b/puppet/services/pacemaker/keystone.yaml @@ -0,0 +1,34 @@ +heat_template_version: 2016-04-08 + +description: > + OpenStack Keystone service with Pacemaker configured with Puppet + +parameters: + EndpointMap: + default: {} + description: Mapping of service endpoint -> protocol. Typically set + via parameter_defaults in the resource registry. + type: json + MysqlVirtualIPUri: + type: string + default: '' + +resources: + + KeystoneServiceBase: + type: ../keystone.yaml + properties: + EndpointMap: {get_param: EndpointMap} + MysqlVirtualIPUri: {get_param: MysqlVirtualIPUri} + +outputs: + role_data: + description: Role data for the Keystone pacemaker role. + value: + config_settings: + map_merge: + - get_attr: [KeystoneServiceBase, role_data, config_settings] + #- + # custom keystone hiera goes here if we need it!? + step_config: | + include ::tripleo::profile::pacemaker::keystone diff --git a/puppet/swift-storage.yaml b/puppet/swift-storage.yaml index 8a4ea21f..296428db 100644 --- a/puppet/swift-storage.yaml +++ b/puppet/swift-storage.yaml @@ -256,6 +256,7 @@ resources: - all_nodes # provided by allNodesConfig - '"%{::osfamily}"' - common + merge_behavior: deeper datafiles: common: raw_data: {get_file: hieradata/common.yaml} @@ -337,12 +338,12 @@ outputs: str_replace: template: | PRIMARYIP PRIMARYHOST.DOMAIN PRIMARYHOST - EXTERNALIP EXTERNALHOST - INTERNAL_APIIP INTERNAL_APIHOST - STORAGEIP STORAGEHOST - STORAGE_MGMTIP STORAGE_MGMTHOST - TENANTIP TENANTHOST - MANAGEMENTIP MANAGEMENTHOST + EXTERNALIP EXTERNALHOST.DOMAIN EXTERNALHOST + INTERNAL_APIIP INTERNAL_APIHOST.DOMAIN INTERNAL_APIHOST + STORAGEIP STORAGEHOST.DOMAIN STORAGEHOST + STORAGE_MGMTIP STORAGE_MGMTHOST.DOMAIN STORAGE_MGMTHOST + TENANTIP TENANTHOST.DOMAIN TENANTHOST + MANAGEMENTIP MANAGEMENTHOST.DOMAIN MANAGEMENTHOST params: PRIMARYIP: {get_attr: [NetIpMap, net_ip_map, {get_param: [ServiceNetMap, ObjectStorageHostnameResolveNetwork]}]} DOMAIN: {get_param: CloudDomain} @@ -350,37 +351,37 @@ outputs: EXTERNALIP: {get_attr: [ExternalPort, ip_address]} EXTERNALHOST: list_join: - - '-' + - '.' - - {get_attr: [SwiftStorage, name]} - external INTERNAL_APIIP: {get_attr: [InternalApiPort, ip_address]} INTERNAL_APIHOST: list_join: - - '-' + - '.' - - {get_attr: [SwiftStorage, name]} - internalapi STORAGEIP: {get_attr: [StoragePort, ip_address]} STORAGEHOST: list_join: - - '-' + - '.' - - {get_attr: [SwiftStorage, name]} - storage STORAGE_MGMTIP: {get_attr: [StorageMgmtPort, ip_address]} STORAGE_MGMTHOST: list_join: - - '-' + - '.' - - {get_attr: [SwiftStorage, name]} - storagemgmt TENANTIP: {get_attr: [TenantPort, ip_address]} TENANTHOST: list_join: - - '-' + - '.' - - {get_attr: [SwiftStorage, name]} - tenant MANAGEMENTIP: {get_attr: [ManagementPort, ip_address]} MANAGEMENTHOST: list_join: - - '-' + - '.' - - {get_attr: [SwiftStorage, name]} - management nova_server_resource: diff --git a/puppet/vip-config.yaml b/puppet/vip-config.yaml index ebecd0cb..3e8e9182 100644 --- a/puppet/vip-config.yaml +++ b/puppet/vip-config.yaml @@ -27,6 +27,7 @@ resources: nova_metadata_vip: {get_input: nova_metadata_vip} ceilometer_api_vip: {get_input: ceilometer_api_vip} aodh_api_vip: {get_input: aodh_api_vip} + gnocchi_api_vip: {get_input: gnocchi_api_vip} heat_api_vip: {get_input: heat_api_vip} horizon_vip: {get_input: horizon_vip} redis_vip: {get_input: redis_vip} diff --git a/validation-scripts/all-nodes.sh b/validation-scripts/all-nodes.sh index 31b4d6bf..1c834e76 100644 --- a/validation-scripts/all-nodes.sh +++ b/validation-scripts/all-nodes.sh @@ -1,6 +1,25 @@ #!/bin/bash set -e +function ping_retry() { + local IP_ADDR=$1 + local TIMES=${2:-'10'} + local COUNT=0 + local PING_CMD=ping + if [[ $IP_ADDR =~ ":" ]]; then + PING_CMD=ping6 + fi + until [ $COUNT -ge $TIMES ]; do + if $PING_CMD -W 300 -c 1 $IP_ADDR &> /dev/null; then + echo "Ping to $IP_ADDR succeeded." + return 0 + fi + echo "Ping to $IP_ADDR failed. Retrying..." + COUNT=$(($COUNT + 1)) + done + return 1 +} + # For each unique remote IP (specified via Heat) we check to # see if one of the locally configured networks matches and if so we # attempt a ping test the remote network IP. @@ -9,17 +28,15 @@ function ping_controller_ips() { for REMOTE_IP in $(echo $REMOTE_IPS | sed -e "s| |\n|g" | sort -u); do if [[ $REMOTE_IP =~ ":" ]]; then networks=$(ip -6 r | grep -v default | cut -d " " -f 1 | grep -v "unreachable") - ping=ping6 else networks=$(ip r | grep -v default | cut -d " " -f 1) - ping=ping fi for LOCAL_NETWORK in $networks; do in_network=$(python -c "import ipaddr; net=ipaddr.IPNetwork('$LOCAL_NETWORK'); addr=ipaddr.IPAddress('$REMOTE_IP'); print(addr in net)") if [[ $in_network == "True" ]]; then - echo -n "Trying to ping $REMOTE_IP for local network $LOCAL_NETWORK..." + echo "Trying to ping $REMOTE_IP for local network ${LOCAL_NETWORK}." set +e - if ! $ping -W 300 -c 1 $REMOTE_IP &> /dev/null; then + if ! ping_retry $REMOTE_IP; then echo "FAILURE" echo "$REMOTE_IP is not pingable. Local Network: $LOCAL_NETWORK" >&2 exit 1 @@ -40,7 +57,7 @@ function ping_default_gateways() { set +e for GW in $DEFAULT_GW; do echo -n "Trying to ping default gateway ${GW}..." - if ! ping -c 1 $GW &> /dev/null; then + if ! ping_retry $GW; then echo "FAILURE" echo "$GW is not pingable." exit 1 |