Skip to content

Commit d7b57ed

Browse files
authored
Migrate to README.yaml format, add travis (#13)
1 parent cd1b042 commit d7b57ed

File tree

9 files changed

+409
-72
lines changed

9 files changed

+409
-72
lines changed

.gitignore

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,3 +6,6 @@
66
.terraform
77
.idea
88
*.iml
9+
10+
**/.build-harness
11+
**/build-harness

.travis.yml

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
addons:
2+
apt:
3+
packages:
4+
- git
5+
- make
6+
- curl
7+
8+
install:
9+
- make init
10+
11+
script:
12+
- make terraform:install
13+
- make terraform:get-plugins
14+
- make terraform:get-modules
15+
- make terraform:lint
16+
- make terraform:validate

Makefile

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
SHELL := /bin/bash
2+
3+
# List of targets the `readme` target should call before generating the readme
4+
export README_DEPS ?= docs/targets.md docs/terraform.md
5+
6+
-include $(shell curl -sSL -o .build-harness "https://git.io/build-harness"; echo .build-harness)
7+
8+
## Lint terraform code
9+
lint:
10+
$(SELF) terraform/install terraform/get-modules terraform/get-plugins terraform/lint terraform/validate

README.md

Lines changed: 188 additions & 40 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,23 @@
1-
# terraform-aws-elasticache-redis
1+
<!-- This file was automatically generated by the `build-harness`. Make all changes to `README.yaml` and run `make readme` to rebuild this file. -->
2+
3+
[![Cloud Posse](https://cloudposse.com/logo-300x69.png)](https://cloudposse.com)
4+
5+
# terraform-aws-elasticache-redis [![Build Status](https://travis-ci.org/cloudposse/terraform-aws-elasticache-redis.svg?branch=master)](https://travis-ci.org/cloudposse/terraform-aws-elasticache-redis) [![Latest Release](https://img.shields.io/github/release/cloudposse/terraform-aws-elasticache-redis.svg)](https://travis-ci.org/cloudposse/terraform-aws-elasticache-redis/releases) [![Slack Community](https://slack.cloudposse.com/badge.svg)](https://slack.cloudposse.com)
6+
27

38
Terraform module to provision an [`ElastiCache`](https://aws.amazon.com/elasticache/) Redis Cluster
49

510

11+
---
12+
13+
This project is part of our comprehensive ["SweetOps"](https://docs.cloudposse.com) approach towards DevOps.
14+
15+
16+
It's 100% Open Source and licensed under the [APACHE2](LICENSE).
17+
18+
19+
20+
621
## Usage
722

823
Include this repository as a module in your existing terraform code:
@@ -32,46 +47,179 @@ module "example_redis" {
3247
```
3348

3449

35-
## Input
36-
37-
| Name | Default | Description |
38-
|:-----------------------------|:-------------------:|:----------------------------------------------------------------|
39-
| enabled | true | Set to false to prevent the module from creating any resources |
40-
| namespace | global | Namespace |
41-
| stage | default | Stage |
42-
| name | redis | Name |
43-
| security_groups | [] | AWS security group ids |
44-
| vpc_id | __REQUIRED__ | AWS VPC id |
45-
| subnets | [] | AWS subnet ids |
46-
| cluster_size | 1 | Count of nodes in cluster |
47-
| instance_type | cache.t2.micro | Elastic cache instance type |
48-
| family | redis3.2 | Redis family |
49-
| engine_version | 3.2.4 | Redis engine version |
50-
| port | 6379 | Redis port |
51-
| maintenance_window | wed:03:00-wed:04:00 | Maintenance window |
52-
| notification_topic_arn | | Notification topic arn |
53-
| alarm_cpu_threshold_percent | 75 | CPU threshold alarm level |
54-
| alarm_memory_threshold_bytes | 10000000 | Ram threshold alarm level |
55-
| alarm_actions | [] | Alarm action list |
56-
| apply_immediately | true | Apply changes immediately |
57-
| automatic_failover | false | Automatic failover (Not available for T1/T2 instances) |
58-
| availability_zones | [] | Availability zone ids |
59-
| zone_id | false | Route53 DNS Zone id |
60-
| attributes | [] | Additional attributes (_e.g._ "1") |
61-
| tags | {} | Additional tags (_e.g._ map("BusinessUnit","ABC") |
62-
| delimiter | - | Delimiter between `name`, `namespace`, `stage` and `attributes` |
63-
64-
65-
## Output
66-
67-
| Name | Description |
68-
|:------------------|:------------------|
69-
| id | Redis cluster id |
50+
51+
52+
53+
54+
## Makefile Targets
55+
```
56+
Available targets:
57+
58+
help This help screen
59+
help/all Display help for all targets
60+
lint Lint terraform code
61+
62+
```
63+
64+
## Inputs
65+
66+
| Name | Description | Type | Default | Required |
67+
|------|-------------|:----:|:-----:|:-----:|
68+
| alarm_actions | Alarm action list | list | `<list>` | no |
69+
| alarm_cpu_threshold_percent | CPU threshold alarm level | string | `75` | no |
70+
| alarm_memory_threshold_bytes | Ram threshold alarm level | string | `10000000` | no |
71+
| apply_immediately | Apply changes immediately | string | `true` | no |
72+
| attributes | Additional attributes (_e.g._ "1") | list | `<list>` | no |
73+
| automatic_failover | Automatic failover (Not available for T1/T2 instances) | string | `false` | no |
74+
| availability_zones | Availability zone ids | list | `Availability zone ids` | no |
75+
| cluster_size | Count of nodes in cluster | string | `1` | no |
76+
| delimiter | Delimiter between `name`, `namespace`, `stage` and `attributes` | string | `-` | no |
77+
| enabled | Set to false to prevent the module from creating any resources | string | `true` | no |
78+
| engine_version | Redis engine version | string | `4.0.10` | no |
79+
| family | Redis family | string | `redis4.0` | no |
80+
| instance_type | Elastic cache instance type | string | `cache.t2.micro` | no |
81+
| maintenance_window | Maintenance window | string | `wed:03:00-wed:04:00` | no |
82+
| name | Name | string | `redis` | no |
83+
| namespace | Namespace | string | `global` | no |
84+
| notification_topic_arn | Notification topic arn | string | `10000000` | no |
85+
| port | Redis port | string | `6379` | no |
86+
| security_groups | AWS security group ids | list | `<list>` | no |
87+
| stage | Stage | string | `default` | no |
88+
| subnets | AWS subnet ids | list | `<list>` | no |
89+
| tags | Additional tags (_e.g._ map("BusinessUnit","ABC") | map | `<map>` | no |
90+
| vpc_id | AWS VPC id | string | `REQUIRED` | no |
91+
| zone_id | Route53 DNS Zone id | string | `false` | no |
92+
93+
## Outputs
94+
95+
| Name | Description |
96+
|------|-------------|
97+
| host | Redis host |
98+
| id | Redis cluster id |
99+
| port | Redis port |
70100
| security_group_id | Security group id |
71-
| host | Redis host |
72-
| port | Redis port |
73101

74102

75-
## License
76103

77-
Apache 2 License. See [`LICENSE`](LICENSE) for full details.
104+
## Help
105+
106+
**Got a question?**
107+
108+
File a GitHub [issue](https://github.com/cloudposse/terraform-aws-elasticache-redis/issues), send us an [email][email] or join our [Slack Community][slack].
109+
110+
## Commerical Support
111+
112+
Work directly with our team of DevOps experts via email, slack, and video conferencing.
113+
114+
We provide *commercial support* for all of our [Open Source][github] projects. As a *Dedicated Support* customer, you have access to our team of subject matter experts at a fraction of the cost of a fulltime engineer.
115+
116+
[![E-Mail](https://img.shields.io/badge/email-hello@cloudposse.com-blue.svg)](mailto:hello@cloudposse.com)
117+
118+
- **Questions.** We'll use a Shared Slack channel between your team and ours.
119+
- **Troubleshooting.** We'll help you triage why things aren't working.
120+
- **Code Reviews.** We'll review your Pull Requests and provide constructive feedback.
121+
- **Bug Fixes.** We'll rapidly work to fix any bugs in our projects.
122+
- **Build New Terraform Modules.** We'll develop original modules to provision infrastructure.
123+
- **Cloud Architecture.** We'll assist with your cloud strategy and design.
124+
- **Implementation.** We'll provide hands on support to implement our reference architectures.
125+
126+
127+
## Community Forum
128+
129+
Get access to our [Open Source Community Forum][slack] on Slack. It's **FREE** to join for everyone! Our "SweetOps" community is where you get to talk with others who share a similar vision for how to rollout and manage infrastructure. This is the best place to talk shop, ask questions, solicit feedback, and work together as a community to build *sweet* infrastructure.
130+
131+
## Contributing
132+
133+
### Bug Reports & Feature Requests
134+
135+
Please use the [issue tracker](https://github.com/cloudposse/terraform-aws-elasticache-redis/issues) to report any bugs or file feature requests.
136+
137+
### Developing
138+
139+
If you are interested in being a contributor and want to get involved in developing this project or [help out](https://github.com/orgs/cloudposse/projects/3) with our other projects, we would love to hear from you! Shoot us an [email](mailto:hello@cloudposse.com).
140+
141+
In general, PRs are welcome. We follow the typical "fork-and-pull" Git workflow.
142+
143+
1. **Fork** the repo on GitHub
144+
2. **Clone** the project to your own machine
145+
3. **Commit** changes to your own branch
146+
4. **Push** your work back up to your fork
147+
5. Submit a **Pull Request** so that we can review your changes
148+
149+
**NOTE:** Be sure to merge the latest changes from "upstream" before making a pull request!
150+
151+
## Copyright
152+
153+
Copyright © 2017-2018 [Cloud Posse, LLC](https://cloudposse.com)
154+
155+
156+
## License
157+
158+
[![License](https://img.shields.io/badge/License-Apache%202.0-blue.svg)](https://opensource.org/licenses/Apache-2.0)
159+
160+
See [LICENSE](LICENSE) for full details.
161+
162+
Licensed to the Apache Software Foundation (ASF) under one
163+
or more contributor license agreements. See the NOTICE file
164+
distributed with this work for additional information
165+
regarding copyright ownership. The ASF licenses this file
166+
to you under the Apache License, Version 2.0 (the
167+
"License"); you may not use this file except in compliance
168+
with the License. You may obtain a copy of the License at
169+
170+
https://www.apache.org/licenses/LICENSE-2.0
171+
172+
Unless required by applicable law or agreed to in writing,
173+
software distributed under the License is distributed on an
174+
"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
175+
KIND, either express or implied. See the License for the
176+
specific language governing permissions and limitations
177+
under the License.
178+
179+
180+
## Trademarks
181+
182+
All other trademarks referenced herein are the property of their respective owners.
183+
184+
## About
185+
186+
This project is maintained and funded by [Cloud Posse, LLC][website]. Like it? Please let us know at <hello@cloudposse.com>
187+
188+
[![Cloud Posse](https://cloudposse.com/logo-300x69.png)](https://cloudposse.com)
189+
190+
We're a [DevOps Professional Services][hire] company based in Los Angeles, CA. We love [Open Source Software](https://github.com/cloudposse/)!
191+
192+
We offer paid support on all of our projects.
193+
194+
Check out [our other projects][github], [apply for a job][jobs], or [hire us][hire] to help with your cloud strategy and implementation.
195+
196+
[docs]: https://docs.cloudposse.com/
197+
[website]: https://cloudposse.com/
198+
[github]: https://github.com/cloudposse/
199+
[jobs]: https://cloudposse.com/jobs/
200+
[hire]: https://cloudposse.com/contact/
201+
[slack]: https://slack.cloudposse.com/
202+
[linkedin]: https://www.linkedin.com/company/cloudposse
203+
[twitter]: https://twitter.com/cloudposse/
204+
[email]: mailto:hello@cloudposse.com
205+
206+
207+
### Contributors
208+
209+
| [![Erik Osterman][osterman_avatar]](osterman_homepage)<br/>[Erik Osterman][osterman_homepage] | [![Igor Rodionov][goruha_avatar]](goruha_homepage)<br/>[Igor Rodionov][goruha_homepage] | [![Andriy Knysh][aknysh_avatar]](aknysh_homepage)<br/>[Andriy Knysh][aknysh_homepage] | [![Daren Desjardins][darend_avatar]](darend_homepage)<br/>[Daren Desjardins][darend_homepage] | [![Max Moon][MoonMoon1919_avatar]](MoonMoon1919_homepage)<br/>[Max Moon][MoonMoon1919_homepage] | [![Christopher Riley][christopherriley_avatar]](christopherriley_homepage)<br/>[Christopher Riley][christopherriley_homepage] |
210+
|---|---|---|---|---|---|
211+
212+
[osterman_homepage]: https://github.com/osterman
213+
[osterman_avatar]: https://github.com/osterman.png?size=150
214+
[goruha_homepage]: https://github.com/goruha
215+
[goruha_avatar]: https://github.com/goruha.png?size=150
216+
[aknysh_homepage]: https://github.com/aknysh
217+
[aknysh_avatar]: https://github.com/aknysh.png?size=150
218+
[darend_homepage]: https://github.com/darend
219+
[darend_avatar]: https://github.com/darend.png?size=150
220+
[MoonMoon1919_homepage]: https://github.com/MoonMoon1919
221+
[MoonMoon1919_avatar]: https://github.com/MoonMoon1919.png?size=150
222+
[christopherriley_homepage]: https://github.com/christopherriley
223+
[christopherriley_avatar]: https://github.com/christopherriley.png?size=150
224+
225+

README.yaml

Lines changed: 81 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,81 @@
1+
---
2+
#
3+
# This is the canonical configuration for the `README.md`
4+
# Run `make readme` to rebuild the `README.md`
5+
#
6+
7+
# Name of this project
8+
name: terraform-aws-elasticache-redis
9+
10+
# Logo for this project
11+
#logo: docs/logo.png
12+
13+
# License of this project
14+
license: "APACHE2"
15+
16+
# Canonical GitHub repo
17+
github_repo: cloudposse/terraform-aws-elasticache-redis
18+
19+
# Badges to display
20+
badges:
21+
- name: "Build Status"
22+
image: "https://travis-ci.org/cloudposse/terraform-aws-elasticache-redis.svg?branch=master"
23+
url: "https://travis-ci.org/cloudposse/terraform-aws-elasticache-redis"
24+
- name: "Latest Release"
25+
image: "https://img.shields.io/github/release/cloudposse/terraform-aws-elasticache-redis.svg"
26+
url: "https://travis-ci.org/cloudposse/terraform-aws-elasticache-redis/releases"
27+
- name: "Slack Community"
28+
image: "https://slack.cloudposse.com/badge.svg"
29+
url: "https://slack.cloudposse.com"
30+
31+
# Short description of this project
32+
description: |-
33+
Terraform module to provision an [`ElastiCache`](https://aws.amazon.com/elasticache/) Redis Cluster
34+
35+
# How to use this project
36+
usage: |-
37+
Include this repository as a module in your existing terraform code:
38+
39+
```hcl
40+
module "example_redis" {
41+
source = "git::https://github.com/cloudposse/terraform-aws-elasticache-redis.git?ref=master"
42+
namespace = "general"
43+
name = "redis"
44+
stage = "prod"
45+
zone_id = "${var.route53_zone_id}"
46+
security_groups = ["${var.security_group_id}"]
47+
48+
vpc_id = "${var.vpc_id}"
49+
subnets = "${var.private_subnets}"
50+
maintenance_window = "wed:03:00-wed:04:00"
51+
cluster_size = "2"
52+
instance_type = "cache.t2.micro"
53+
engine_version = "3.2.4"
54+
alarm_cpu_threshold_percent = "${var.cache_alarm_cpu_threshold_percent}"
55+
alarm_memory_threshold_bytes = "${var.cache_alarm_memory_threshold_bytes}"
56+
apply_immediately = "true"
57+
availability_zones = "${var.availability_zones}"
58+
59+
automatic_failover = "false"
60+
}
61+
```
62+
63+
64+
include:
65+
- "docs/targets.md"
66+
- "docs/terraform.md"
67+
68+
# Contributors to this project
69+
contributors:
70+
- name: "Erik Osterman"
71+
github: "osterman"
72+
- name: "Igor Rodionov"
73+
github: "goruha"
74+
- name: "Andriy Knysh"
75+
github: "aknysh"
76+
- name: "Daren Desjardins"
77+
github: "darend"
78+
- name: "Max Moon"
79+
github: "MoonMoon1919"
80+
- name: "Christopher Riley"
81+
github: "christopherriley"

docs/targets.md

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
## Makefile Targets
2+
```
3+
Available targets:
4+
5+
help This help screen
6+
help/all Display help for all targets
7+
lint Lint terraform code
8+
9+
```

0 commit comments

Comments
 (0)