|
2 | 2 |
|
3 | 3 | ## What is this |
4 | 4 |
|
5 | | -This module contains reusable terraform modules to reduce boilerplate code. Mainly for M3 company but anyone can use this under [LICENSE](./LICENSE). |
| 5 | +Reusable terraform modules. They are made for M3,Inc.'s internal use. But, anyone able to use them under [LICENSE](./LICENSE). |
6 | 6 |
|
7 | | -For example, you can setup ECS cluster + AutoScailing with [ecs_ec2_cluster_template](./ecs_ec2_cluster_template), no need to write many terraform for every applications. |
| 7 | +## Modules |
8 | 8 |
|
9 | | -## Documents |
| 9 | +**Setting up services**: |
10 | 10 |
|
11 | | -Look `README.md` and `variables.tf` of each module to know it's detail. For example, [ecs_ec2_cluster_template/README.md](./ecs_ec2_cluster_template/README.md) and [ecs_ec2_cluster_template/variables.tf](./ecs_ec2_cluster_template/variables.tf). |
| 11 | +| Module | Description | |
| 12 | +| -------------: | :------------- | |
| 13 | +| [alb_template](./alb_template) | ALB + SSL certificate. | |
| 14 | +| [ecr_repository_template](./ecr_repository_template) | ECR repository with Lifecycle policy. | |
| 15 | +| [ecs_ec2_cluster_template](./ecs_ec2_cluster_template) | ECS nodes with EC2 + AutoScaling. | |
| 16 | +| [ecs_web_service_template](./ecs_web_service_template) | ECS service + ALB target/listener + Route53 record.| |
12 | 17 |
|
13 | | -## How to use |
| 18 | +**Notifications**: |
14 | 19 |
|
15 | | -You can load this module from [GitHub registry](https://www.terraform.io/docs/modules/sources.html#github). |
| 20 | +| Module | Description | |
| 21 | +| -------------: | :------------- | |
| 22 | +| [guardduty_slack](./guardduty_slack) | GuardDuty alerts in Slack. | |
16 | 23 |
|
17 | | -Only what you need to do is to write following: |
| 24 | + |
| 25 | +**Others**: |
| 26 | + |
| 27 | +| Module | Description | |
| 28 | +| -------------: | :------------- | |
| 29 | +| [lambda_monitoring](./lambda_monitoring) | CloudWatch monitoring (alarm) for AWS lambda. | |
| 30 | + |
| 31 | +See `README.md` and `variables.tf` of each module for detail. |
| 32 | + |
| 33 | +## Install |
| 34 | + |
| 35 | +We can use modules with `module` blocks: |
18 | 36 |
|
19 | 37 | ``` |
20 | 38 | module "esc_ec2_cluster_template" { |
21 | 39 | source = "github.com/m3dev/m3-terraform-modules//ecs_ec2_cluster_template?ref=495ff58" |
22 | 40 |
|
23 | | - // ... set input variables, see `variables.tf` of the module. |
| 41 | + // ... set input variables, see `variables.tf` of the mo. |
24 | 42 | } |
25 | 43 | ``` |
26 | 44 |
|
27 | | -Note that there are some key points in the `source` URL (see [official document for detail](https://www.terraform.io/docs/modules/sources.html)): |
| 45 | +Note: |
| 46 | + |
| 47 | +- You have to use double slash (`//`) to split repository URL and path from repository root. |
| 48 | +- You should specify tag/branch/revision with `ref`, or your code might be broken when the `master` branch changed. |
28 | 49 |
|
29 | | -- Use double slash (`//`) to split repository URL and path from repository root |
30 | | -- Use `ref` to specify tag/branch/revision to use |
| 50 | +See [the official document](https://www.terraform.io/docs/modules/sources.html)) for detail. |
0 commit comments