Skip to content

Instantly share code, notes, and snippets.

@birkoff
birkoff / cognito-social-idp-user-pool.md
Last active June 5, 2024 09:33
Documentation for Cognito Setup

Amazon Cognito provides authentication, authorization, and user management for your web and mobile apps. Your users can sign in directly with a user name and password, or through a third party such as Facebook, Amazon, Google or Apple.

https://docs.aws.amazon.com/cognito/latest/developerguide/what-is-amazon-cognito.html

The two main components

You can use identity pools and user pools separately or together.

User pools

User pools are user directories that provide sign-up and sign-in options for your app users

resource "random_password" "rds_password" {
length = 16 # Specify the desired password length
special = true # Include special characters in the password
override_special = "_!@#" # Optional: Specify additional special characters
}
module "security_group" {
source = "git::https://github.com/terraform-aws-modules/terraform-aws-security-group.git//"
name = "${var.identifier}-db"
@birkoff
birkoff / application-main.tf
Last active October 14, 2023 21:15
Terraform Route53 CloudFront S3 Bucket WebPage - MultiAccount Deployment
# Terraform state will be stored on Shared-Services
# No interpolations allowed here!!!!!
terraform {
backend "s3" {
bucket = "terraform-state-shared-services" # Shared Services
region = "us-east-1"
profile = "shared-services"
# Set this only when using Terraform Workspaces
key = "lab/web-ui/terraform.tfstate"
dynamodb_table = "shared-services-lock-table"
# Terraform state will be stored on Shared-Services
# No interpolations allowed here!!!!!
terraform {
backend "s3" {
bucket = "terraform-state-shared-services" # Shared Services
region = "us-east-1"
profile = "shared-services"
# Set this only when using Terraform Workspaces
key = "dns/zones/terraform.tfstate"
dynamodb_table = "shared-services-lock-table"