https://github.com/imperial-genomics-facility/igf-aws-terraform
A repository for storing terraform configs
https://github.com/imperial-genomics-facility/igf-aws-terraform
Last synced: 8 months ago
JSON representation
A repository for storing terraform configs
- Host: GitHub
- URL: https://github.com/imperial-genomics-facility/igf-aws-terraform
- Owner: imperial-genomics-facility
- License: apache-2.0
- Created: 2024-09-04T12:04:19.000Z (about 1 year ago)
- Default Branch: main
- Last Pushed: 2024-12-17T23:49:31.000Z (10 months ago)
- Last Synced: 2025-01-03T08:26:55.773Z (9 months ago)
- Language: HCL
- Size: 68.4 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# IGF Terraform confs for AWS
A repository for storing AWS Terraform config files.## What resources will be created ?
* VPC
* Public subnets
* Private subnets
* Internet gateway for public subnets
* Route tables
* S3 bucket with versioning
* Lifecycle rules for S3 (target prefix: runs/)
* Remove incomplete multipart uploads after 7 days
* Remove non-current versions after 7 days
* Remove files after 30 days## How to use it?
* Clone repo `git clone https://github.com/imperial-genomics-facility/IGF-aws-terraform.git`
* Install and initialize terraform `terraform init'
* Create a variable file `terraform.tfvars` and add following lines
```yaml
environment = "YOUR ENV NAME"
project_name = "YOUR PROJECT NAME"
vpc_cidr_block = "CIDR BLOCK"
enable_nat_gateway = false
enable_vpn_gateway = false
name = "NAME"
s3_raw_run_bucket_id = " YOUR BUCKET NAME"
public_subnet_cidr_blocks = [
"LIST OF public subnets"
]
private_subnet_cidr_blocks = [
"LIST OF private subnets"
]
```
* Generate plan `terraform plan -out=dev.tfplan -no-color`
* Inspect plan and apply changes `terraform apply -no-color dev.tfplan`
* Destroy infrastructure: `terraform apply -destroy`