Skip to content
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

[CLI] cdk deploy breaks when bootstrapping with --qualifier that is too large #9255

Closed
roskelleycj opened this issue Jul 25, 2020 · 0 comments · Fixed by #10121
Closed

[CLI] cdk deploy breaks when bootstrapping with --qualifier that is too large #9255

roskelleycj opened this issue Jul 25, 2020 · 0 comments · Fixed by #10121
Assignees
Labels
@aws-cdk/pipelines CDK Pipelines library effort/small Small work item – less than a day of effort feature-request A feature should be added or improved. good first issue Related to contributions. See CONTRIBUTING.md p2 package/tools Related to AWS CDK Tools or CLI

Comments

@roskelleycj
Copy link

roskelleycj commented Jul 25, 2020

Using a long qualifier name causes IAM error because the IAM Role name limit is 64 characters.

Use Case

I created a rather long name for my stack. And I used the --qualifier option as well and it was long to. This is because I like descriptive names in the various consoles that have resources created after the CDK is deployed. Besides the default qualifier of hnb659fds is kind of useless.

Proposed Solution

I would suggest that the --qualifier be limited to 9 characters and that it be checked before the bootstrap is executed and an error reported to the user.

For example a naive fix could be applied here by using Cloudformation's AllowedPatterns and ConstraintDescription

This is a 🚀 Feature Request

@roskelleycj roskelleycj added feature-request A feature should be added or improved. needs-triage This issue or PR still needs to be triaged. labels Jul 25, 2020
@github-actions github-actions bot added the @aws-cdk/pipelines CDK Pipelines library label Jul 25, 2020
@roskelleycj roskelleycj changed the title [cdk-pipelines] cdk deploy breaks when bootstrapping with --qualifier that is to large [cdk-bootstrap] cdk deploy breaks when bootstrapping with --qualifier that is to large Jul 25, 2020
@ericzbeard ericzbeard removed the needs-triage This issue or PR still needs to be triaged. label Jul 27, 2020
@njlynch njlynch removed their assignment Jul 31, 2020
@njlynch njlynch added package/tools Related to AWS CDK Tools or CLI and removed @aws-cdk/pipelines CDK Pipelines library labels Jul 31, 2020
@njlynch njlynch changed the title [cdk-bootstrap] cdk deploy breaks when bootstrapping with --qualifier that is to large [CLI] cdk deploy breaks when bootstrapping with --qualifier that is to large Jul 31, 2020
@shivlaks shivlaks changed the title [CLI] cdk deploy breaks when bootstrapping with --qualifier that is to large [CLI] cdk deploy breaks when bootstrapping with --qualifier that is too large Jul 31, 2020
@ericzbeard ericzbeard removed their assignment Aug 3, 2020
@rix0rrr rix0rrr added @aws-cdk/pipelines CDK Pipelines library effort/small Small work item – less than a day of effort good first issue Related to contributions. See CONTRIBUTING.md p2 labels Aug 4, 2020
rix0rrr added a commit that referenced this issue Sep 2, 2020
The qualifier has a quite restricted length. Validate the length (and
character set) of the qualifier that the user supplies.

Fixes #9255.
@mergify mergify bot closed this as completed in #10121 Sep 2, 2020
mergify bot pushed a commit that referenced this issue Sep 2, 2020
The qualifier has a quite restricted length. Validate the length (and
character set) of the qualifier that the user supplies.

Fixes #9255.


----

*By submitting this pull request, I confirm that my contribution is made under the terms of the Apache-2.0 license*
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
@aws-cdk/pipelines CDK Pipelines library effort/small Small work item – less than a day of effort feature-request A feature should be added or improved. good first issue Related to contributions. See CONTRIBUTING.md p2 package/tools Related to AWS CDK Tools or CLI
Projects
None yet
Development

Successfully merging a pull request may close this issue.

5 participants