node.js - Original IP not passed to container on single container Docker image on AWS Elastic Beanstalk -
i have node.js server inside docker container on aws elastic beanstalk. have noticed if try access user's ip address via request headers, don't user's actual remote ip address. instead seems ip address of docker container - 172.19.0.1
.
i'm sure there simple how docker or elastic beanstalk configured need change desired behaviour - don't know needs change.
something in dockerfile? flag or in docker build
command before push & deploy container? configuration on aws in elb or elastic beanstalk?
would appreciate pointers on start!
with hapi node.js, request headers not available request.info
request.headers
. using request.info
returns network level informations. should use request.headers[ 'x-forwarded-for' ]
request level informations. try displaying request.headers
key-value pairs discover key linked value containing ip address want find.
Comments
Post a Comment