From f8a86691daa8b71c95b2f6bb34e92bd34a80703a Mon Sep 17 00:00:00 2001 From: "Gowdra, Girish" Date: Fri, 16 May 2025 19:23:14 -0700 Subject: [PATCH 1/3] update implementation and test plan --- .../cluster-orch-integrating-k8s-into-emt.md | 63 ++++++++++++++++++- 1 file changed, 61 insertions(+), 2 deletions(-) diff --git a/design-proposals/cluster-orch-integrating-k8s-into-emt.md b/design-proposals/cluster-orch-integrating-k8s-into-emt.md index 6990fe181..4d61634cc 100644 --- a/design-proposals/cluster-orch-integrating-k8s-into-emt.md +++ b/design-proposals/cluster-orch-integrating-k8s-into-emt.md @@ -310,6 +310,65 @@ Edge Microvisor Toolkit Cluster Orchestration UX/UI -## Implementation plan +## Implementation Plan [ wip ] -## Test Plan +1. **Build K3s RPM Packages**: + - Write a SPEC file for K3s and its dependencies (e.g., `k3s-selinux`). + - Integrate the SPEC file into the EMT build pipeline. + - Test the RPM build process to ensure the K3s binary and assets are correctly packaged. + +2. **Integrate K3s into EMT**: + - Create a new package list file (`k3s.json`) specifying the K3s and `k3s-selinux` packages. + - Update the EMT image configuration files to include the `k3s.json` package list. + - Modify the EMT build pipeline to embed the K3s version into the `manifest.json` file. + +3. **Update Cluster Manager**: + - Implement logic to filter cluster templates based on the Kubernetes version embedded in the EMT image. + - Add support for the `airGapped` configuration in the Cluster Manager API for K3s on EMT. + +4. **Update CAPINTEL Provider**: + - Modify CAPINTEL to handle the new workflows for cluster creation, deletion. + - Implement safeguards to block incompatible EMT image upgrades. + +5. **Update UI/UX**: + - Add a toggle for `Create Cluster Automatically` during host registration. + - Update the UI to filter cluster templates based on the selected OS profile. + +6. **Documentation**: + - Update user documentation to reflect the new workflows and limitations. + - Provide examples for configuring `airGapped` and using the new features. + +7. **Testing and Validation**: + - Perform end-to-end testing for all workflows (automatic/manual cluster creation, deletion, and upgrades). + - Validate compatibility checks between EMT images and cluster templates. + +## Test Plan [ wip ] + +1. **Unit Tests**: + - Test the SPEC file to ensure correct RPM packaging of K3s and its dependencies. + - Validate the logic for filtering cluster templates based on Kubernetes versions. + +2. **Integration Tests**: + - Test the EMT build pipeline to ensure K3s is correctly embedded in the image. + - Verify that the `airGapped` configuration works as expected during cluster creation. + +3. **End-to-End Tests**: + - Test automatic cluster creation during host registration. + - Test manual cluster creation with compatible and incompatible EMT images. + - Test cluster deletion and ensure proper cleanup of Kubernetes configurations. + +4. **Upgrade Tests**: + - Test upgrading the EMT image with a new K3s version. + - Validate safeguards to block incompatible EMT image upgrades. + +5. **UI/UX Tests**: + - Verify the new toggle for `Create Cluster Automatically` works as expected. + - Ensure the UI correctly filters cluster templates based on OS profiles. + +6. **Performance Tests**: + - Measure cluster creation times for K3s on EMT and compare them to existing setups. + - Test the scalability of automatic cluster creation for bulk host registration. + +7. **Regression Tests**: + - Ensure existing workflows for K3s on Ubuntu and RKE2 on EMT/Ubuntu remain unaffected. + - Validate that multi-node cluster workflows are not disrupted. From 7f5991ae6239c0f7b1683be19e08a80d3e7002d2 Mon Sep 17 00:00:00 2001 From: "Gowdra, Girish" Date: Mon, 19 May 2025 16:04:55 -0700 Subject: [PATCH 2/3] update implementation and test plan --- .../cluster-orch-integrating-k8s-into-emt.md | 63 +++++++++---------- 1 file changed, 30 insertions(+), 33 deletions(-) diff --git a/design-proposals/cluster-orch-integrating-k8s-into-emt.md b/design-proposals/cluster-orch-integrating-k8s-into-emt.md index 4d61634cc..9facd7d75 100644 --- a/design-proposals/cluster-orch-integrating-k8s-into-emt.md +++ b/design-proposals/cluster-orch-integrating-k8s-into-emt.md @@ -310,65 +310,62 @@ Edge Microvisor Toolkit Cluster Orchestration UX/UI -## Implementation Plan [ wip ] +## Implementation Plan -1. **Build K3s RPM Packages**: - - Write a SPEC file for K3s and its dependencies (e.g., `k3s-selinux`). - - Integrate the SPEC file into the EMT build pipeline. - - Test the RPM build process to ensure the K3s binary and assets are correctly packaged. +1. **Build and Package K3s** + - Develop a SPEC file for K3s and its dependencies (e.g., `k3s-selinux`). + - Integrate the SPEC file into the EMT build pipeline and test the RPM build process to ensure correct packaging. -2. **Integrate K3s into EMT**: - - Create a new package list file (`k3s.json`) specifying the K3s and `k3s-selinux` packages. - - Update the EMT image configuration files to include the `k3s.json` package list. - - Modify the EMT build pipeline to embed the K3s version into the `manifest.json` file. +2. **Embed K3s into EMT** + - Create a package list file (`k3s.json`) specifying K3s packages and update EMT image configurations to include it. + - Modify the EMT build pipeline to embed K3s version information into the `manifest.json` file. -3. **Update Cluster Manager**: - - Implement logic to filter cluster templates based on the Kubernetes version embedded in the EMT image. +3. **Cluster Manager Enhancements** + - Implement logic to filter cluster templates based on the Kubernetes version embedded in EMT images. - Add support for the `airGapped` configuration in the Cluster Manager API for K3s on EMT. -4. **Update CAPINTEL Provider**: - - Modify CAPINTEL to handle the new workflows for cluster creation, deletion. +4. **CAPINTEL Provider Updates** + - Modify CAPINTEL to handle new workflows for cluster creation and deletion. - Implement safeguards to block incompatible EMT image upgrades. -5. **Update UI/UX**: +5. **UI/UX Improvements** - Add a toggle for `Create Cluster Automatically` during host registration. - Update the UI to filter cluster templates based on the selected OS profile. -6. **Documentation**: - - Update user documentation to reflect the new workflows and limitations. - - Provide examples for configuring `airGapped` and using the new features. +6. **Documentation** + - Update user documentation to reflect new workflows and limitations. + - Provide examples for configuring `airGapped` and using new features. -7. **Testing and Validation**: - - Perform end-to-end testing for all workflows (automatic/manual cluster creation, deletion, and upgrades). +7. **Testing and Validation** + - Conduct comprehensive testing for all workflows, including automatic/manual cluster creation, deletion, and upgrades. - Validate compatibility checks between EMT images and cluster templates. -## Test Plan [ wip ] +## Test Plan -1. **Unit Tests**: - - Test the SPEC file to ensure correct RPM packaging of K3s and its dependencies. - - Validate the logic for filtering cluster templates based on Kubernetes versions. +1. **Unit Tests** + - Test the SPEC file for correct RPM packaging of K3s and dependencies. + - Validate logic for filtering cluster templates based on Kubernetes versions. -2. **Integration Tests**: +2. **Integration Tests** - Test the EMT build pipeline to ensure K3s is correctly embedded in the image. - - Verify that the `airGapped` configuration works as expected during cluster creation. + - Verify the `airGapped` configuration during cluster creation. -3. **End-to-End Tests**: +3. **End-to-End Tests** - Test automatic cluster creation during host registration. - Test manual cluster creation with compatible and incompatible EMT images. - Test cluster deletion and ensure proper cleanup of Kubernetes configurations. -4. **Upgrade Tests**: +4. **Upgrade Tests** - Test upgrading the EMT image with a new K3s version. - Validate safeguards to block incompatible EMT image upgrades. -5. **UI/UX Tests**: - - Verify the new toggle for `Create Cluster Automatically` works as expected. +5. **UI/UX Tests** + - Verify the functionality of the `Create Cluster Automatically` toggle. - Ensure the UI correctly filters cluster templates based on OS profiles. -6. **Performance Tests**: +6. **Performance Tests** - Measure cluster creation times for K3s on EMT and compare them to existing setups. - - Test the scalability of automatic cluster creation for bulk host registration. + - Test scalability of automatic cluster creation for bulk host registration. -7. **Regression Tests**: +7. **Regression Tests** - Ensure existing workflows for K3s on Ubuntu and RKE2 on EMT/Ubuntu remain unaffected. - - Validate that multi-node cluster workflows are not disrupted. From 4c0447003e364027531270859944657b12b7c6bd Mon Sep 17 00:00:00 2001 From: "Gowdra, Girish" Date: Mon, 19 May 2025 17:02:55 -0700 Subject: [PATCH 3/3] update implementation and test plan --- .../cluster-orch-integrating-k8s-into-emt.md | 106 +++++++++++------- 1 file changed, 66 insertions(+), 40 deletions(-) diff --git a/design-proposals/cluster-orch-integrating-k8s-into-emt.md b/design-proposals/cluster-orch-integrating-k8s-into-emt.md index 9facd7d75..6cee56a6d 100644 --- a/design-proposals/cluster-orch-integrating-k8s-into-emt.md +++ b/design-proposals/cluster-orch-integrating-k8s-into-emt.md @@ -306,66 +306,92 @@ It is important to note that Kubernetes version upgrades, including those for K3 ## Affected components and Teams -Edge Microvisor Toolkit -Cluster Orchestration +Edge Microvisor Toolkit (EMT) +Cluster Orchestration (CO) UX/UI -## Implementation Plan +## Phase 1 + +### Implementation Plan: Foundation and Initial Functionality 1. **Build and Package K3s** - - Develop a SPEC file for K3s and its dependencies (e.g., `k3s-selinux`). - - Integrate the SPEC file into the EMT build pipeline and test the RPM build process to ensure correct packaging. +- Develop the SPEC file for K3s and its dependencies. +- Integrate the SPEC file into the EMT build pipeline. +- Test the RPM build process to ensure correct packaging. 2. **Embed K3s into EMT** - - Create a package list file (`k3s.json`) specifying K3s packages and update EMT image configurations to include it. - - Modify the EMT build pipeline to embed K3s version information into the `manifest.json` file. +- Create the package list file (`k3s.json`) specifying K3s packages. +- Update EMT image configurations to include the `k3s.json` package list. +- Modify the EMT build pipeline to embed K3s version information into the `manifest.json` file. 3. **Cluster Manager Enhancements** - - Implement logic to filter cluster templates based on the Kubernetes version embedded in EMT images. - - Add support for the `airGapped` configuration in the Cluster Manager API for K3s on EMT. +- Implement logic to filter cluster templates based on the Kubernetes version embedded in EMT images. +- Add support for the `airGapped` configuration in the Cluster Manager API for K3s on EMT. 4. **CAPINTEL Provider Updates** - - Modify CAPINTEL to handle new workflows for cluster creation and deletion. - - Implement safeguards to block incompatible EMT image upgrades. +- Modify CAPINTEL to handle new workflows for cluster creation and deletion. +- Implement safeguards to block incompatible EMT image upgrades. 5. **UI/UX Improvements** - - Add a toggle for `Create Cluster Automatically` during host registration. - - Update the UI to filter cluster templates based on the selected OS profile. - -6. **Documentation** - - Update user documentation to reflect new workflows and limitations. - - Provide examples for configuring `airGapped` and using new features. +- Add a toggle for `Create Cluster Automatically` during host registration. +- Update the UI to filter cluster templates based on the selected OS profile. -7. **Testing and Validation** - - Conduct comprehensive testing for all workflows, including automatic/manual cluster creation, deletion, and upgrades. - - Validate compatibility checks between EMT images and cluster templates. - -## Test Plan +### Test Plan 1. **Unit Tests** - - Test the SPEC file for correct RPM packaging of K3s and dependencies. - - Validate logic for filtering cluster templates based on Kubernetes versions. +- Test the SPEC file for correct RPM packaging of K3s and dependencies. 2. **Integration Tests** - - Test the EMT build pipeline to ensure K3s is correctly embedded in the image. - - Verify the `airGapped` configuration during cluster creation. +- Test the EMT build pipeline to ensure K3s is correctly embedded in the image. 3. **End-to-End Tests** - - Test automatic cluster creation during host registration. - - Test manual cluster creation with compatible and incompatible EMT images. - - Test cluster deletion and ensure proper cleanup of Kubernetes configurations. +- Test automatic cluster creation during host registration. +- Validate logic for filtering cluster templates based on Kubernetes versions. + +### Goals +- Achieve a working integration of K3s into EMT with basic functionality. +- Ensure most of the development is completed in the first phase for CO, UI and EMT. +- Ensure documentation is updated to guide users through new workflows. + +## Phase 2 + +### Implementation plan: Enhancements and Optimization + +We expect most of the implementation to be completed in the first phase. The second phase will focus on refining the +user experience and optimizing workflows based on feedback from the first phase. + +The documentation shall be updated to reflect the new workflows and limitations introduced by this design change. +The following updates are planned: +- Update user documentation to reflect new workflows and limitations. +- Update EMT and EMT-S documentation to include K3s integration details. + + +### Test Plan + +1. **Integration Tests** +- Verify the `airGapped` configuration during cluster creation. + +2. **End-to-End Tests** +- Test manual cluster creation with compatible and incompatible EMT images. +- Test cluster deletion and ensure proper cleanup of Kubernetes configurations. + +3. **Upgrade Tests** +- Test upgrading the EMT image with a new K3s version. +- Validate safeguards to block incompatible EMT image upgrades. -4. **Upgrade Tests** - - Test upgrading the EMT image with a new K3s version. - - Validate safeguards to block incompatible EMT image upgrades. +4. **UI/UX Tests** +- Verify the functionality of the `Create Cluster Automatically` toggle. +- Ensure the UI correctly filters cluster templates based on OS profiles. -5. **UI/UX Tests** - - Verify the functionality of the `Create Cluster Automatically` toggle. - - Ensure the UI correctly filters cluster templates based on OS profiles. +5. **Performance Tests** +- Measure cluster creation times for K3s on EMT and compare them to existing setups. +- Test scalability of automatic cluster creation for bulk host registration. -6. **Performance Tests** - - Measure cluster creation times for K3s on EMT and compare them to existing setups. - - Test scalability of automatic cluster creation for bulk host registration. +6. **Regression Tests** +- Ensure existing workflows for K3s on Ubuntu and RKE2 on EMT/Ubuntu remain unaffected. +- Validate that multi-node cluster workflows are not disrupted. -7. **Regression Tests** - - Ensure existing workflows for K3s on Ubuntu and RKE2 on EMT/Ubuntu remain unaffected. +### Goals +- Enhance functionality and optimize workflows based on feedback from Sprint 1. +- Implement additional features and safeguards to improve reliability and user experience. +- Conduct comprehensive testing to ensure robustness and scalability.