Skip to content

[patch] Pass db2u_kind to mas-update PipelineRun (MASISMIG-79074) - #526

Open
ankit-bhadoriya wants to merge 1 commit into
stablefrom
masismig-79074
Open

ankit-bhadoriya wants to merge 1 commit into
stablefrom
masismig-79074

Conversation

@ankit-bhadoriya

@ankit-bhadoriya ankit-bhadoriya commented Oct 14, 2026 •

Copy link
Copy Markdown

Summary

The pipelinerun-update.yml.j2 template did not emit the db2u_kind parameter,
so even though the CLI correctly detected the deployment type and set db2u_kind,
the value was silently dropped before reaching the mas-devops-db2 task. The Ansible
role then defaulted to db2ucluster and failed with DB2U_KIND MISMATCH DETECTED!
on environments using existing Db2uInstance deployments.

Root Cause

pipelinerun-update.yml.j2 had no block to render db2u_kind into the PipelineRun
params. pipelinerun-install.yml.j2 already handles it correctly — this brings the
update template to parity.

Changes

  • src/mas/devops/templates/pipelinerun-update.yml.j2 — render db2u_kind inside
    the Db2 update block when provided, omit when empty (safe for existing callers)
  • test/src/test_tekton_update.py — 4 new unit tests for launchUpdatePipeline():
    • db2u_kind=db2uinstance is rendered into PipelineRun params
    • db2u_kind=db2ucluster is rendered into PipelineRun params
    • db2u_kind is omitted when not provided (existing callers unaffected)
    • db2u_kind is omitted when empty string

Testing

  • Unit tests: 11/11 passed (test_tekton_update.py)
unit test
  • End-to-end: Cluster with Db2uInstance on v11.5.9.0, updated to v9-260902-amd64
    (Db2 v12). With this fix applied, update-db2 task passed successfully and Db2
    upgraded to v12.
DB2U updated

Related

  • Companion PR in ibm-mas/cli: branch masismig-79074
  • Jira: MASISMIG-79074

The pipelinerun-update template did not emit db2u_kind, so the mas-update
pipeline could never forward it to the mas-devops-db2 task. For existing
Db2uInstance deployments the db2 role then defaulted to db2ucluster and failed
with DB2U_KIND MISMATCH DETECTED during the Db2 v11 to v12 upgrade.

Render db2u_kind inside the Db2 update block when it is provided, matching how
pipelinerun-install already handles it. Omitted when empty so existing callers
are unaffected.
@ankit-bhadoriya ankit-bhadoriya self-assigned this Oct 14, 2026
@ankit-bhadoriya
ankit-bhadoriya marked this pull request as ready for review October 14, 2026 12:19
@ankit-bhadoriya
ankit-bhadoriya requested a review from a team as a code owner October 14, 2026 12:19

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant