-
Notifications
You must be signed in to change notification settings - Fork 558
misc: PR to compare the rollout chart changes for 5.1.1 #6875
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,5 +1,5 @@ | ||
| apiVersion: v1 | ||
| appVersion: "1.0" | ||
| description: A Helm chart for Kubernetes | ||
| name: reference-chart_5-1-0 | ||
| version: 5.1.0 | ||
| name: reference-chart_5-1-1 | ||
| version: 5.1.1 |
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,5 +1,5 @@ | ||
|
|
||
| # Rollout Deployment Chart - v5.0 | ||
| # Rollout Deployment Chart - v5.1 | ||
|
|
||
| ## 1. Yaml File - | ||
|
|
||
|
|
||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,15 @@ | ||
| DELETE FROM global_strategy_metadata_chart_ref_mapping | ||
| WHERE chart_ref_id IN ( | ||
| SELECT id | ||
| FROM "public"."chart_ref" | ||
| WHERE "version" = '5.1.0' | ||
| AND "location" = 'reference-chart_5-1-0' | ||
| AND "name" = 'Rollout Deployment' | ||
| ) | ||
| AND global_strategy_metadata_id IN (1, 2, 3, 4); | ||
|
|
||
| -- 2. Remove the chart reference (Parent) | ||
| DELETE FROM "public"."chart_ref" | ||
| WHERE "version" = '5.1.0' | ||
|
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. version should be '5.1.1' |
||
| AND "location" = 'reference-chart_5-1-0' | ||
|
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. location as well |
||
| AND "name" = 'Rollout Deployment'; | ||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,39 @@ | ||
| -- 1. Insert chart_ref if not exists | ||
| INSERT INTO "public"."chart_ref" ( | ||
| "location", "version", "deployment_strategy_path", | ||
| "is_default", "active", "created_on", "created_by", | ||
| "updated_on", "updated_by", "name" | ||
| ) | ||
| SELECT | ||
| 'reference-chart_5-1-1', '5.1.1', 'pipeline-values.yaml', | ||
|
Check failure on line 8 in scripts/sql/34604602_reference-5-1-1.up.sql
|
||
| 'f', 't', now(), 1, now(), 1, | ||
| 'Rollout Deployment' | ||
|
Check failure on line 10 in scripts/sql/34604602_reference-5-1-1.up.sql
|
||
| WHERE NOT EXISTS ( | ||
| SELECT 1 | ||
| FROM "public"."chart_ref" | ||
| WHERE "version" = '5.1.1' | ||
| AND "location" = 'reference-chart_5-1-1' | ||
| AND "name" = 'Rollout Deployment' | ||
| ); | ||
|
|
||
| -- 2. Insert mappings based on the chart_ref above | ||
| INSERT INTO global_strategy_metadata_chart_ref_mapping ( | ||
| "global_strategy_metadata_id", "chart_ref_id", "active", | ||
| "created_on", "created_by", "updated_on", "updated_by", "default" | ||
| ) | ||
| SELECT | ||
| m_ids.id, | ||
| cr.id, | ||
| true, now(), 1, now(), 1, | ||
| (m_ids.id = 1) | ||
| FROM | ||
| "public"."chart_ref" cr, | ||
| (VALUES (1), (2), (3), (4)) AS m_ids(id) | ||
| WHERE | ||
| cr.version = '5.1.1' AND cr.name = 'Rollout Deployment' | ||
| AND NOT EXISTS ( | ||
| SELECT 1 | ||
| FROM global_strategy_metadata_chart_ref_mapping existing | ||
| WHERE existing.global_strategy_metadata_id = m_ids.id | ||
| AND existing.chart_ref_id = cr.id | ||
| ); | ||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
version and location