From d41972e62de88b54f74e15838701de72d4fd921d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?C=C3=A9dric=20Jeanneret?= Date: Fri, 30 Aug 2024 08:29:17 +0200 Subject: [PATCH] Introduce "adoption" snippet in the automation file For adoption, there's a need to override the infra exposed by the scenario. While this new "adoption" entry creates a stronger link with the ci-framework, it can also be consumed by any other tool, as long as it knows how to consume the two "patches". This is part of a PoC, and will probably lead to discussions regarding the best way to manage all of the datasets. --- .ci/automation-schema.yaml | 9 ++++- automation/vars/hci.yaml | 75 ++++++++++++++++++++++++++++++++++++++ 2 files changed, 83 insertions(+), 1 deletion(-) diff --git a/.ci/automation-schema.yaml b/.ci/automation-schema.yaml index 415e12a3c..123db7524 100644 --- a/.ci/automation-schema.yaml +++ b/.ci/automation-schema.yaml @@ -5,9 +5,10 @@ # https://github.com/23andMe/Yamale --- vas: map(include('_architecture'), key=str()) +adoption: map(include('_adoption'), key=str(), max=1, required=False) --- -# Define various nested types +# Define VA/DT various nested types _values: name: str() src_file: str() @@ -33,3 +34,9 @@ _stage: --- _architecture: stages: list(include('_stage'), min=1) + +# Define adoption nested types +--- +_adoption: + layout_patch: map(key=str(), required=False) + networking_mapper_patch: map(key=str(), required=False) diff --git a/automation/vars/hci.yaml b/automation/vars/hci.yaml index 7449b72b3..20008bb9a 100644 --- a/automation/vars/hci.yaml +++ b/automation/vars/hci.yaml @@ -76,3 +76,78 @@ vas: - name: edpm-deployment-values-post-ceph src_file: values.yaml build_output: deployment-post-ceph.yaml + +# Adoption related content for adoption +adoption: + hci: + layout_patch: + vms: + # Let's remove the default computes, since we want to adopt the + # OSP ones + compute: + amount: 0 + osp-undercloud: + amount: 1 + disk_file_name: rhel-8.10.qcow2 + image_local_dir: "{{ cifmw_basedir }}/images/" + image_url: "{{ cifmw_discovered_image_url }}" + sha256_image_name: "{{ cifmw_discovered_hash }}" + memory: 16 + cpus: 8 + disksize: 80 + nets: + - ocpbm + - osp_trunk + osp-controller: + amount: 3 + disk_file_name: rhel-8.10.qcow2 + image_local_dir: "{{ cifmw_basedir }}/images/" + image_url: "{{ cifmw_discovered_image_url }}" + sha256_image_name: "{{ cifmw_discovered_hash }}" + memory: 16 + cpus: 8 + disksize: 80 + nets: + - ocpbm + - osp_trunk + osp-compute: + amount: 3 + disk_file_name: rhel-8.10.qcow2 + image_local_dir: "{{ cifmw_basedir }}/images/" + image_url: "{{ cifmw_discovered_image_url }}" + sha256_image_name: "{{ cifmw_discovered_hash }}" + memory: 4 + cpus: 4 + disksize: 20 + nets: + - ocpbm + - osp_trunk + networking_mapper_patch: + group-templates: + osp-controllers: + network-template: + range: + start: 200 + length: 3 + networks: &osp_nets + ctlplane: {} + internalapi: + trunk-parent: ctlplane + tenant: + trunk-parent: ctlplane + storage: + trunk-parent: ctlplane + storagemgmt: + trunk-parent: ctlplane + osp-computes: + network-template: + range: + start: 210 + length: 3 + networks: *osp_nets + osp-underclouds: + network-template: + range: + start: 199 + length: 1 + networks: *osp_nets