[minor] Added configurable install plan approval support for AIService and AIService tenant in gitops#2233
[minor] Added configurable install plan approval support for AIService and AIService tenant in gitops#2233Sakshi-Singhroha1 wants to merge 38 commits into
Conversation
…-aiservice-install-plan-approval
mnivedithaa
left a comment
There was a problem hiding this comment.
Please cleanup the commented lines, resolve the conflicts.
Also you need to update gitops_aiservice pipeline and task changes here as well (changes done in saas-tekton)
|
|
||
|
|
||
|
|
||
| masAppsArgGroup.add_argument( |
There was a problem hiding this comment.
Is this arg required for cli?
There was a problem hiding this comment.
Yes, This accepts and validates user input.
Without this, the CLI won't recognize the --aiservice-install-plan-approval flag
| @@ -343,6 +340,11 @@ def buildCommand(self) -> str: | |||
| if self.getParam('aiservice_channel') != "": | |||
| command += f" --aiservice-channel \"{self.getParam('aiservice_channel')}\"{newline}" | |||
|
|
|||
|
|
|||
| if self.getParam('aiservice_install_plan_approval') != "": | |||
There was a problem hiding this comment.
Is this arg required for cli?
There was a problem hiding this comment.
Yes, this passes the parameter to the gitops-aiservice function.
Without this, the parameter is accepted but never used
…and updated gitops_aiservice pipeline and task
whitfiea
left a comment
There was a problem hiding this comment.
Please see comments.
Also I would expect that the aiservice-tenant would have the same setting as I thought was was now a subscription itself? I don't think it would make sense to have the aiservice as manual and the aiservice-tenant has automatic
…subscription installPlanApproval change
JIRA:
MASCORE-12745 https://jsw.ibm.com/browse/MASCORE-12745
MASCORE-13410 https://jsw.ibm.com/browse/MASCORE-13410
MASCORE-13462 https://jsw.ibm.com/browse/MASCORE-13462
MASCORE-13884 https://jsw.ibm.com/browse/MASCORE-13884
Problem: The AIService and AIService tenant operator subscription installPlanApproval fields were hardcoded as "Automatic" in the GitOps templates. This prevented users from controlling whether operator updates require manual approval or install automatically.
Requirement: Add support for configurable
AIServiceandAIService tenantinstall plan approval parameters in the CLI flow, including shell functions, generated templates, and pipeline/task parameter pass-through.Why these changes are needed:
Deployment flows need to carry install plan approval values from CLI into generated configuration
AIService and AIService tenant operator upgrade behavior must be configurable per environment
Default value
"Automatic"is needed for backward compatibilityGenerated Tekton and GitOps configuration must include these values so they reach the final Kubernetes subscription setup
What was changed:
This PR adds AIService and AIService tenant install plan approval support across CLI shell functions, generated GitOps templates, generated Tekton pipeline/task templates, and repository validation metadata.
Changes made:
File 1:
image/cli/mascli/functions/gitops_aiserviceAdded
--aiservice-install-plan-approvalto the CLI help outputAdded default value handling:
Added argument parsing:
Added the value to CLI summary output:
File 2:
image/cli/mascli/functions/gitops_aiservice_tenantAdded
--aiservice-tenant-install-plan-approvalto the CLI help outputAdded default value handling:
Added argument parsing:
Added the tenant value to CLI summary output:
File 3:
image/cli/mascli/templates/gitops/appset-configs/cluster/instance/ibm-aiservice.yaml.j2Added template rendering for AIService install plan approval:
File 4:
image/cli/mascli/templates/gitops/appset-configs/cluster/instance/ibm-aiservice-tenant.yaml.j2Added template rendering for AIService tenant install plan approval:
File 5:
tekton/src/pipelines/gitops/gitops-aiservice-pipeline.yml.j2Added pipeline parameter definition for AIService install plan approval with default value:
Added parameter pass-through to the downstream task
File 6:
tekton/src/pipelines/gitops/gitops-aiservice-tenant-pipeline.yml.j2Added pipeline parameter definition for AIService tenant install plan approval with default value:
Added parameter pass-through to the downstream task
File 7:
tekton/src/tasks/gitops/gitops-aiservice.yml.j2Added task parameter definition for AIService install plan approval with default value:
Added environment variable mapping:
File 8:
tekton/src/tasks/gitops/gitops-aiservice-tenant.yml.j2Added task parameter definition for AIService tenant install plan approval with default value:
Added environment variable mapping:
File 9:
.secrets.baselineUpdated generated baseline metadata and line references as part of repository validation
Impact:
✅ CLI accepts
--aiservice-install-plan-approval✅ CLI accepts
--aiservice-tenant-install-plan-approval✅ Generated GitOps templates include install plan approval values for AIService and AIService tenant
✅ Generated Tekton pipeline/task templates carry these parameters through the workflow
✅ Default value
"Automatic"ensures backward compatibility✅ Enables configurable operator upgrade behavior per environment
Testing performed:
CLI Testing:
✅ Validated argument parsing in AIService shell functions
✅ Validated argument parsing in AIService tenant shell functions
✅ Verified default values are applied correctly
✅ Confirmed values are shown in CLI summary output
Template Verification:
✅ Verified generated GitOps templates include AIService and AIService tenant install plan approval values
✅ Verified generated Tekton pipeline and task templates include the new parameters and mappings
Validation Results:
✅ Parameters are accepted and propagated correctly
✅ Templates render expected values
✅ Repository validation updated .secrets.baseline
Related Pull Requests:
saas-envs-starter: PR #158 - Added prompts and template parameters for install plan configuration
saas-deploy-py: PR #266 - Added schema validation for install plan approval fields
saas-tekton: PR #223 - Added Tekton pipeline support for install plan approval parameters
ibm-mas/gitops: PR #447 - Added configurable install plan approval for AIService and AIService tenant operators