I hereby claim:
- I am mhmdio on github.
- I am mhmd (https://keybase.io/mhmd) on keybase.
- I have a public key ASCqGWDrWbbWJ47Gf9xaAyhHJpKQZzM8ikv93ev2ZR3glgo
To claim this, I am signing this object:
I hereby claim:
To claim this, I am signing this object:
data "aws_availability_zones" "available" {} | |
locals { | |
az_length = length(data.aws_availability_zones.available) > 3 ? 3 : length(data.aws_availability_zones.available) | |
azs = slice(data.aws_availability_zones.available.names, 0, local.az_length) | |
} |
locals { | |
raw_value = yamldecode(file("${path.module}/example.yaml")) | |
normalized_value = { | |
name = tostring(try(local.raw_value.name, null)) | |
groups = try(local.raw_value.groups, []) | |
} | |
} |
terraform { | |
required_version = ">= 0.15.1" | |
backend "remote" {} | |
} |
sudo usermod -a -G docker USER |
resource "aws_cloudformation_stack" "mq01" { | |
name = "${var.name}-mq01" | |
tags = var.tags | |
disable_rollback = false | |
template_body = file("${path.module}/cfn/mq.yaml") | |
parameters = { | |
AmazonMQBrokerName = "${var.name}-mq01" | |
AmazonMQHostInstanceType = "mq.t3.micro" | |
AmazonMQBrokerUser = "Admin" |
data "aws_caller_identity" "current" {} # data.aws_caller_identity.current.account_id | |
data "aws_region" "current" {} # data.aws_region.current.name | |
output "account_id" { | |
description = "Selected AWS Account ID" | |
value = data.aws_caller_identity.current.account_id | |
} | |
output "region" { | |
description = "Details about selected AWS region" |