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

allowed_hosts #91

Closed
jfmatth opened this issue Jun 16, 2017 · 2 comments
Closed

allowed_hosts #91

jfmatth opened this issue Jun 16, 2017 · 2 comments

Comments

@jfmatth
Copy link
Contributor

jfmatth commented Jun 16, 2017

In Openshift2 I used to set allowed_hosts to an environment variable called OPENSHIFT_APP_DNS, but now I notice that you have used * in it's place.

Do we think this is safe since we are in a dedicated container now?

Just wanted to check.

thanks,

@bparees
Copy link
Contributor

bparees commented Jun 16, 2017

no, it's that we don't know the host you're going to expose the application on. it's determined by the route you create, and in turn the route's hostname is determined by the project name and other dynamic pieces (unless you control the DNS and can set an explicit route name).

you are to some degree protected by the router in that a request is unlikely to get to your app unless you defined a route that points to it and someone sent a request to that route w/ the proper host header, but that is not a guarantee. If you really care about this, you will want to set the value yourself. But the value to set it to is not available as an env variable inside the application because, again, in v3 the route is decoupled from the application, unlike in v2 when they were tightly coupled.

@bparees bparees closed this as completed Jun 16, 2017
@jfmatth
Copy link
Contributor Author

jfmatth commented Jun 16, 2017

Thanks Ben, that makes sense.

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