Skip to content

Commit 4acb497

Browse files
JamesFrostosterman
authored andcommitted
Added the artifact_type variable. (#26)
* Added the `artifact_type` variable. Currently, if you set the `source_type` variable to anything other than `CODEPIPELINE`, Terraform raises an exception. This is because the artifact type is always set to `CODEPIPELINE`. * Updated README.md
1 parent 0d4d833 commit 4acb497

File tree

5 files changed

+94
-26
lines changed

5 files changed

+94
-26
lines changed

README.md

Lines changed: 84 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
<!-- This file was automatically generated by the `build-harness`. Make all changes to `README.yaml` and run `make readme` to rebuild this file. -->
2+
[![README Header][readme_header_img]][readme_header_link]
23

3-
[![Cloud Posse](https://cloudposse.com/logo-300x69.svg)](https://cloudposse.com)
4+
[![Cloud Posse][logo]](https://cpco.io/homepage)
45

56
# terraform-aws-codebuild [![Build Status](https://travis-ci.org/cloudposse/terraform-aws-codebuild.svg?branch=master)](https://travis-ci.org/cloudposse/terraform-aws-codebuild) [![Latest Release](https://img.shields.io/github/release/cloudposse/terraform-aws-codebuild.svg)](https://github.com/cloudposse/terraform-aws-codebuild/releases) [![Slack Community](https://slack.cloudposse.com/badge.svg)](https://slack.cloudposse.com)
67

@@ -10,7 +11,17 @@ Terraform module to create AWS CodeBuild project for AWS CodePipeline.
1011

1112
---
1213

13-
This project is part of our comprehensive ["SweetOps"](https://docs.cloudposse.com) approach towards DevOps.
14+
This project is part of our comprehensive ["SweetOps"](https://cpco.io/sweetops) approach towards DevOps.
15+
[<img align="right" title="Share via Email" src="https://docs.cloudposse.com/images/ionicons/ios-email-outline-2.0.1-16x16-999999.svg"/>][share_email]
16+
[<img align="right" title="Share on Google+" src="https://docs.cloudposse.com/images/ionicons/social-googleplus-outline-2.0.1-16x16-999999.svg" />][share_googleplus]
17+
[<img align="right" title="Share on Facebook" src="https://docs.cloudposse.com/images/ionicons/social-facebook-outline-2.0.1-16x16-999999.svg" />][share_facebook]
18+
[<img align="right" title="Share on Reddit" src="https://docs.cloudposse.com/images/ionicons/social-reddit-outline-2.0.1-16x16-999999.svg" />][share_reddit]
19+
[<img align="right" title="Share on LinkedIn" src="https://docs.cloudposse.com/images/ionicons/social-linkedin-outline-2.0.1-16x16-999999.svg" />][share_linkedin]
20+
[<img align="right" title="Share on Twitter" src="https://docs.cloudposse.com/images/ionicons/social-twitter-outline-2.0.1-16x16-999999.svg" />][share_twitter]
21+
22+
23+
[![Terraform Open Source Modules](https://docs.cloudposse.com/images/terraform-open-source-modules.svg)][terraform_modules]
24+
1425

1526

1627
It's 100% Open Source and licensed under the [APACHE2](LICENSE).
@@ -21,6 +32,11 @@ It's 100% Open Source and licensed under the [APACHE2](LICENSE).
2132

2233

2334

35+
We literally have [*hundreds of terraform modules*][terraform_modules] that are Open Source and well-maintained. Check them out!
36+
37+
38+
39+
2440

2541

2642

@@ -89,8 +105,9 @@ provider "null" {
89105
```
90106
Available targets:
91107
92-
help This help screen
108+
help Help screen
93109
help/all Display help for all targets
110+
help/short This help short screen
94111
lint Lint terraform code
95112
96113
```
@@ -99,6 +116,7 @@ Available targets:
99116

100117
| Name | Description | Type | Default | Required |
101118
|------|-------------|:----:|:-----:|:-----:|
119+
| artifact_type | The build output artifact's type. Valid values for this parameter are: CODEPIPELINE, NO_ARTIFACTS or S3. | string | `CODEPIPELINE` | no |
102120
| attributes | Additional attributes (e.g. `policy` or `role`) | list | `<list>` | no |
103121
| aws_account_id | (Optional) AWS Account ID. Used as CodeBuild ENV variable when building Docker images. For more info: http://docs.aws.amazon.com/codebuild/latest/userguide/sample-docker.html | string | `` | no |
104122
| aws_region | (Optional) AWS Region, e.g. us-east-1. Used as CodeBuild ENV variable when building Docker images. For more info: http://docs.aws.amazon.com/codebuild/latest/userguide/sample-docker.html | string | `` | no |
@@ -134,6 +152,13 @@ Available targets:
134152

135153

136154

155+
## Share the Love
156+
157+
Like this project? Please give it a ★ on [our GitHub](https://github.com/cloudposse/terraform-aws-codebuild)! (it helps us **a lot**)
158+
159+
Are you using this project or any of our other projects? Consider [leaving a testimonial][testimonial]. =)
160+
161+
137162
## Related Projects
138163

139164
Check out these related projects.
@@ -148,26 +173,38 @@ Check out these related projects.
148173

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

176+
[![README Commercial Support][readme_commercial_support_img]][readme_commercial_support_link]
177+
151178
## Commercial Support
152179

153180
Work directly with our team of DevOps experts via email, slack, and video conferencing.
154181

155182
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.
156183

157-
[![E-Mail](https://img.shields.io/badge/[email protected])](mailto:[email protected])
184+
[![E-Mail](https://img.shields.io/badge/[email protected])][email]
158185

159186
- **Questions.** We'll use a Shared Slack channel between your team and ours.
160187
- **Troubleshooting.** We'll help you triage why things aren't working.
161188
- **Code Reviews.** We'll review your Pull Requests and provide constructive feedback.
162189
- **Bug Fixes.** We'll rapidly work to fix any bugs in our projects.
163-
- **Build New Terraform Modules.** We'll develop original modules to provision infrastructure.
190+
- **Build New Terraform Modules.** We'll [develop original modules][module_development] to provision infrastructure.
164191
- **Cloud Architecture.** We'll assist with your cloud strategy and design.
165192
- **Implementation.** We'll provide hands-on support to implement our reference architectures.
166193

167194

168-
## Community Forum
169195

170-
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.
196+
## Terraform Module Development
197+
198+
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.
199+
200+
201+
## Slack Community
202+
203+
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.
204+
205+
## Newsletter
206+
207+
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.
171208

172209
## Contributing
173210

@@ -177,7 +214,7 @@ Please use the [issue tracker](https://github.com/cloudposse/terraform-aws-codeb
177214

178215
### Developing
179216

180-
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:[email protected]).
217+
If you are interested in being a contributor and want to get involved in developing this project or [help out](https://cpco.io/help-out) with our other projects, we would love to hear from you! Shoot us an [email][email].
181218

182219
In general, PRs are welcome. We follow the typical "fork-and-pull" Git workflow.
183220

@@ -192,7 +229,7 @@ In general, PRs are welcome. We follow the typical "fork-and-pull" Git workflow.
192229

193230
## Copyright
194231

195-
Copyright © 2017-2018 [Cloud Posse, LLC](https://cloudposse.com)
232+
Copyright © 2017-2018 [Cloud Posse, LLC](https://cpco.io/copyright)
196233

197234

198235

@@ -233,26 +270,16 @@ All other trademarks referenced herein are the property of their respective owne
233270

234271
## About
235272

236-
This project is maintained and funded by [Cloud Posse, LLC][website]. Like it? Please let us know at <[email protected]>
273+
This project is maintained and funded by [Cloud Posse, LLC][website]. Like it? Please let us know by [leaving a testimonial][testimonial]!
237274

238-
[![Cloud Posse](https://cloudposse.com/logo-300x69.svg)](https://cloudposse.com)
275+
[![Cloud Posse][logo]][website]
239276

240-
We're a [DevOps Professional Services][hire] company based in Los Angeles, CA. We love [Open Source Software](https://github.com/cloudposse/)!
277+
We're a [DevOps Professional Services][hire] company based in Los Angeles, CA. We ❤️ [Open Source Software][we_love_open_source].
241278

242-
We offer paid support on all of our projects.
279+
We offer [paid support][commercial_support] on all of our projects.
243280

244-
Check out [our other projects][github], [apply for a job][jobs], or [hire us][hire] to help with your cloud strategy and implementation.
281+
Check out [our other projects][github], [follow us on twitter][twitter], [apply for a job][jobs], or [hire us][hire] to help with your cloud strategy and implementation.
245282

246-
[docs]: https://docs.cloudposse.com/
247-
[website]: https://cloudposse.com/
248-
[github]: https://github.com/cloudposse/
249-
[commercial_support]: https://github.com/orgs/cloudposse/projects
250-
[jobs]: https://cloudposse.com/jobs/
251-
[hire]: https://cloudposse.com/contact/
252-
[slack]: https://slack.cloudposse.com/
253-
[linkedin]: https://www.linkedin.com/company/cloudposse
254-
[twitter]: https://twitter.com/cloudposse/
255-
[email]: mailto:[email protected]
256283

257284

258285
### Contributors
@@ -272,3 +299,36 @@ Check out [our other projects][github], [apply for a job][jobs], or [hire us][hi
272299
[sarkis_avatar]: https://github.com/sarkis.png?size=150
273300

274301

302+
303+
[![README Footer][readme_footer_img]][readme_footer_link]
304+
[![Beacon][beacon]][website]
305+
306+
[logo]: https://cloudposse.com/logo-300x69.svg
307+
[docs]: https://cpco.io/docs
308+
[website]: https://cpco.io/homepage
309+
[github]: https://cpco.io/github
310+
[jobs]: https://cpco.io/jobs
311+
[hire]: https://cpco.io/hire
312+
[slack]: https://cpco.io/slack
313+
[linkedin]: https://cpco.io/linkedin
314+
[twitter]: https://cpco.io/twitter
315+
[testimonial]: https://cpco.io/leave-testimonial
316+
[newsletter]: https://cpco.io/newsletter
317+
[email]: https://cpco.io/email
318+
[commercial_support]: https://cpco.io/commercial-support
319+
[we_love_open_source]: https://cpco.io/we-love-open-source
320+
[module_development]: https://cpco.io/module-development
321+
[terraform_modules]: https://cpco.io/terraform-modules
322+
[readme_header_img]: https://cloudposse.com/readme/header/img?repo=cloudposse/terraform-aws-codebuild
323+
[readme_header_link]: https://cloudposse.com/readme/header/link?repo=cloudposse/terraform-aws-codebuild
324+
[readme_footer_img]: https://cloudposse.com/readme/footer/img?repo=cloudposse/terraform-aws-codebuild
325+
[readme_footer_link]: https://cloudposse.com/readme/footer/link?repo=cloudposse/terraform-aws-codebuild
326+
[readme_commercial_support_img]: https://cloudposse.com/readme/commercial-support/img?repo=cloudposse/terraform-aws-codebuild
327+
[readme_commercial_support_link]: https://cloudposse.com/readme/commercial-support/link?repo=cloudposse/terraform-aws-codebuild
328+
[share_twitter]: https://twitter.com/intent/tweet/?text=terraform-aws-codebuild&url=https://github.com/cloudposse/terraform-aws-codebuild
329+
[share_linkedin]: https://www.linkedin.com/shareArticle?mini=true&title=terraform-aws-codebuild&url=https://github.com/cloudposse/terraform-aws-codebuild
330+
[share_reddit]: https://reddit.com/submit/?url=https://github.com/cloudposse/terraform-aws-codebuild
331+
[share_facebook]: https://facebook.com/sharer/sharer.php?u=https://github.com/cloudposse/terraform-aws-codebuild
332+
[share_googleplus]: https://plus.google.com/share?url=https://github.com/cloudposse/terraform-aws-codebuild
333+
[share_email]: mailto:?subject=terraform-aws-codebuild&body=https://github.com/cloudposse/terraform-aws-codebuild
334+
[beacon]: https://ga-beacon.cloudposse.com/UA-76589703-4/cloudposse/terraform-aws-codebuild?pixel&cs=github&cm=readme&an=terraform-aws-codebuild

docs/targets.md

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,8 +2,9 @@
22
```
33
Available targets:
44
5-
help This help screen
5+
help Help screen
66
help/all Display help for all targets
7+
help/short This help short screen
78
lint Lint terraform code
89
910
```

docs/terraform.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@
33

44
| Name | Description | Type | Default | Required |
55
|------|-------------|:----:|:-----:|:-----:|
6+
| artifact_type | The build output artifact's type. Valid values for this parameter are: CODEPIPELINE, NO_ARTIFACTS or S3. | string | `CODEPIPELINE` | no |
67
| attributes | Additional attributes (e.g. `policy` or `role`) | list | `<list>` | no |
78
| aws_account_id | (Optional) AWS Account ID. Used as CodeBuild ENV variable when building Docker images. For more info: http://docs.aws.amazon.com/codebuild/latest/userguide/sample-docker.html | string | `` | no |
89
| aws_region | (Optional) AWS Region, e.g. us-east-1. Used as CodeBuild ENV variable when building Docker images. For more info: http://docs.aws.amazon.com/codebuild/latest/userguide/sample-docker.html | string | `` | no |

main.tf

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -163,7 +163,7 @@ resource "aws_codebuild_project" "default" {
163163
service_role = "${aws_iam_role.default.arn}"
164164

165165
artifacts {
166-
type = "CODEPIPELINE"
166+
type = "${var.artifact_type}"
167167
}
168168

169169
# The cache as a list with a map object inside.

variables.tf

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -134,3 +134,9 @@ variable "source_location" {
134134
default = ""
135135
description = "The location of the source code from git or s3."
136136
}
137+
138+
variable "artifact_type" {
139+
type = "string"
140+
default = "CODEPIPELINE"
141+
description = "The build output artifact's type. Valid values for this parameter are: CODEPIPELINE, NO_ARTIFACTS or S3."
142+
}

0 commit comments

Comments
 (0)