Q: Service with multiple ports/protocols per route (e.g. HTTP and HTTPS) possible in OpenShift?
I am currently investigating OpenShift for use in our company. We have a web application in a container, which exposes both port 80 http and port 443 https. Is it possible to run this container in OpenShift, using both ports over the SAME hostname? The OpenShift GUI lets me select only one port per service, if I try to create a route, and either http or https, not both. My use-case is, that my application is reachable on http://my-app as well as on https://my-app (in my opinion a quite common use-case)
It is not possible to have multiple routes with the same hostname and path. Only first such route will be admitted to the router. The routes with paths will work as mentioned by #Graham You can put all 3 below in a single project without problem: example.com example.com/hello example.com/world They can have different protocols. Adding a duplicate route with different protocol will not work. Additionally if you have Project B, you won't be able to use example.com host again. So, none of the below will be accepted to a router: example.com example.com/hello example.com/world example.com/path Which makes sense, as you don't want someone else to use your domain. What usually happens when you have https exposed is that all http traffic is redirected to https. You can achieve it by creating edge terminated route (over UI) and selecting Insecure Traffic: Redirect. There is also an option to set it to Allow. More documentation and yaml examples if you would like to create route from command line: OpenShift Origin: Secured routes
How does inter-gear networking security work in OpenShift?
How to contact an external server from OpenShift
How to install ioncube Loader on openshift
Does OpenShift Online provide an API to manage apps?
Cannot git-clone an OpenShift application
what is difference between environment variable types
Openshift authenticity of host cant be established, when creating app
Update composer.phar on Openshift
How can I tell if my OpenShift application has been deleted?
openshift : need to edit httpd.conf to enable or add directive according to my needs but it's not work
What can I do as OpenShift user?
Install Atlassian Stash on Openshift
Alternative ways to deploy code to Openshift
How to get phpmyadmin credentials of application in openshift
Using openshift rhc tail command
openshift application url returns 404 error