Terraform-aws-db-provisioning-ci-cd
Database-IAC-templates and database-provisioning-code are included in this module.It helps with database provisioning using Infrastructure as Code (IaC).
Terraform is an infrastructure-as-code (IaC) tool that simplifies the creating,updating,and versioning of infrastructure in a secure and repeatable manner.db-iac-templates consists terraform templates for creating DB-provisioning CodePipelines. As a guide and ready-to-use terraform configurations,this would provide an overview of how to setup validation pipelines with end-to-end tests using AWS CodePipeline,AWS CodeBuild,AWS CodeCommit and terraform.
This folder contains the sample terraform code to provision the RDS database using db-provisioning pipeline.
SSM parametrs being fetched from the first step of this solution i.e. setup/db-ssm-params and used in db-provisioning-code/BUILDSPEC_TEMPLATES
. Variable decalarion is done in db-provisioning-code/variables.tf
.
Note: We have provided the sample RDS database provisioning using terraform. Please refer RDS best practises to provision customized RDS database.
- As per required input values, update
db-iac-templates/examples/terraform.tfvars
. - The following are the deployment commands for creating pipelines in an AWS account.
cd db-iac-templates/ terrform init terraform plan --var-file=examples/terraform.tfvars terraform apply --var-file=examples/terraform.tfvars
- Monitor the "DB-Provisioning pipeline" Pipeline for updates.
- Before deploying changes, it will ask for manual approval, please approve it and let the pipeline continue.