From fc65e59f170405907eea0374525b898e82accd2e Mon Sep 17 00:00:00 2001 From: raagamounica Date: Mon, 10 Nov 2025 19:41:40 +0530 Subject: [PATCH 1/9] feat: Added next step url for logs agent --- solutions/fully-configurable/main.tf | 6 +++++ solutions/fully-configurable/outputs.tf | 29 +++++++++++++++++++++++++ 2 files changed, 35 insertions(+) diff --git a/solutions/fully-configurable/main.tf b/solutions/fully-configurable/main.tf index 554dd3f5..32fd4caf 100644 --- a/solutions/fully-configurable/main.tf +++ b/solutions/fully-configurable/main.tf @@ -16,6 +16,12 @@ locals { cloud_logs_instance_id = split(".", var.cloud_logs_ingress_endpoint)[0] } +module "instance_crn_parser" { + source = "terraform-ibm-modules/common-utilities/ibm//modules/crn-parser" + version = "1.2.0" + crn = var.instance_crn +} + module "trusted_profile" { count = (var.logs_agent_iam_mode == "TrustedProfile" && var.logs_agent_trusted_profile_id == null) ? 1 : 0 source = "terraform-ibm-modules/trusted-profile/ibm" diff --git a/solutions/fully-configurable/outputs.tf b/solutions/fully-configurable/outputs.tf index 586e7dd2..0430a8cf 100644 --- a/solutions/fully-configurable/outputs.tf +++ b/solutions/fully-configurable/outputs.tf @@ -3,4 +3,33 @@ ############################################################################## +############################################################################## +# Cloud automation for Logs Agent- Next Steps URLs outputs +############################################################################## + +output "next_steps_text" { + value = "Your Logs Instance Environment is ready." + description = "Next steps text" +} + +output "next_step_primary_label" { + value = "Go to Logs Instance Dashboard" + description = "Primary label" +} + +output "next_step_primary_url" { + value = "https://dashboard.${element(split(":", var.instance_crn), 5)}.logs.cloud.ibm.com/${element(split(":", var.instance_crn), 7)}" + description = "Primary URL" +} + +output "next_step_secondary_label" { + value = "Learn more about IBM Cloud logging" + description = "Secondary label" +} + +output "next_step_secondary_url" { + value = "https://cloud.ibm.com/docs/cloud-logs?topic=cloud-logs-getting-started" + description = "Secondary URL" +} + ############################################################################## From f3416e28277943efb7e0b4afd5ebdfdbf31bfd4c Mon Sep 17 00:00:00 2001 From: raagamounica Date: Mon, 10 Nov 2025 21:20:08 +0530 Subject: [PATCH 2/9] feat: Added next step url for logs agent --- solutions/fully-configurable/main.tf | 7 +------ solutions/fully-configurable/outputs.tf | 2 +- 2 files changed, 2 insertions(+), 7 deletions(-) diff --git a/solutions/fully-configurable/main.tf b/solutions/fully-configurable/main.tf index 32fd4caf..28aff830 100644 --- a/solutions/fully-configurable/main.tf +++ b/solutions/fully-configurable/main.tf @@ -14,12 +14,7 @@ locals { cluster_config_endpoint_type = var.cluster_config_endpoint_type is_vpc_cluster = var.is_vpc_cluster cloud_logs_instance_id = split(".", var.cloud_logs_ingress_endpoint)[0] -} - -module "instance_crn_parser" { - source = "terraform-ibm-modules/common-utilities/ibm//modules/crn-parser" - version = "1.2.0" - crn = var.instance_crn + region = split(".", var.cloud_logs_ingress_endpoint)[3] } module "trusted_profile" { diff --git a/solutions/fully-configurable/outputs.tf b/solutions/fully-configurable/outputs.tf index 0430a8cf..b93bdde6 100644 --- a/solutions/fully-configurable/outputs.tf +++ b/solutions/fully-configurable/outputs.tf @@ -18,7 +18,7 @@ output "next_step_primary_label" { } output "next_step_primary_url" { - value = "https://dashboard.${element(split(":", var.instance_crn), 5)}.logs.cloud.ibm.com/${element(split(":", var.instance_crn), 7)}" + value = "https://dashboard.${region}.logs.cloud.ibm.com/${cloud_logs_instance_id}" description = "Primary URL" } From c61a7a1d30e6f8f4fbfcc3aa0dd627dc506dc9ad Mon Sep 17 00:00:00 2001 From: raagamounica Date: Mon, 10 Nov 2025 23:27:41 +0530 Subject: [PATCH 3/9] feat: Added next step url for logs agent --- solutions/fully-configurable/outputs.tf | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/solutions/fully-configurable/outputs.tf b/solutions/fully-configurable/outputs.tf index b93bdde6..d8718e44 100644 --- a/solutions/fully-configurable/outputs.tf +++ b/solutions/fully-configurable/outputs.tf @@ -18,7 +18,7 @@ output "next_step_primary_label" { } output "next_step_primary_url" { - value = "https://dashboard.${region}.logs.cloud.ibm.com/${cloud_logs_instance_id}" + value = "https://dashboard.${local.region}.logs.cloud.ibm.com/${local.cloud_logs_instance_id}" description = "Primary URL" } From f94976699013e268f05ba4812994f98fcbe5845e Mon Sep 17 00:00:00 2001 From: raagamounica Date: Tue, 11 Nov 2025 10:53:52 +0530 Subject: [PATCH 4/9] feat: Added next step url for logs agent --- solutions/fully-configurable/main.tf | 2 +- solutions/fully-configurable/outputs.tf | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/solutions/fully-configurable/main.tf b/solutions/fully-configurable/main.tf index 28aff830..54de15ac 100644 --- a/solutions/fully-configurable/main.tf +++ b/solutions/fully-configurable/main.tf @@ -14,7 +14,7 @@ locals { cluster_config_endpoint_type = var.cluster_config_endpoint_type is_vpc_cluster = var.is_vpc_cluster cloud_logs_instance_id = split(".", var.cloud_logs_ingress_endpoint)[0] - region = split(".", var.cloud_logs_ingress_endpoint)[3] + region = split(".", var.cloud_logs_ingress_endpoint)[-5] } module "trusted_profile" { diff --git a/solutions/fully-configurable/outputs.tf b/solutions/fully-configurable/outputs.tf index d8718e44..cdef641e 100644 --- a/solutions/fully-configurable/outputs.tf +++ b/solutions/fully-configurable/outputs.tf @@ -28,7 +28,7 @@ output "next_step_secondary_label" { } output "next_step_secondary_url" { - value = "https://cloud.ibm.com/docs/cloud-logs?topic=cloud-logs-getting-started" + value = "https://cloud.ibm.com/docs/cloud-logs?topic=cloud-logs-agent-about#agent-about-ov" description = "Secondary URL" } From 19e20d3cd22e49b033948ff34471ad4a15465c15 Mon Sep 17 00:00:00 2001 From: raagamounica Date: Tue, 11 Nov 2025 11:20:00 +0530 Subject: [PATCH 5/9] feat: Added next step url for logs agent --- solutions/fully-configurable/main.tf | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/solutions/fully-configurable/main.tf b/solutions/fully-configurable/main.tf index 54de15ac..1585b3ae 100644 --- a/solutions/fully-configurable/main.tf +++ b/solutions/fully-configurable/main.tf @@ -14,7 +14,7 @@ locals { cluster_config_endpoint_type = var.cluster_config_endpoint_type is_vpc_cluster = var.is_vpc_cluster cloud_logs_instance_id = split(".", var.cloud_logs_ingress_endpoint)[0] - region = split(".", var.cloud_logs_ingress_endpoint)[-5] + region = regex("[a-z]+-[a-z]+", var.cloud_logs_ingress_endpoint) } module "trusted_profile" { From 54e164930a771eaa076405168e3a39525e05e7b9 Mon Sep 17 00:00:00 2001 From: mounicatellabati <78633728+mounicatellabati@users.noreply.github.com> Date: Tue, 11 Nov 2025 11:35:02 +0530 Subject: [PATCH 6/9] Modify next_step_primary_url output value Updated the primary URL output to include the dashboard path. --- solutions/fully-configurable/outputs.tf | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/solutions/fully-configurable/outputs.tf b/solutions/fully-configurable/outputs.tf index cdef641e..8a431fde 100644 --- a/solutions/fully-configurable/outputs.tf +++ b/solutions/fully-configurable/outputs.tf @@ -18,7 +18,7 @@ output "next_step_primary_label" { } output "next_step_primary_url" { - value = "https://dashboard.${local.region}.logs.cloud.ibm.com/${local.cloud_logs_instance_id}" + value = "https://dashboard.${local.region}.logs.cloud.ibm.com/${local.cloud_logs_instance_id}/#/dashboard" description = "Primary URL" } From 59a18f8f134597e014fbfabb583b7d7e6e1ab3f5 Mon Sep 17 00:00:00 2001 From: raagamounica Date: Tue, 11 Nov 2025 16:55:37 +0530 Subject: [PATCH 7/9] fix: fixed the logic to get both private endpoints --- solutions/fully-configurable/main.tf | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/solutions/fully-configurable/main.tf b/solutions/fully-configurable/main.tf index 1585b3ae..af59433e 100644 --- a/solutions/fully-configurable/main.tf +++ b/solutions/fully-configurable/main.tf @@ -14,7 +14,7 @@ locals { cluster_config_endpoint_type = var.cluster_config_endpoint_type is_vpc_cluster = var.is_vpc_cluster cloud_logs_instance_id = split(".", var.cloud_logs_ingress_endpoint)[0] - region = regex("[a-z]+-[a-z]+", var.cloud_logs_ingress_endpoint) + region = split(".", var.cloud_logs_ingress_endpoint)[index(split(".", var.cloud_logs_ingress_endpoint), "logs") - 1] } module "trusted_profile" { From 5b46bae4dda34928246e243068f2c4f924362b6e Mon Sep 17 00:00:00 2001 From: mounicatellabati <78633728+mounicatellabati@users.noreply.github.com> Date: Wed, 12 Nov 2025 09:09:33 +0530 Subject: [PATCH 8/9] fix: update proper labels and description --- solutions/fully-configurable/outputs.tf | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/solutions/fully-configurable/outputs.tf b/solutions/fully-configurable/outputs.tf index 8a431fde..228d4295 100644 --- a/solutions/fully-configurable/outputs.tf +++ b/solutions/fully-configurable/outputs.tf @@ -8,12 +8,12 @@ ############################################################################## output "next_steps_text" { - value = "Your Logs Instance Environment is ready." + value = "Your logs agent is ready to send logs to the instance." description = "Next steps text" } output "next_step_primary_label" { - value = "Go to Logs Instance Dashboard" + value = "Go to Cloud Logs dashboard" description = "Primary label" } @@ -23,12 +23,12 @@ output "next_step_primary_url" { } output "next_step_secondary_label" { - value = "Learn more about IBM Cloud logging" + value = "About the logging agent" description = "Secondary label" } output "next_step_secondary_url" { - value = "https://cloud.ibm.com/docs/cloud-logs?topic=cloud-logs-agent-about#agent-about-ov" + value = "https://cloud.ibm.com/docs/cloud-logs?topic=cloud-logs-agent-about" description = "Secondary URL" } From ad251dad75f01b509de7791fb655b9db3468b2d5 Mon Sep 17 00:00:00 2001 From: raagamounica Date: Mon, 17 Nov 2025 12:53:26 +0530 Subject: [PATCH 9/9] fix: fixed indentation errors --- solutions/fully-configurable/outputs.tf | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/solutions/fully-configurable/outputs.tf b/solutions/fully-configurable/outputs.tf index 228d4295..741d9041 100644 --- a/solutions/fully-configurable/outputs.tf +++ b/solutions/fully-configurable/outputs.tf @@ -13,7 +13,7 @@ output "next_steps_text" { } output "next_step_primary_label" { - value = "Go to Cloud Logs dashboard" + value = "Go to Cloud Logs dashboard" description = "Primary label" }