Skip to content

Commit

Permalink
#1 add scaffolding code
Browse files Browse the repository at this point in the history
  • Loading branch information
kunduso committed Aug 20, 2024
1 parent f745167 commit 0040338
Show file tree
Hide file tree
Showing 3 changed files with 62 additions and 0 deletions.
8 changes: 8 additions & 0 deletions backend.tf
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
terraform {
backend "s3" {
bucket = "kunduso-terraform-remote-bucket"
encrypt = true
key = "tf/terraform-rds-secretsmanager-rotation-lambda/terraform.tfstate"
region = "us-east-2"
}
}
19 changes: 19 additions & 0 deletions provider.tf
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
terraform {
required_providers {
aws = {
source = "hashicorp/aws"
version = "5.63.1"
}
}
}

provider "aws" {
region = var.region
access_key = var.access_key
secret_key = var.secret_key
default_tags {
tags = {
Source = "https://github.com/kunduso/terraform-rds-secretsmanager-rotation-lambda"
}
}
}
35 changes: 35 additions & 0 deletions variables.tf
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
#Define AWS Region
variable "region" {
description = "Infrastructure region"
type = string
default = "us-east-2"
}
#Define IAM User Access Key
variable "access_key" {
description = "The access_key that belongs to the IAM user"
type = string
sensitive = true
default = ""
}
#Define IAM User Secret Key
variable "secret_key" {
description = "The secret_key that belongs to the IAM user"
type = string
sensitive = true
default = ""
}
variable "name" {
description = "The name of the application."
type = string
default = "app-12"
}
variable "vpc_cidr" {
description = "The CIDR of the VPC."
type = string
default = "15.25.15.0/27"
}
variable "subnet_cidr" {
description = "The CIDR blocks for the subnets."
type = list(any)
default = ["12.25.15.0/28", "12.25.15.16/28"]
}

0 comments on commit 0040338

Please sign in to comment.