Skip to content
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

support passing alert IDs to service dashboards #27

Merged
merged 3 commits into from
Dec 22, 2023

Conversation

imjasonh
Copy link
Member

This should produce full-width alert chart widgets for each alert. I might need to iterate on this with changes in tf-prober to see this all working together. It at least doesn't regress for non-alert-having services.

@imjasonh imjasonh enabled auto-merge (squash) December 21, 2023 18:22
@imjasonh imjasonh marked this pull request as draft December 21, 2023 19:35
auto-merge was automatically disabled December 21, 2023 19:35

Pull request was converted to draft

Signed-off-by: Jason Hall <jason@chainguard.dev>
@imjasonh imjasonh marked this pull request as ready for review December 21, 2023 19:57
Signed-off-by: Jason Hall <jason@chainguard.dev>
Signed-off-by: Jason Hall <jason@chainguard.dev>
@imjasonh imjasonh enabled auto-merge (squash) December 21, 2023 20:31
@@ -16,15 +16,24 @@ module "resources" {
filter = ["resource.type=\"cloud_run_revision\""]
}

module "alerts" {
source = "../sections/alerts"
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
source = "../sections/alerts"
count = var.alert != "" ? 1 : 0
source = "../sections/alerts"

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We could also consider making this a list 🤔

]
source = "../sections/layout"
sections = concat(
var.alert == "" ? [] : [module.alerts.section],
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
var.alert == "" ? [] : [module.alerts.section],
var.alert == "" ? [] : [module.alerts[0].section],

or

Suggested change
var.alert == "" ? [] : [module.alerts.section],
[for x in module.alerts : x.section],

@imjasonh imjasonh merged commit 1f49244 into chainguard-dev:main Dec 22, 2023
20 checks passed
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.

2 participants