<p>My application that is hosted on OpenShift has a route with a URL that looks like this:</p>
<p><a href="https://books-student-book-reservation-backend-project.apps.amarige.hostname.us" rel="nofollow noreferrer">https://books-student-book-reservation-backend-project.apps.amarige.hostname.us</a></p>
<p>I want to give end users a URL that looks like this: <a href="https://breeze.us" rel="nofollow noreferrer">https://breeze.us</a>. First it hides the OpenShift URL structure, second it is easier to remember. Bottom line it's more user friendly.</p>
<p>The challenge is that when I redirect breeze.us to the OpenShift route, I get &quot;Application is not available&quot; error from OpenShift.</p>
<p>Any suggestion on how to resolve this?</p>

Billy Billy
<p><a href="https://docs.openshift.com/online/pro/dev_guide/routes.html#custom-route-and-hosts-and-certificates-restrictions" rel="nofollow noreferrer">https://docs.openshift.com/online/pro/dev_guide/routes.html#custom-route-and-hosts-and-certificates-restrictions</a></p>
<h1>If you are using OpenShift Online</h1>
<p>In OpenShift Online Starter, custom hostname is not permitted.  You can either buy OpenShift Online Pro (which allows custom hostname to be set), or use a reverse proxy to redirect your traffic (from another server with the custom hostname) to OpenShift.</p>
<h1>If you are using self-deployed OKD</h1>
<p>You can set a custom hostname for your route like this:</p>
<pre class="lang-yaml prettyprint-override"><code># A example unsecured route with custom hostname
apiVersion: v1
kind: Route
metadata:
  name: route-unsecured
spec:
  host: www.your-custom-hostname.com  # here
  to:
    kind: Service
    name: service-name
</code></pre>
<p>If you need to serve multiple routes under the same hostname, you can also do path-based route with custom hostname:</p>
<pre class="lang-yaml prettyprint-override"><code># A example unsecured path-based route with custom hostname
apiVersion: v1
kind: Route
metadata:
  name: route-unsecured
spec:
  host: www.your-custom-hostname.com
  path: &quot;/test&quot;      # here
  to:
    kind: Service
    name: service-name
</code></pre>
<p>So that you can use <code>www.your-custom-hostname.com/test</code> to access your route.</p>
