zappa / Zappa

Serverless Python
https://zappa.ws/zappa
MIT License
3.31k stars 363 forks source link

[Migrated] Feature/passing source ip #470

Closed jneves closed 6 months ago

jneves commented 3 years ago

Originally from: https://github.com/Miserlou/Zappa/issues/1249 by danielwhatmuff

Description

Passing env var for the $context.identity.sourceIp

http://docs.aws.amazon.com/apigateway/latest/developerguide/api-gateway-mapping-template-reference.html#context-variable-reference

GitHub Issues

Fairly small change discussed in slack but let me know if you want an issue for further discussion.

monkut commented 1 year ago

I don't see a problem adding the lambda context sourceIP, but currently the client IP should be available in "REMOTE_ADDR".

https://github.com/zappa/Zappa/blob/master/zappa/wsgi.py#L89-L96

github-actions[bot] commented 7 months ago

Hi there! Unfortunately, this Issue has not seen any activity for at least 90 days. If the Issue is still relevant to the latest version of Zappa, please comment within the next 10 days if you wish to keep it open. Otherwise, it will be automatically closed.

github-actions[bot] commented 6 months ago

Hi there! Unfortunately, this Issue was automatically closed as it had not seen any activity in at least 100 days. If the Issue is still relevant to the latest version of Zappa, please open a new Issue.