Skip to content

Commit 5d03d6d

Browse files
adamcrewsaknysh
authored andcommitted
Use the latest label module to support the environment attribute (#19)
1 parent a2d05ec commit 5d03d6d

File tree

4 files changed

+127
-75
lines changed

4 files changed

+127
-75
lines changed

README.md

Lines changed: 94 additions & 51 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,43 @@
1-
<!-- This file was automatically generated by the `build-harness`. Make all changes to `README.yaml` and run `make readme` to rebuild this file. -->
1+
<!--
2+
3+
4+
5+
6+
7+
8+
9+
10+
11+
12+
13+
14+
15+
16+
** DO NOT EDIT THIS FILE
17+
**
18+
** This file was automatically generated by the `build-harness`.
19+
** 1) Make all changes to `README.yaml`
20+
** 2) Run `make init` (you only need to do this once)
21+
** 3) Run`make readme` to rebuild this file.
22+
**
23+
** (We maintain HUNDREDS of open source projects. This is how we maintain our sanity.)
24+
**
25+
26+
27+
28+
29+
30+
31+
32+
33+
34+
35+
36+
37+
38+
39+
40+
-->
241
[![README Header][readme_header_img]][readme_header_link]
342

443
[![Cloud Posse][logo]](https://cpco.io/homepage)
@@ -93,15 +132,16 @@ Available targets:
93132
| autoscale_min_write_capacity | DynamoDB autoscaling min write capacity | number | `5` | no |
94133
| autoscale_read_target | The target value for DynamoDB read autoscaling | number | `50` | no |
95134
| autoscale_write_target | The target value for DynamoDB write autoscaling | number | `50` | no |
96-
| delimiter | Delimiter to be used between `namespace`, `stage`, `name` and `attributes` | string | `-` | no |
135+
| delimiter | Delimiter to be used between `namespace`, `environment`, `stage`, `name` and `attributes` | string | `-` | no |
97136
| dynamodb_indexes | List of DynamoDB indexes | list(string) | `<list>` | no |
98137
| dynamodb_table_arn | DynamoDB table ARN | string | - | yes |
99138
| dynamodb_table_name | DynamoDB table name | string | - | yes |
100139
| enabled | Set to false to prevent the module from creating any resources | bool | `true` | no |
101-
| name | Name (e.g. `app` or `cluster`) | string | - | yes |
102-
| namespace | Namespace (e.g. `eg` or `cp`) | string | `` | no |
103-
| stage | Stage (e.g. `prod`, `dev`, `staging`, `infra`) | string | `` | no |
104-
| tags | Additional tags (e.g. map(`BusinessUnit`,`XYZ`) | map(string) | `<map>` | no |
140+
| environment | Environment, e.g. 'prod', 'staging', 'dev', 'pre-prod', 'UAT' | string | `` | no |
141+
| name | Solution name, e.g. 'app' or 'jenkins' | string | `` | no |
142+
| namespace | Namespace, which could be your organization name or abbreviation, e.g. 'eg' or 'cp' | string | `` | no |
143+
| stage | Stage, e.g. 'prod', 'staging', 'dev', OR 'source', 'build', 'test', 'deploy', 'release' | string | `` | no |
144+
| tags | Additional tags (e.g. `map('BusinessUnit','XYZ')` | map(string) | `<map>` | no |
105145

106146
## Outputs
107147

@@ -135,42 +175,47 @@ Check out these related projects.
135175

136176
## Help
137177

138-
**Got a question?**
178+
**Got a question?** We got answers.
139179

140180
File a GitHub [issue](https://github.com/cloudposse/terraform-aws-dynamodb-autoscaler/issues), send us an [email][email] or join our [Slack Community][slack].
141181

142182
[![README Commercial Support][readme_commercial_support_img]][readme_commercial_support_link]
143183

144-
## Commercial Support
145-
146-
Work directly with our team of DevOps experts via email, slack, and video conferencing.
147-
148-
We provide [*commercial support*][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 full-time engineer.
184+
## DevOps Accelerator for Startups
149185

150-
[![E-Mail](https://img.shields.io/badge/email-hello@cloudposse.com-blue.svg)][email]
151186

152-
- **Questions.** We'll use a Shared Slack channel between your team and ours.
153-
- **Troubleshooting.** We'll help you triage why things aren't working.
154-
- **Code Reviews.** We'll review your Pull Requests and provide constructive feedback.
155-
- **Bug Fixes.** We'll rapidly work to fix any bugs in our projects.
156-
- **Build New Terraform Modules.** We'll [develop original modules][module_development] to provision infrastructure.
157-
- **Cloud Architecture.** We'll assist with your cloud strategy and design.
158-
- **Implementation.** We'll provide hands-on support to implement our reference architectures.
187+
We are a [**DevOps Accelerator**][commercial_support]. We'll help you build your cloud infrastructure from the ground up so you can own it. Then we'll show you how to operate it and stick around for as long as you need us.
159188

189+
[![Learn More](https://img.shields.io/badge/learn%20more-success.svg?style=for-the-badge)][commercial_support]
160190

191+
Work directly with our team of DevOps experts via email, slack, and video conferencing.
161192

162-
## Terraform Module Development
163-
164-
Are you interested in custom Terraform module development? Submit your inquiry using [our form][module_development] today and we'll get back to you ASAP.
193+
We deliver 10x the value for a fraction of the cost of a full-time engineer. Our track record is not even funny. If you want things done right and you need it done FAST, then we're your best bet.
165194

195+
- **Reference Architecture.** You'll get everything you need from the ground up built using 100% infrastructure as code.
196+
- **Release Engineering.** You'll have end-to-end CI/CD with unlimited staging environments.
197+
- **Site Reliability Engineering.** You'll have total visibility into your apps and microservices.
198+
- **Security Baseline.** You'll have built-in governance with accountability and audit logs for all changes.
199+
- **GitOps.** You'll be able to operate your infrastructure via Pull Requests.
200+
- **Training.** You'll receive hands-on training so your team can operate what we build.
201+
- **Questions.** You'll have a direct line of communication between our teams via a Shared Slack channel.
202+
- **Troubleshooting.** You'll get help to triage when things aren't working.
203+
- **Code Reviews.** You'll receive constructive feedback on Pull Requests.
204+
- **Bug Fixes.** We'll rapidly work with you to fix any bugs in our projects.
166205

167206
## Slack Community
168207

169208
Join our [Open Source Community][slack] on Slack. It's **FREE** 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 totally *sweet* infrastructure.
170209

171210
## Newsletter
172211

173-
Signup for [our newsletter][newsletter] that covers everything on our technology radar. Receive updates on what we're up to on GitHub as well as awesome new projects we discover.
212+
Sign up for [our newsletter][newsletter] that covers everything on our technology radar. Receive updates on what we're up to on GitHub as well as awesome new projects we discover.
213+
214+
## Office Hours
215+
216+
[Join us every Wednesday via Zoom][office_hours] for our weekly "Lunch & Learn" sessions. It's **FREE** for everyone!
217+
218+
[![zoom](https://img.cloudposse.com/fit-in/200x200/https://cloudposse.com/wp-content/uploads/2019/08/Powered-by-Zoom.png")][office_hours]
174219

175220
## Contributing
176221

@@ -195,7 +240,7 @@ In general, PRs are welcome. We follow the typical "fork-and-pull" Git workflow.
195240

196241
## Copyright
197242

198-
Copyright © 2017-2019 [Cloud Posse, LLC](https://cpco.io/copyright)
243+
Copyright © 2017-2020 [Cloud Posse, LLC](https://cpco.io/copyright)
199244

200245

201246

@@ -254,39 +299,37 @@ Check out [our other projects][github], [follow us on twitter][twitter], [apply
254299
|---|---|---|
255300

256301
[osterman_homepage]: https://github.com/osterman
257-
[osterman_avatar]: https://github.com/osterman.png?size=150
302+
[osterman_avatar]: https://img.cloudposse.com/150x150/https://github.com/osterman.png
258303
[aknysh_homepage]: https://github.com/aknysh
259-
[aknysh_avatar]: https://github.com/aknysh.png?size=150
304+
[aknysh_avatar]: https://img.cloudposse.com/150x150/https://github.com/aknysh.png
260305
[emmekappa_homepage]: https://github.com/emmekappa
261-
[emmekappa_avatar]: https://github.com/emmekappa.png?size=150
262-
263-
306+
[emmekappa_avatar]: https://img.cloudposse.com/150x150/https://github.com/emmekappa.png
264307

265308
[![README Footer][readme_footer_img]][readme_footer_link]
266309
[![Beacon][beacon]][website]
267310

268311
[logo]: https://cloudposse.com/logo-300x69.svg
269-
[docs]: https://cpco.io/docs
270-
[website]: https://cpco.io/homepage
271-
[github]: https://cpco.io/github
272-
[jobs]: https://cpco.io/jobs
273-
[hire]: https://cpco.io/hire
274-
[slack]: https://cpco.io/slack
275-
[linkedin]: https://cpco.io/linkedin
276-
[twitter]: https://cpco.io/twitter
277-
[testimonial]: https://cpco.io/leave-testimonial
278-
[newsletter]: https://cpco.io/newsletter
279-
[email]: https://cpco.io/email
280-
[commercial_support]: https://cpco.io/commercial-support
281-
[we_love_open_source]: https://cpco.io/we-love-open-source
282-
[module_development]: https://cpco.io/module-development
283-
[terraform_modules]: https://cpco.io/terraform-modules
284-
[readme_header_img]: https://cloudposse.com/readme/header/img?repo=cloudposse/terraform-aws-dynamodb-autoscaler
285-
[readme_header_link]: https://cloudposse.com/readme/header/link?repo=cloudposse/terraform-aws-dynamodb-autoscaler
286-
[readme_footer_img]: https://cloudposse.com/readme/footer/img?repo=cloudposse/terraform-aws-dynamodb-autoscaler
287-
[readme_footer_link]: https://cloudposse.com/readme/footer/link?repo=cloudposse/terraform-aws-dynamodb-autoscaler
288-
[readme_commercial_support_img]: https://cloudposse.com/readme/commercial-support/img?repo=cloudposse/terraform-aws-dynamodb-autoscaler
289-
[readme_commercial_support_link]: https://cloudposse.com/readme/commercial-support/link?repo=cloudposse/terraform-aws-dynamodb-autoscaler
312+
[docs]: https://cpco.io/docs?utm_source=github&utm_medium=readme&utm_campaign=cloudposse/terraform-aws-dynamodb-autoscaler&utm_content=docs
313+
[website]: https://cpco.io/homepage?utm_source=github&utm_medium=readme&utm_campaign=cloudposse/terraform-aws-dynamodb-autoscaler&utm_content=website
314+
[github]: https://cpco.io/github?utm_source=github&utm_medium=readme&utm_campaign=cloudposse/terraform-aws-dynamodb-autoscaler&utm_content=github
315+
[jobs]: https://cpco.io/jobs?utm_source=github&utm_medium=readme&utm_campaign=cloudposse/terraform-aws-dynamodb-autoscaler&utm_content=jobs
316+
[hire]: https://cpco.io/hire?utm_source=github&utm_medium=readme&utm_campaign=cloudposse/terraform-aws-dynamodb-autoscaler&utm_content=hire
317+
[slack]: https://cpco.io/slack?utm_source=github&utm_medium=readme&utm_campaign=cloudposse/terraform-aws-dynamodb-autoscaler&utm_content=slack
318+
[linkedin]: https://cpco.io/linkedin?utm_source=github&utm_medium=readme&utm_campaign=cloudposse/terraform-aws-dynamodb-autoscaler&utm_content=linkedin
319+
[twitter]: https://cpco.io/twitter?utm_source=github&utm_medium=readme&utm_campaign=cloudposse/terraform-aws-dynamodb-autoscaler&utm_content=twitter
320+
[testimonial]: https://cpco.io/leave-testimonial?utm_source=github&utm_medium=readme&utm_campaign=cloudposse/terraform-aws-dynamodb-autoscaler&utm_content=testimonial
321+
[office_hours]: https://cloudposse.com/office-hours?utm_source=github&utm_medium=readme&utm_campaign=cloudposse/terraform-aws-dynamodb-autoscaler&utm_content=office_hours
322+
[newsletter]: https://cpco.io/newsletter?utm_source=github&utm_medium=readme&utm_campaign=cloudposse/terraform-aws-dynamodb-autoscaler&utm_content=newsletter
323+
[email]: https://cpco.io/email?utm_source=github&utm_medium=readme&utm_campaign=cloudposse/terraform-aws-dynamodb-autoscaler&utm_content=email
324+
[commercial_support]: https://cpco.io/commercial-support?utm_source=github&utm_medium=readme&utm_campaign=cloudposse/terraform-aws-dynamodb-autoscaler&utm_content=commercial_support
325+
[we_love_open_source]: https://cpco.io/we-love-open-source?utm_source=github&utm_medium=readme&utm_campaign=cloudposse/terraform-aws-dynamodb-autoscaler&utm_content=we_love_open_source
326+
[terraform_modules]: https://cpco.io/terraform-modules?utm_source=github&utm_medium=readme&utm_campaign=cloudposse/terraform-aws-dynamodb-autoscaler&utm_content=terraform_modules
327+
[readme_header_img]: https://cloudposse.com/readme/header/img
328+
[readme_header_link]: https://cloudposse.com/readme/header/link?utm_source=github&utm_medium=readme&utm_campaign=cloudposse/terraform-aws-dynamodb-autoscaler&utm_content=readme_header_link
329+
[readme_footer_img]: https://cloudposse.com/readme/footer/img
330+
[readme_footer_link]: https://cloudposse.com/readme/footer/link?utm_source=github&utm_medium=readme&utm_campaign=cloudposse/terraform-aws-dynamodb-autoscaler&utm_content=readme_footer_link
331+
[readme_commercial_support_img]: https://cloudposse.com/readme/commercial-support/img
332+
[readme_commercial_support_link]: https://cloudposse.com/readme/commercial-support/link?utm_source=github&utm_medium=readme&utm_campaign=cloudposse/terraform-aws-dynamodb-autoscaler&utm_content=readme_commercial_support_link
290333
[share_twitter]: https://twitter.com/intent/tweet/?text=terraform-aws-dynamodb-autoscaler&url=https://github.com/cloudposse/terraform-aws-dynamodb-autoscaler
291334
[share_linkedin]: https://www.linkedin.com/shareArticle?mini=true&title=terraform-aws-dynamodb-autoscaler&url=https://github.com/cloudposse/terraform-aws-dynamodb-autoscaler
292335
[share_reddit]: https://reddit.com/submit/?url=https://github.com/cloudposse/terraform-aws-dynamodb-autoscaler

docs/terraform.md

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -9,15 +9,16 @@
99
| autoscale_min_write_capacity | DynamoDB autoscaling min write capacity | number | `5` | no |
1010
| autoscale_read_target | The target value for DynamoDB read autoscaling | number | `50` | no |
1111
| autoscale_write_target | The target value for DynamoDB write autoscaling | number | `50` | no |
12-
| delimiter | Delimiter to be used between `namespace`, `stage`, `name` and `attributes` | string | `-` | no |
12+
| delimiter | Delimiter to be used between `namespace`, `environment`, `stage`, `name` and `attributes` | string | `-` | no |
1313
| dynamodb_indexes | List of DynamoDB indexes | list(string) | `<list>` | no |
1414
| dynamodb_table_arn | DynamoDB table ARN | string | - | yes |
1515
| dynamodb_table_name | DynamoDB table name | string | - | yes |
1616
| enabled | Set to false to prevent the module from creating any resources | bool | `true` | no |
17-
| name | Name (e.g. `app` or `cluster`) | string | - | yes |
18-
| namespace | Namespace (e.g. `eg` or `cp`) | string | `` | no |
19-
| stage | Stage (e.g. `prod`, `dev`, `staging`, `infra`) | string | `` | no |
20-
| tags | Additional tags (e.g. map(`BusinessUnit`,`XYZ`) | map(string) | `<map>` | no |
17+
| environment | Environment, e.g. 'prod', 'staging', 'dev', 'pre-prod', 'UAT' | string | `` | no |
18+
| name | Solution name, e.g. 'app' or 'jenkins' | string | `` | no |
19+
| namespace | Namespace, which could be your organization name or abbreviation, e.g. 'eg' or 'cp' | string | `` | no |
20+
| stage | Stage, e.g. 'prod', 'staging', 'dev', OR 'source', 'build', 'test', 'deploy', 'release' | string | `` | no |
21+
| tags | Additional tags (e.g. `map('BusinessUnit','XYZ')` | map(string) | `<map>` | no |
2122

2223
## Outputs
2324

main.tf

Lines changed: 9 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,13 @@
11
module "default_label" {
2-
source = "git::https://github.com/cloudposse/terraform-null-label.git?ref=tags/0.14.1"
3-
namespace = var.namespace
4-
stage = var.stage
5-
name = var.name
6-
delimiter = var.delimiter
7-
attributes = var.attributes
8-
tags = var.tags
9-
enabled = var.enabled
2+
source = "git::https://github.com/cloudposse/terraform-null-label.git?ref=tags/0.16.0"
3+
namespace = var.namespace
4+
stage = var.stage
5+
environment = var.environment
6+
name = var.name
7+
delimiter = var.delimiter
8+
attributes = var.attributes
9+
tags = var.tags
10+
enabled = var.enabled
1011
}
1112

1213
data "aws_iam_policy_document" "assume_role" {

variables.tf

Lines changed: 18 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,24 +1,37 @@
11
variable "namespace" {
22
type = string
3-
description = "Namespace (e.g. `eg` or `cp`)"
43
default = ""
4+
description = "Namespace, which could be your organization name or abbreviation, e.g. 'eg' or 'cp'"
5+
}
6+
7+
variable "environment" {
8+
type = string
9+
default = ""
10+
description = "Environment, e.g. 'prod', 'staging', 'dev', 'pre-prod', 'UAT'"
511
}
612

713
variable "stage" {
814
type = string
9-
description = "Stage (e.g. `prod`, `dev`, `staging`, `infra`)"
1015
default = ""
16+
description = "Stage, e.g. 'prod', 'staging', 'dev', OR 'source', 'build', 'test', 'deploy', 'release'"
1117
}
1218

1319
variable "name" {
1420
type = string
15-
description = "Name (e.g. `app` or `cluster`)"
21+
default = ""
22+
description = "Solution name, e.g. 'app' or 'jenkins'"
23+
}
24+
25+
variable "enabled" {
26+
type = bool
27+
default = true
28+
description = "Set to false to prevent the module from creating any resources"
1629
}
1730

1831
variable "delimiter" {
1932
type = string
2033
default = "-"
21-
description = "Delimiter to be used between `namespace`, `stage`, `name` and `attributes`"
34+
description = "Delimiter to be used between `namespace`, `environment`, `stage`, `name` and `attributes`"
2235
}
2336

2437
variable "attributes" {
@@ -30,7 +43,7 @@ variable "attributes" {
3043
variable "tags" {
3144
type = map(string)
3245
default = {}
33-
description = "Additional tags (e.g. map(`BusinessUnit`,`XYZ`)"
46+
description = "Additional tags (e.g. `map('BusinessUnit','XYZ')`"
3447
}
3548

3649
variable "dynamodb_table_name" {
@@ -84,9 +97,3 @@ variable "autoscale_max_write_capacity" {
8497
default = 20
8598
description = "DynamoDB autoscaling max write capacity"
8699
}
87-
88-
variable "enabled" {
89-
type = bool
90-
description = "Set to false to prevent the module from creating any resources"
91-
default = true
92-
}

0 commit comments

Comments
 (0)