From afc0d39dc2dd32ba602aaabebe7e398b2d5c82b9 Mon Sep 17 00:00:00 2001 From: Bogdan Dobrelya Date: Wed, 16 Jun 2021 11:19:42 +0200 Subject: [PATCH] Add Ephemeral Heat service Adds a ephemeral heat service that ensures the containers are fetched on the system and tagged specially for usage later with the overcloud deployment process. After the service deploys, the following container images should be available on the local system. localhost/tripleo/openstack-heat-all:ephemeral localhost/tripleo/openstack-heat-engine:ephemeral localhost/tripleo/openstack-heat-api:ephemeral Depends-On: https://review.opendev.org/c/openstack/tripleo-common/+/796614 Partial-Bug: #1931995 Change-Id: I923856c83c14eb54073684ace93e9e1e85f53329 Signed-off-by: Bogdan Dobrelya Co-Authored-By: Alex Schultz Signed-off-by: Alex Schultz --- .../heat-ephemeral-container-ansible.yaml | 74 +++++++++++++++++++ environments/undercloud.yaml | 2 + overcloud-resource-registry-puppet.j2.yaml | 1 + roles/Undercloud.yaml | 1 + roles_data_undercloud.yaml | 1 + 5 files changed, 79 insertions(+) create mode 100644 deployment/heat/heat-ephemeral-container-ansible.yaml diff --git a/deployment/heat/heat-ephemeral-container-ansible.yaml b/deployment/heat/heat-ephemeral-container-ansible.yaml new file mode 100644 index 0000000000..a2a5827769 --- /dev/null +++ b/deployment/heat/heat-ephemeral-container-ansible.yaml @@ -0,0 +1,74 @@ +heat_template_version: wallaby + +description: > + Openstack Heat Ephemeral service, provides nothing but container images + +parameters: + ContainerHeatAllImage: + description: The container image to use for heat-all + type: string + ContainerHeatEngineImage: + description: image + type: string + ContainerHeatConfigImage: + description: The container image to use for the heat config_volume + type: string + ContainerHeatApiImage: + description: image + type: string + ContainerHeatApiConfigImage: + description: The container image to use for the heat_api config_volume + type: string + ServiceData: + default: {} + description: Dictionary packing service data + type: json + ServiceNetMap: + default: {} + description: Mapping of service_name -> network name. Typically set + via parameter_defaults in the resource registry. Use + parameter_merge_strategies to merge it with the defaults. + type: json + RoleName: + default: '' + description: Role name on which the service is applied + type: string + RoleParameters: + default: {} + description: Parameters specific to the role + type: json + EndpointMap: + default: {} + description: Mapping of service endpoint -> protocol. Typically set + via parameter_defaults in the resource registry. + type: json + +outputs: + role_data: + description: Role data for the Heat Ephemeral + value: + service_name: heat_ephemeral + upgrade_tasks: [] + deploy_steps_tasks: + - name: Tag Ephemeral Heat Containers for Overcloud Deploy + when: + - step|int == 5 + block: + - name: Tag Heat All image + import_role: + name: tripleo_container_tag + vars: + container_image: {get_param: ContainerHeatAllImage} + container_image_latest: "localhost/tripleo/openstack-heat-all:ephemeral" + - name: Tag Heat Engine image + import_role: + name: tripleo_container_tag + vars: + container_image: {get_param: ContainerHeatEngineImage} + container_image_latest: "localhost/tripleo/openstack-heat-engine:ephemeral" + - name: Tag Heat Api image + import_role: + name: tripleo_container_tag + vars: + container_image: {get_param: ContainerHeatApiImage} + container_image_latest: "localhost/tripleo/openstack-heat-api:ephemeral" diff --git a/environments/undercloud.yaml b/environments/undercloud.yaml index af87be3ac8..710f292d8e 100644 --- a/environments/undercloud.yaml +++ b/environments/undercloud.yaml @@ -16,6 +16,8 @@ resource_registry: OS::TripleO::Services::OpenStackClients: ../deployment/clients/openstack-clients-baremetal-ansible.yaml + OS::TripleO::Services::HeatEphemeral: ../deployment/heat/heat-ephemeral-container-ansible.yaml + # services we disable by default on the undercloud OS::TripleO::Services::AodhApi: OS::Heat::None OS::TripleO::Services::AodhEvaluator: OS::Heat::None diff --git a/overcloud-resource-registry-puppet.j2.yaml b/overcloud-resource-registry-puppet.j2.yaml index 4022e2c2d5..35eb766ea6 100644 --- a/overcloud-resource-registry-puppet.j2.yaml +++ b/overcloud-resource-registry-puppet.j2.yaml @@ -132,6 +132,7 @@ resource_registry: OS::TripleO::Services::HeatApiCfn: deployment/heat/heat-api-cfn-container-puppet.yaml OS::TripleO::Services::HeatApiCloudwatch: deployment/heat/heat-api-cloudwatch-disabled-puppet.yaml OS::TripleO::Services::HeatEngine: deployment/heat/heat-engine-container-puppet.yaml + OS::TripleO::Services::HeatEphemeral: OS::Heat::None OS::TripleO::Services::Kernel: deployment/kernel/kernel-baremetal-ansible.yaml OS::TripleO::Services::MySQL: deployment/database/mysql-pacemaker-puppet.yaml OS::TripleO::Services::NeutronBgpVpnApi: OS::Heat::None diff --git a/roles/Undercloud.yaml b/roles/Undercloud.yaml index e4291e3a4a..0178db516a 100644 --- a/roles/Undercloud.yaml +++ b/roles/Undercloud.yaml @@ -47,6 +47,7 @@ - OS::TripleO::Services::HeatApi - OS::TripleO::Services::HeatApiCfn - OS::TripleO::Services::HeatEngine + - OS::TripleO::Services::HeatEphemeral - OS::TripleO::Services::UndercloudTLS - OS::TripleO::Services::UndercloudRemoveNovajoin - OS::TripleO::Services::IronicApi diff --git a/roles_data_undercloud.yaml b/roles_data_undercloud.yaml index 2973b26d1b..f26856225b 100644 --- a/roles_data_undercloud.yaml +++ b/roles_data_undercloud.yaml @@ -50,6 +50,7 @@ - OS::TripleO::Services::HeatApi - OS::TripleO::Services::HeatApiCfn - OS::TripleO::Services::HeatEngine + - OS::TripleO::Services::HeatEphemeral - OS::TripleO::Services::UndercloudTLS - OS::TripleO::Services::UndercloudRemoveNovajoin - OS::TripleO::Services::IronicApi