Terraform AWS
https://registry.terraform.io/providers/hashicorp/aws
Docs: https://registry.terraform.io/providers/hashicorp/aws/latest/docs
Terraform providers forum - https://discuss.hashicorp.com/c/terraform-providers/31
https://aws.amazon.com/solutions/partners/terraform-modules/
Are you missing an AWS resource in Terraform? Try awscc provider! - https://cloudonaut.io/are-you-missing-an-aws-resource-in-terraform-try-awscc-provider
Tutorials:
- Get started: https://developer.hashicorp.com/terraform/tutorials/aws-get-started
- Use cases: https://developer.hashicorp.com/terraform/tutorials/aws
provider "aws" {
region = "us-east-1"
profile = "personal"
default_tags {
tags = {
Project = "my-app"
}
}
}
Since version 1.11, there's no need to have a DynamoDB table to do state locking:
S3 native state locking is now generally available. The
use_lockfile
argument enables users to adopt the S3-native mechanism for state locking. As part of this change, we've deprecated the DynamoDB-related arguments in favor of this new locking mechanism. While you can still use DynamoDB alongside S3-native state locking for migration purposes, we encourage migrating to the new state locking mechanism.
IAM
Difference between aws_iam_policy and aws_iam_role_policy - https://stackoverflow.com/questions/66510222/difference-between-aws-iam-policy-and-aws-iam-role-policy
- aws_iam_policy -> managed policy, can be re-used
- aws_iam_role_policy → inline policy