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

Fix logic to proxy S3 requests against *amazonaws.com #83

Merged
merged 2 commits into from
Oct 14, 2024
Merged

Conversation

whummer
Copy link
Member

@whummer whummer commented Oct 14, 2024

Fix logic to proxy S3 requests against *.s3.amazonaws.com requests.

Follow up for recent PR #80 , which introduced extraction of bucket names from hostnames in proxied requests. The previous PR only extracted the bucket from <bucket>.s3.localhost.localstack.cloud hosts, and with this PR we are now also supporting <bucket>.s3.amazonaws.com hosts. This can be required if, e.g., a request is being made from a Lambda using transparent endpoint injection.

A simple test has been added to cover the functionality - using a modified boto3 client that mimicks a local request using transparent endpoint injection, targeting the real AWS hostname locally.

@whummer whummer marked this pull request as ready for review October 14, 2024 23:18
@whummer whummer merged commit f10102f into main Oct 14, 2024
1 check passed
@whummer whummer deleted the s3-proxy-aws branch October 14, 2024 23:19
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant