-
-
Notifications
You must be signed in to change notification settings - Fork 132
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
Add an example showing how to use nginx as a reverse proxy. #140
Conversation
Thanks! I just started an |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ok, looks good now! Thanks!
Apart from the two nits, the main remaining question is: do we have license/usage and source information for the OCaml logo used in this example?
By comparison, example w-one-binary
uses a silly picture of OCaml, and "serves" together with it a README.md that says:
The camel image is taken from pixabay.com. The license
states:Free for commercial use
No attribution required
Since we don't have a separate directory in this example to put a README in, we could just put the corresponding info for the OCaml logo into a different file (or make an assets
directory like in w-one-binary
).
I've added |
Thanks! |
This change addresses Issue #98 by adding a new example showing how to use nginx as a reverse proxy together with Dream. To simplify setup, both nginx and the example server run in docker containers managed by docker compose. In the example, we show how to use nginx to handle requests for static assets so that that traffic never reaches the application server.
Issue #98 mentions security concerns around respecting proxy headers. The example introduced here doesn't cover those concerns so it won't allow #98 to be closed but may serve as a useful starting point for running those kinds of tests in the future.