Skip to content

Commit

Permalink
make grafana dashboard optional (#209)
Browse files Browse the repository at this point in the history
* make grafana_dashboard optional

* Update variables.tf

* Update variables.tf

* Update cloudwatch.tf

* Update variables.tf

* Update CHANGELOG.md

* Update VARIABLES.md
  • Loading branch information
rjena5300 authored Nov 22, 2021
1 parent bf26972 commit 4400d5a
Show file tree
Hide file tree
Showing 5 changed files with 13 additions and 2 deletions.
4 changes: 4 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,10 @@ All notable changes to this project will be documented in this file.

The format is based on [Keep a Changelog](http://keepachangelog.com/en/1.0.0/) and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0.html).

## [6.11.3] - 2021-11-22
### Added
- make EKS & ECS dashboard optional

## [6.11.2] - 2021-11-12
### Added
- Added governance role read and tag objects permission to apiary buckets
Expand Down
1 change: 1 addition & 0 deletions VARIABLES.md
Original file line number Diff line number Diff line change
Expand Up @@ -96,6 +96,7 @@
| system\_schema\_name | Name for the internal system database | `string` | `"apiary_system"` | no |
| table\_param\_filter | A regular expression for selecting necessary table parameters for the SNS listener. If the value isn't set, then no table parameters are selected. | `string` | `""` | no |
| vpc\_id | VPC ID. | `string` | n/a | yes |
| enable\_dashboard | make EKS & ECS dashboard optional | `bool` | true | no |

### apiary_assume_roles

Expand Down
2 changes: 1 addition & 1 deletion cloudwatch.tf
Original file line number Diff line number Diff line change
Expand Up @@ -186,7 +186,7 @@ EOF
}

resource "aws_cloudwatch_dashboard" "apiary" {
count = var.hms_instance_type == "ecs" ? 1 : 0
count = var.hms_instance_type == "ecs" && var.enable_dashboard ? 1 : 0
dashboard_name = "${local.instance_alias}-${var.aws_region}"

dashboard_body = <<EOF
Expand Down
2 changes: 1 addition & 1 deletion grafana-dashboard.tf
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ data "template_file" "grafana_dashboard_data" {
}

resource "kubernetes_config_map" "grafana_dashboard" {
count = var.hms_instance_type == "k8s" ? 1 : 0
count = var.hms_instance_type == "k8s" && var.enable_dashboard ? 1 : 0
metadata {
name = "${local.instance_alias}-data-lake-dashboard"
namespace = var.dashboard_namespace
Expand Down
6 changes: 6 additions & 0 deletions variables.tf
Original file line number Diff line number Diff line change
Expand Up @@ -575,3 +575,9 @@ variable "apiary_governance_iamroles" {
type = list(string)
default = []
}

variable "enable_dashboard" {
description = "make EKS & ECS dashboard optional"
type = bool
default = true
}

0 comments on commit 4400d5a

Please sign in to comment.