Skip to content

Commit 8e053e7

Browse files
committed
Updated schema
1 parent c4185bc commit 8e053e7

File tree

8 files changed

+406
-335
lines changed

8 files changed

+406
-335
lines changed

db/migrations/00008_chart_versions.up.sql

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,8 @@ CREATE TABLE chart_versions (
99
repo text DEFAULT NULL,
1010
version text DEFAULT NULL,
1111
chart_store jsonb NOT NULL DEFAULT '{}',
12-
application_id text REFERENCES applications(id) ON DELETE CASCADE
12+
application_id text REFERENCES applications(id) ON DELETE CASCADE,
13+
lifecycle_id text REFERENCES lifecycles(id) ON DELETE CASCADE
1314
);
1415

1516
CREATE TRIGGER chart_versions_updated_at

pkg/pb/cmdb.pb.atlas.query.validate.go

Lines changed: 8 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

pkg/pb/cmdb.pb.atlas.validate.go

Lines changed: 15 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

pkg/pb/cmdb.pb.go

Lines changed: 343 additions & 333 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

pkg/pb/cmdb.pb.gorm.go

Lines changed: 21 additions & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

pkg/pb/cmdb.pb.validate.go

Lines changed: 10 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

pkg/pb/cmdb.proto

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -603,6 +603,9 @@ message ChartVersion {
603603

604604
// Reference to Application
605605
atlas.rpc.Identifier application_id = 7 [(gorm.field) = {reference_of: "Application", tag: {type: "UUID"}}];
606+
607+
// Reference to Application Instance
608+
atlas.rpc.Identifier lifecycle_id = 8 [(gorm.field) = {reference_of: "Lifecycle", tag: {type: "UUID"}}];
606609
}
607610

608611
message CreateChartVersionRequest {

pkg/pb/cmdb.swagger.json

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2650,6 +2650,10 @@
26502650
"type": "string",
26512651
"readOnly": true
26522652
},
2653+
"lifecycle_id": {
2654+
"description": "The resource identifier.",
2655+
"type": "string"
2656+
},
26532657
"name": {
26542658
"type": "string",
26552659
"title": "The name of the ChartVersion"

0 commit comments

Comments
 (0)