Feature request: ability to set oauth2RedirectUrl using env vars in Docker
See original GitHub issueCurrently, docker-run.sh sed’s out some placeholders in index.html for env vars that are set when running swagger-ui as a Docker container. This is great; however, there’s a need to be able to set oauth2RedirectUrl in an environment variable as well – as right now this is ‘baked in’ to http://localhost:3200/oauth2-redirect.html .
In #2844 @bodnia suggests changing the constructor of SwaggerUIBundle, which I could obviously do; however, I’d rather use the stock image as it is.
Have you had any thoughts about exposing the config in swagger-config.yaml to environment variables?
Issue Analytics
- State:
- Created 6 years ago
- Reactions:1
- Comments:12 (7 by maintainers)
Top Results From Across the Web
Environment variables in Compose | Docker Documentation
How to set, use and manage environment variables in Compose. ... The .env file feature only works when you use the docker-compose up...
Read more >Configuration - Swagger Documentation
How to configure. Swagger UI accepts configuration parameters in four locations. From lowest to highest precedence: The swagger-config.yaml in the ...
Read more >How to use environment variables in docker-compose?
If an environment variable is not set, Compose substitutes with an empty string. ... The feature was added in this pull request.
Read more >GitLab CI/CD variables
A variable of type File : KUBE_CA_PEM with a certificate as the value. Use the variables in a job script like this: kubectl...
Read more >Docker ARG, ENV and .env - a Complete Guide - vsupalov.com
Read on and you will understand how to configure your Docker images and dockerized apps with ease - with the power of Docker...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found

Ah cool thanks @bodnia @webron – it should do what I want! Sorry that I missed that – might be worth explicitly mentioning that in the readme so that lazy people like me who are searching the repo for terms such as
oauth2RedirectUrlwill find what they’re looking for 😄I’ll close the issue for now, but if I run into any problems, I’ll come back
Yeah, I believe that should work, but you know… test, test, test 😉