diff --git a/deploy/dashboard.tf b/deploy/dashboard.tf index d2cc8e7206e62dc5d2b5b3c472ecd6efd3c16bcf..38486f608acc4324533d9f224ed5a36b665dcff8 100644 --- a/deploy/dashboard.tf +++ b/deploy/dashboard.tf @@ -6,7 +6,9 @@ resource "aws_cloudwatch_dashboard" "main" { dynamodb_table_name = aws_dynamodb_table.main.name apigw_stage_name = aws_api_gateway_stage.main.stage_name apigw_name = aws_api_gateway_rest_api.main.name + api_id = aws_api_gateway_rest_api.main.id aws_region = var.aws_region + }) } diff --git a/deploy/templates/dashboards/dashboard.json.tpl b/deploy/templates/dashboards/dashboard.json.tpl index b386450a3eb09733f0caea946dcf750cb5f6e18e..26d2f69647da44ce3dc63ab4b151da0e450097ac 100644 --- a/deploy/templates/dashboards/dashboard.json.tpl +++ b/deploy/templates/dashboards/dashboard.json.tpl @@ -7,7 +7,7 @@ "x": 0, "type": "text", "properties": { - "markdown": "\n# API Gateway\n" + "markdown": "\n# API Gateway\n - [${apigw_name}/${apigw_stage_name}](https://${aws_region}.console.aws.amazon.com/apigateway/home?region=${aws_region}#/apis/${api_id}/stages/${apigw_stage_name})\n" } }, { @@ -17,7 +17,7 @@ "x": 0, "type": "text", "properties": { - "markdown": "\n# Lambdas\n" + "markdown": "\n# Lambdas \n%{for l in lambda_names} - [${l}](https://${aws_region}.console.aws.amazon.com/lambda/home?region=${aws_region}#/functions/${l}?tab=monitoring)\n%{endfor}\n" } }, { @@ -27,7 +27,7 @@ "x": 0, "type": "text", "properties": { - "markdown": "\n# DynamoDB\n" + "markdown": "\n# DynamoDB\n - [${dynamodb_table_name}](https://${aws_region}.console.aws.amazon.com/dynamodb/home?region=${aws_region}#tables:selected=${dynamodb_table_name};tab=overview)\n" } }, {