Skip to content

Commit 6dac9aa

Browse files
authored
feat: enabled COS bucket monitoring and activity tracking by default for instances DA (#124)
1 parent a4d19cd commit 6dac9aa

File tree

4 files changed

+15
-11
lines changed

4 files changed

+15
-11
lines changed

solutions/agents/version.tf

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ terraform {
66
# Lock DA into an exact provider version - renovate automation will keep it updated
77
ibm = {
88
source = "ibm-cloud/ibm"
9-
version = "1.66.0"
9+
version = "1.67.1"
1010
}
1111
helm = {
1212
source = "hashicorp/helm"

solutions/instances/main.tf

Lines changed: 12 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -27,12 +27,6 @@ locals {
2727
cos_target_bucket_name = var.existing_at_cos_target_bucket_name != null ? var.existing_at_cos_target_bucket_name : module.cos_bucket[0].buckets[local.at_cos_target_bucket_name].bucket_name
2828
cos_target_bucket_endpoint = var.existing_at_cos_target_bucket_endpoint != null ? var.existing_at_cos_target_bucket_endpoint : module.cos_bucket[0].buckets[local.at_cos_target_bucket_name].s3_endpoint_private
2929

30-
metrics_monitoring = var.cloud_monitoring_provision || (var.existing_cloud_monitoring_crn != null) ? {
31-
usage_metrics_enabled = true
32-
request_metrics_enabled = true
33-
metrics_monitoring_crn = var.cloud_monitoring_provision ? module.observability_instance.cloud_monitoring_crn : var.existing_cloud_monitoring_crn
34-
} : null
35-
3630
bucket_config_1 = var.existing_log_archive_cos_bucket_name == null && var.log_analysis_provision == true ? {
3731
class = var.log_archive_cos_bucket_class
3832
name = local.log_archive_cos_bucket_name
@@ -238,7 +232,7 @@ module "cos_bucket" {
238232
}
239233
count = (length(coalesce(local.bucket_config_map, [])) != 0) ? 1 : 0 # no need to call COS module if consumer is using existing COS bucket
240234
source = "terraform-ibm-modules/cos/ibm//modules/buckets"
241-
version = "8.5.3"
235+
version = "8.6.2"
242236
bucket_configs = [
243237
for value in local.bucket_config_map :
244238
{
@@ -257,7 +251,17 @@ module "cos_bucket" {
257251
archive_rule = local.archive_rule
258252
expire_rule = local.expire_rule
259253
retention_rule = null
260-
metrics_monitoring = local.metrics_monitoring
254+
metrics_monitoring = {
255+
usage_metrics_enabled = true
256+
request_metrics_enabled = true
257+
# if DA is creating monitoring instance, use that. If its passing existing instance, use that. If neither, pass null, meaning metrics are sent to the instance associated to the container's location unless otherwise specified in the Metrics Router service configuration.
258+
metrics_monitoring_crn = var.cloud_monitoring_provision ? module.observability_instance.cloud_monitoring_crn : var.existing_cloud_monitoring_crn != null ? var.existing_cloud_monitoring_crn : null
259+
}
260+
activity_tracking = {
261+
read_data_events = true
262+
write_data_events = true
263+
management_events = true
264+
}
261265
}
262266
]
263267
}

solutions/instances/version.tf

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ terraform {
44
# Lock DA into an exact provider version - renovate automation will keep it updated
55
ibm = {
66
source = "ibm-cloud/ibm"
7-
version = "1.66.0"
7+
version = "1.67.1"
88
}
99
logdna = {
1010
source = "logdna/logdna"

tests/resources/main.tf

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
##############################################################################
44

55
module "landing_zone" {
6-
source = "git::https://github.com/terraform-ibm-modules/terraform-ibm-landing-zone//patterns//roks//module?ref=v5.24.7"
6+
source = "git::https://github.com/terraform-ibm-modules/terraform-ibm-landing-zone//patterns//roks//module?ref=v5.25.1"
77
region = var.region
88
prefix = var.prefix
99
tags = var.resource_tags

0 commit comments

Comments
 (0)