Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/bingtsingw/boilerplate-terraform
A simple terraform boilerplate with terragrunt
https://github.com/bingtsingw/boilerplate-terraform
boilerplate dotenv template terraform terragrunt
Last synced: about 2 months ago
JSON representation
A simple terraform boilerplate with terragrunt
- Host: GitHub
- URL: https://github.com/bingtsingw/boilerplate-terraform
- Owner: bingtsingw
- License: mit
- Created: 2020-09-25T16:27:25.000Z (over 4 years ago)
- Default Branch: main
- Last Pushed: 2023-01-25T15:11:17.000Z (almost 2 years ago)
- Last Synced: 2023-03-06T02:59:16.161Z (almost 2 years ago)
- Topics: boilerplate, dotenv, template, terraform, terragrunt
- Language: HCL
- Homepage:
- Size: 36.1 KB
- Stars: 5
- Watchers: 2
- Forks: 0
- Open Issues: 3
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# boilerplate-terraform
This is a boilerplate using [terraform](https://www.terraform.io) with [terragrunt](https://github.com/gruntwork-io/terragrunt).
## Features
- [dotenv](https://github.com/motdotla/dotenv)-like variables management.
- remote backend with alicloud oss.
- built-in `Makefile` to simplify daily work.## Usage
```shell
# set environment variables in .env.yml file
cp .env.yml.example .env.yml# run make command
make module-clone MODULE_NAME=xxx
make plan
make apply
```## Explanation for Dotenv
In fact, `terraform` or `terragrunt` does not support `dotenv`, so we cannot use a `.env` file directly.
Instead, we can borrow the idea behind `dotenv`. Just parse a `.env.yml` file with `terragrunt`'s `yamldecode` function to simulate this feature.