-
Notifications
You must be signed in to change notification settings - Fork 338
Need to Explicitly set Swagger specs_url Scheme When Deployed on Behind AWS Elastic Load Balancer. #237
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
Comments
I hope your PR solves this with ease... Sharing here my solution. I solved this for AKS with these hacks. This requires that I explicitly set a APP_BASE_PATH settings variable. This ensures that if theres value, then its running behind an ingress controller with custom host path as base URL in SwaggerUI.
|
This is pr #238. I don't think I am able to add this as a linked issue. @rdagumampan : Let me know if this achieves what you are looking for. |
@rdagumampan : I see your point of providing a more general solution using the base url. I will revise accordingly, though I think I may expose the functionality a little differently to make it more integrated. |
@DustinMoriarty looking forward to it... I just got my hands on Python in last two weeks and lost few hairline on this so If I dont have to hack this way, that would be lovely :D |
closing with merge of #238 |
We have found that when we deploy to AWS ECS behind an elastic load balancer, we need to subclass the API class in order to explicitly set the scheme for the URL such that it sets an external URL instead of a relative URL. It would be preferable if this option was built into flask-restx itself.
I plan to submit a PR for this issue.
The text was updated successfully, but these errors were encountered: