fastapi-saml icon indicating copy to clipboard operation
fastapi-saml copied to clipboard

http_host issue when running under docker

Open giesberge opened this issue 4 years ago • 3 comments

If you use request.client.host you'll get the ip of the server if you're running in docker and it will fail requests. Its probably better to use request.url.hostname unless you think otherwise

giesberge avatar Jul 10 '21 16:07 giesberge

ok let me check on that!

ais-one avatar Sep 15 '21 13:09 ais-one

I spent days trying to figure out how to run this in Docker. Changing request.client.host to request.url.hostname as suggested by @giesberge solves the issue of an invalid SAML ACS post request due to a difference in hosts.

mrestay avatar Jan 25 '22 00:01 mrestay

@mrestay I had forgotten about this repo for awhile, let me include the findings from @giesberge in the README.md and I will also try out this using Docker.

ais-one avatar Jan 25 '22 00:01 ais-one