-
-
Notifications
You must be signed in to change notification settings - Fork 4.2k
Added ARN support for get-parameter and get-parameters in SSM #11082
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
base: main
Are you sure you want to change the base?
Conversation
I have read the CLA Document and I hereby sign the CLA wbeardall seems not to be a GitHub user. You need a GitHub account to be able to sign the CLA. If you have already a GitHub account, please add the email address used for this commit to your account. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Welcome to LocalStack! Thanks for raising your first Pull Request and landing in your contributions. Our team will reach out with any reviews or feedbacks that we have shortly. We recommend joining our Slack Community and share your PR on the #community channel to share your contributions with us. Please make sure you are following our contributing guidelines and our Code of Conduct.
I have read the CLA Document and I hereby sign the CLA |
Note: Need to fix my test environment, as the provided instructions haven't worked on my machine. Will update when I have time. |
Hi @wbeardall !
Anything we can help with there? What's was the issue exactly? |
Hi @dominikschubert, I'm afraid I haven't had time to dig into this further; I'll try and circle back to this at some point! |
Fix to #11048
Motivation
Adding correct validation for ARN inputs to
ssm get-parameter
andssm get-parameters
Changes
Adds an internal validation method to
localstack.services.ssm.provider.SSMProvider
(._normalize_name_or_arn
) which validates either ARNs or parameter names, and throws errors consistent with the AWS implementation (to the best of my knowledge).Testing
TestSSM.test_get_parameter_by_arn
TODO
^arn:aws:.+:.+:.+:.+$
aws ssm get-parameter --name arn:
aws ssm get-parameter --name arn:aws:service:incorrect-region:0000000000:parameter/myparam
service
in the above isssm
; the following passes validation:aws ssm get-parameter --name arn:aws:service:us-east-1:0000000000:parameter/myparam
)