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

Read IP through Traefik #33

Open
JAP42 opened this issue Jul 13, 2019 · 1 comment
Open

Read IP through Traefik #33

JAP42 opened this issue Jul 13, 2019 · 1 comment

Comments

@JAP42
Copy link

JAP42 commented Jul 13, 2019

Wondering what headers would need to be passed for this to work through a traefik proxy. Right now unless I specify an IP it gets set to the internal traefik network IP. I tried a few things but nothing is working. I think something might need to be changed on the software side also.

@dstapp
Copy link
Owner

dstapp commented Jul 18, 2019

Hey, thanks for the request. The correct way of handling this would be using the X-Forwarded-For header where traefik would provide the requests origin IP address. However this is currently not handled since I only use r.RemoteAddr (https://github.com/dprandzioch/docker-ddns/blob/c9956b795ba7689e9dfd8ac260831ffe4873054e/rest-api/request_handler.go#L56 ).

When I have some spare time I can change this but unfortunately it will take some time until I get to it.

If someone wants to provide a pull request it will be much faster ;)

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

No branches or pull requests

2 participants