-
Notifications
You must be signed in to change notification settings - Fork 9.6k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Make elasticache_subnet_group subnet_ids as required argument #2534
Conversation
Isn't it really optional for old EC2-Classic accounts which have no knowledge of subnets/VPCs? It feels like it would be really helpful to have a detection for EC2-Classic / VPC accounts in place, then we could do validation based on that. |
AFAIK this resource is designed for VPC-inside EC cluster only, and Subnet is a part of VPC.
Is it expected to create a new Subnet automatically when no subnet is specified? If that is so this is an another bug.
This EC2-classic/VPC validation you mentioned works at |
You're right: http://docs.aws.amazon.com/cli/latest/reference/elasticache/create-cache-subnet-group.html I don't know what happens if user tries using this in EC2 Classic... but like I said, we don't have validation yet in place anyway and more importantly that's not a subject of this PR. |
Thanks for noticing! 👍 cc @tmtk75 who originally created this resource. |
Overall it LGTM, I'm just giving some time to @tmtk75 to react in case he had some reasons to keep it optional. In case of no reaction, it will be merged. |
@radeksimko Hi, thanks a lot for your notice! I'm totally fine with this change 👍 |
Make elasticache_subnet_group subnet_ids as required argument
Great 👍 Thanks for merging ❗ |
I'm going to lock this issue because it has been closed for 30 days ⏳. This helps our maintainers find and focus on the active issues. If you have found a problem that seems similar to this, please open a new issue and complete the issue template so we can capture all the details necessary to investigate further. |
WHAT
Make elasticache_subnet_group
subnet_ids
as required argument.WHY
Terraform v0.5.3 describes that elasticache_subnet_group
subnet_ids
is optional argument.However, AWS API document (CreateCacheSubnetGroup - Amazon ElastiCache) describes that
subnet_ids
is required argument.I tried to create ElastiCache Subnet Group without
subnet_ids
with the below code:and then I got the the below error by
terraform apply
: