Skip to content

Commit 0a9bcbb

Browse files
committed
Tweak terraform deps and outputs
1 parent b78b682 commit 0a9bcbb

File tree

2 files changed

+6
-1
lines changed

2 files changed

+6
-1
lines changed

terraform/dev/main.tf

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,11 @@ resource "aws_api_gateway_deployment" "api" {
1313
rest_api_id = "${aws_api_gateway_rest_api.hexagonal-lambda.id}"
1414
stage_name = "${var.deploy}"
1515

16+
depends_on = [
17+
"module.get-hex-endpoint",
18+
"module.post-up-endpoint",
19+
]
20+
1621
# https://medium.com/coryodaniel/til-forcing-terraform-to-deploy-a-aws-api-gateway-deployment-ed36a9f60c1a
1722
variables {
1823
deployed_at = "${timestamp()}"

terraform/dev/outputs.tf

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
output "api_url" {
2-
value = "https://${aws_api_gateway_rest_api.hexagonal-lambda.id}.execute-api.${var.region}.amazonaws.com/${aws_api_gateway_deployment.api.stage_name}"
2+
value = "${aws_api_gateway_deployment.api.invoke_url}"
33
}
44

55
output "api_id" {

0 commit comments

Comments
 (0)