Skip to content

Commit 0c20bf9

Browse files
authored
Support AWS Provider V5 (#28)
* Support AWS Provider V5 * Support AWS Provider V5 * updates * updates * updates
1 parent 4ffb68d commit 0c20bf9

File tree

11 files changed

+37
-62
lines changed

11 files changed

+37
-62
lines changed

.github/renovate.json

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,14 @@
11
{
22
"extends": [
33
"config:base",
4-
":preserveSemverRanges"
4+
":preserveSemverRanges",
5+
":rebaseStalePrs"
56
],
6-
"baseBranches": ["main", "master", "/^release\\/v\\d{1,2}$/"],
7+
"baseBranches": ["main"],
78
"labels": ["auto-update"],
89
"dependencyDashboardAutoclose": true,
910
"enabledManagers": ["terraform"],
1011
"terraform": {
11-
"ignorePaths": ["**/context.tf", "examples/**"]
12+
"ignorePaths": ["**/context.tf"]
1213
}
1314
}

.github/workflows/release-branch.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,7 @@ on:
1010
- 'docs/**'
1111
- 'examples/**'
1212
- 'test/**'
13+
- 'README.*'
1314

1415
permissions:
1516
contents: write

.github/workflows/release-published.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,4 +11,4 @@ permissions:
1111

1212
jobs:
1313
terraform-module:
14-
uses: cloudposse/github-actions-workflows-terraform-module/.github/workflows/release.yml@main
14+
uses: cloudposse/github-actions-workflows-terraform-module/.github/workflows/release-published.yml@main

README.md

Lines changed: 15 additions & 42 deletions
Original file line numberDiff line numberDiff line change
@@ -33,12 +33,6 @@ This module provisions AWS SSM Patch manager maintenance window tasks, targets,
3333
---
3434

3535
This project is part of our comprehensive ["SweetOps"](https://cpco.io/sweetops) approach towards DevOps.
36-
[<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]
37-
[<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]
38-
[<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]
39-
[<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]
40-
[<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]
41-
[<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]
4236

4337

4438
[![Terraform Open Source Modules](https://docs.cloudposse.com/images/terraform-open-source-modules.svg)][terraform_modules]
@@ -94,10 +88,6 @@ We highly recommend that in your code you pin the version to the exact version y
9488
using so that your infrastructure remains stable, and update versions in a
9589
systematic way so that they do not catch you by surprise.
9690

97-
Also, because of a bug in the Terraform registry ([hashicorp/terraform#21417](https://github.com/hashicorp/terraform/issues/21417)),
98-
the registry shows many of our inputs as required when in fact they are optional.
99-
The table below correctly indicates which inputs are required.
100-
10191

10292
For a complete example, see [examples/complete](examples/complete).
10393

@@ -139,7 +129,7 @@ Available targets:
139129

140130
| Name | Version |
141131
|------|---------|
142-
| <a name="requirement_terraform"></a> [terraform](#requirement\_terraform) | >= 1.0 |
132+
| <a name="requirement_terraform"></a> [terraform](#requirement\_terraform) | >= 1.3 |
143133
| <a name="requirement_aws"></a> [aws](#requirement\_aws) | >= 4.0 |
144134

145135
## Providers
@@ -154,7 +144,7 @@ Available targets:
154144
|------|--------|---------|
155145
| <a name="module_install_window_label"></a> [install\_window\_label](#module\_install\_window\_label) | cloudposse/label/null | 0.25.0 |
156146
| <a name="module_scan_window_label"></a> [scan\_window\_label](#module\_scan\_window\_label) | cloudposse/label/null | 0.25.0 |
157-
| <a name="module_ssm_patch_log_s3_bucket"></a> [ssm\_patch\_log\_s3\_bucket](#module\_ssm\_patch\_log\_s3\_bucket) | cloudposse/s3-bucket/aws | 2.0.0 |
147+
| <a name="module_ssm_patch_log_s3_bucket"></a> [ssm\_patch\_log\_s3\_bucket](#module\_ssm\_patch\_log\_s3\_bucket) | cloudposse/s3-bucket/aws | 3.1.2 |
158148
| <a name="module_ssm_patch_log_s3_bucket_label"></a> [ssm\_patch\_log\_s3\_bucket\_label](#module\_ssm\_patch\_log\_s3\_bucket\_label) | cloudposse/label/null | 0.25.0 |
159149
| <a name="module_this"></a> [this](#module\_this) | cloudposse/label/null | 0.25.0 |
160150

@@ -252,8 +242,6 @@ Available targets:
252242

253243
Like this project? Please give it a ★ on [our GitHub](https://github.com/cloudposse/terraform-aws-ssm-patch-manager)! (it helps us **a lot**)
254244

255-
Are you using this project or any of our other projects? Consider [leaving a testimonial][testimonial]. =)
256-
257245

258246

259247
## Related Projects
@@ -307,10 +295,6 @@ We deliver 10x the value for a fraction of the cost of a full-time engineer. Our
307295

308296
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.
309297

310-
## Discourse Forums
311-
312-
Participate in our [Discourse Forums][discourse]. Here you'll find answers to commonly asked questions. Most questions will be related to the enormous number of projects we support on our GitHub. Come here to collaborate on answers, find solutions, and get ideas about the products and services we value. It only takes a minute to get started! Just sign in with SSO using your GitHub account.
313-
314298
## Newsletter
315299

316300
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.
@@ -321,7 +305,18 @@ Sign up for [our newsletter][newsletter] that covers everything on our technolog
321305

322306
[![zoom](https://img.cloudposse.com/fit-in/200x200/https://cloudposse.com/wp-content/uploads/2019/08/Powered-by-Zoom.png")][office_hours]
323307

324-
## Contributing
308+
## ✨ Contributing
309+
310+
311+
312+
This project is under active development, and we encourage contributions from our community.
313+
Many thanks to our outstanding contributors:
314+
315+
<a href="https://github.com/cloudposse/terraform-aws-ssm-patch-manager/graphs/contributors">
316+
<img src="https://contrib.rocks/image?repo=cloudposse/terraform-aws-ssm-patch-manager&max=24" />
317+
</a>
318+
319+
325320

326321
### Bug Reports & Feature Requests
327322

@@ -398,21 +393,7 @@ We're a [DevOps Professional Services][hire] company based in Los Angeles, CA. W
398393

399394
We offer [paid support][commercial_support] on all of our projects.
400395

401-
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.
402-
403-
404-
405-
### Contributors
406-
407-
<!-- markdownlint-disable -->
408-
| [![PePe Amengual][jamengual_avatar]][jamengual_homepage]<br/>[PePe Amengual][jamengual_homepage] |
409-
|---|
410-
<!-- markdownlint-restore -->
411-
412-
[jamengual_homepage]: https://github.com/jamengual
413-
[jamengual_avatar]: https://img.cloudposse.com/150x150/https://github.com/jamengual.png
414-
415-
[![README Footer][readme_footer_img]][readme_footer_link]
396+
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.[![README Footer][readme_footer_img]][readme_footer_link]
416397
[![Beacon][beacon]][website]
417398
<!-- markdownlint-disable -->
418399
[logo]: https://cloudposse.com/logo-300x69.svg
@@ -422,12 +403,10 @@ Check out [our other projects][github], [follow us on twitter][twitter], [apply
422403
[jobs]: https://cpco.io/jobs?utm_source=github&utm_medium=readme&utm_campaign=cloudposse/terraform-aws-ssm-patch-manager&utm_content=jobs
423404
[hire]: https://cpco.io/hire?utm_source=github&utm_medium=readme&utm_campaign=cloudposse/terraform-aws-ssm-patch-manager&utm_content=hire
424405
[slack]: https://cpco.io/slack?utm_source=github&utm_medium=readme&utm_campaign=cloudposse/terraform-aws-ssm-patch-manager&utm_content=slack
425-
[linkedin]: https://cpco.io/linkedin?utm_source=github&utm_medium=readme&utm_campaign=cloudposse/terraform-aws-ssm-patch-manager&utm_content=linkedin
426406
[twitter]: https://cpco.io/twitter?utm_source=github&utm_medium=readme&utm_campaign=cloudposse/terraform-aws-ssm-patch-manager&utm_content=twitter
427407
[testimonial]: https://cpco.io/leave-testimonial?utm_source=github&utm_medium=readme&utm_campaign=cloudposse/terraform-aws-ssm-patch-manager&utm_content=testimonial
428408
[office_hours]: https://cloudposse.com/office-hours?utm_source=github&utm_medium=readme&utm_campaign=cloudposse/terraform-aws-ssm-patch-manager&utm_content=office_hours
429409
[newsletter]: https://cpco.io/newsletter?utm_source=github&utm_medium=readme&utm_campaign=cloudposse/terraform-aws-ssm-patch-manager&utm_content=newsletter
430-
[discourse]: https://ask.sweetops.com/?utm_source=github&utm_medium=readme&utm_campaign=cloudposse/terraform-aws-ssm-patch-manager&utm_content=discourse
431410
[email]: https://cpco.io/email?utm_source=github&utm_medium=readme&utm_campaign=cloudposse/terraform-aws-ssm-patch-manager&utm_content=email
432411
[commercial_support]: https://cpco.io/commercial-support?utm_source=github&utm_medium=readme&utm_campaign=cloudposse/terraform-aws-ssm-patch-manager&utm_content=commercial_support
433412
[we_love_open_source]: https://cpco.io/we-love-open-source?utm_source=github&utm_medium=readme&utm_campaign=cloudposse/terraform-aws-ssm-patch-manager&utm_content=we_love_open_source
@@ -438,11 +417,5 @@ Check out [our other projects][github], [follow us on twitter][twitter], [apply
438417
[readme_footer_link]: https://cloudposse.com/readme/footer/link?utm_source=github&utm_medium=readme&utm_campaign=cloudposse/terraform-aws-ssm-patch-manager&utm_content=readme_footer_link
439418
[readme_commercial_support_img]: https://cloudposse.com/readme/commercial-support/img
440419
[readme_commercial_support_link]: https://cloudposse.com/readme/commercial-support/link?utm_source=github&utm_medium=readme&utm_campaign=cloudposse/terraform-aws-ssm-patch-manager&utm_content=readme_commercial_support_link
441-
[share_twitter]: https://twitter.com/intent/tweet/?text=terraform-aws-ssm-patch-manager&url=https://github.com/cloudposse/terraform-aws-ssm-patch-manager
442-
[share_linkedin]: https://www.linkedin.com/shareArticle?mini=true&title=terraform-aws-ssm-patch-manager&url=https://github.com/cloudposse/terraform-aws-ssm-patch-manager
443-
[share_reddit]: https://reddit.com/submit/?url=https://github.com/cloudposse/terraform-aws-ssm-patch-manager
444-
[share_facebook]: https://facebook.com/sharer/sharer.php?u=https://github.com/cloudposse/terraform-aws-ssm-patch-manager
445-
[share_googleplus]: https://plus.google.com/share?url=https://github.com/cloudposse/terraform-aws-ssm-patch-manager
446-
[share_email]: mailto:?subject=terraform-aws-ssm-patch-manager&body=https://github.com/cloudposse/terraform-aws-ssm-patch-manager
447420
[beacon]: https://ga-beacon.cloudposse.com/UA-76589703-4/cloudposse/terraform-aws-ssm-patch-manager?pixel&cs=github&cm=readme&an=terraform-aws-ssm-patch-manager
448421
<!-- markdownlint-restore -->

docs/terraform.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33

44
| Name | Version |
55
|------|---------|
6-
| <a name="requirement_terraform"></a> [terraform](#requirement\_terraform) | >= 1.0 |
6+
| <a name="requirement_terraform"></a> [terraform](#requirement\_terraform) | >= 1.3 |
77
| <a name="requirement_aws"></a> [aws](#requirement\_aws) | >= 4.0 |
88

99
## Providers
@@ -18,7 +18,7 @@
1818
|------|--------|---------|
1919
| <a name="module_install_window_label"></a> [install\_window\_label](#module\_install\_window\_label) | cloudposse/label/null | 0.25.0 |
2020
| <a name="module_scan_window_label"></a> [scan\_window\_label](#module\_scan\_window\_label) | cloudposse/label/null | 0.25.0 |
21-
| <a name="module_ssm_patch_log_s3_bucket"></a> [ssm\_patch\_log\_s3\_bucket](#module\_ssm\_patch\_log\_s3\_bucket) | cloudposse/s3-bucket/aws | 2.0.0 |
21+
| <a name="module_ssm_patch_log_s3_bucket"></a> [ssm\_patch\_log\_s3\_bucket](#module\_ssm\_patch\_log\_s3\_bucket) | cloudposse/s3-bucket/aws | 3.1.2 |
2222
| <a name="module_ssm_patch_log_s3_bucket_label"></a> [ssm\_patch\_log\_s3\_bucket\_label](#module\_ssm\_patch\_log\_s3\_bucket\_label) | cloudposse/label/null | 0.25.0 |
2323
| <a name="module_this"></a> [this](#module\_this) | cloudposse/label/null | 0.25.0 |
2424

examples/complete/main.tf

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,20 +1,20 @@
11
module "vpc" {
22
source = "cloudposse/vpc/aws"
3-
version = "0.25.0"
3+
version = "2.1.0"
44

5-
cidr_block = "172.16.0.0/16"
5+
ipv4_primary_cidr_block = "172.16.0.0/16"
66

77
context = module.this.context
88
}
99

1010
module "subnets" {
1111
source = "cloudposse/dynamic-subnets/aws"
12-
version = "0.39.3"
12+
version = "2.4.1"
1313

1414
availability_zones = ["us-east-2a", "us-east-2b"]
1515
vpc_id = module.vpc.vpc_id
16-
igw_id = module.vpc.igw_id
17-
cidr_block = module.vpc.vpc_cidr_block
16+
igw_id = [module.vpc.igw_id]
17+
ipv4_cidr_block = [module.vpc.vpc_cidr_block]
1818
nat_gateway_enabled = true
1919
nat_instance_enabled = false
2020

examples/complete/versions.tf

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
terraform {
2-
required_version = ">= 1.0"
2+
required_version = ">= 1.3"
33

44
required_providers {
55
aws = {

main.tf

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,7 @@ resource "aws_ssm_maintenance_window_task" "task_scan_patches" {
3939

4040
targets {
4141
key = "WindowTargetIds"
42-
values = aws_ssm_maintenance_window_target.target_scan.*.id
42+
values = aws_ssm_maintenance_window_target.target_scan[*].id
4343
}
4444

4545
task_invocation_parameters {
@@ -121,7 +121,7 @@ resource "aws_ssm_maintenance_window_task" "task_install_patches" {
121121

122122
targets {
123123
key = "WindowTargetIds"
124-
values = aws_ssm_maintenance_window_target.target_install.*.id
124+
values = aws_ssm_maintenance_window_target.target_install[*].id
125125
}
126126

127127
task_invocation_parameters {

outputs.tf

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,11 @@
11
output "ssm_patch_log_s3_bucket_id" {
22
description = "SSM Patch Manager s3 log bucket ID"
3-
value = local.create_log_bucket ? join("", module.ssm_patch_log_s3_bucket.*.bucket_id) : ""
3+
value = local.create_log_bucket ? join("", module.ssm_patch_log_s3_bucket[*].bucket_id) : ""
44
}
55

66
output "ssm_patch_log_s3_bucket_arn" {
77
description = "SSM Patch Manager s3 log bucket ARN"
8-
value = local.create_log_bucket ? join("", module.ssm_patch_log_s3_bucket.*.bucket_arn) : ""
8+
value = local.create_log_bucket ? join("", module.ssm_patch_log_s3_bucket[*].bucket_arn) : ""
99
}
1010

1111
output "scan_maintenance_window_task_id" {

ssm_log_bucket.tf

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
locals {
2-
account_id = join("", data.aws_caller_identity.current.*.account_id)
3-
aws_partition = join("", data.aws_partition.current.*.partition)
2+
account_id = join("", data.aws_caller_identity.current[*].account_id)
3+
aws_partition = join("", data.aws_partition.current[*].partition)
44
create_log_bucket = local.enabled && var.bucket_id == null
55
bucket_id = var.bucket_id != null ? var.bucket_id : module.ssm_patch_log_s3_bucket_label.id
66
bucket_policy = var.ssm_bucket_policy != null ? var.ssm_bucket_policy : try(data.aws_iam_policy_document.bucket_policy[0].json, "")
@@ -41,7 +41,7 @@ data "aws_iam_policy_document" "bucket_policy" {
4141
module "ssm_patch_log_s3_bucket" {
4242
count = local.create_log_bucket ? 1 : 0
4343
source = "cloudposse/s3-bucket/aws"
44-
version = "2.0.0"
44+
version = "3.1.2"
4545

4646
acl = "private"
4747
versioning_enabled = var.ssm_bucket_versioning_enable

0 commit comments

Comments
 (0)