# Domain does not route to service

**URL:** <https://forums.suse.com/t/domain-does-not-route-to-service/16200>\
**Category:** Rio\
**Created:** [January 2, 2020, 2:47pm UTC](https://forums.suse.com/t/domain-does-not-route-to-service/16200 "2020-01-02T14:47:15Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![movonw](https://sea2.discourse-cdn.com/flex022/user_avatar/forums.suse.com/movonw/32/5953_2.png) [@movonw](https://forums.suse.com/u/movonw)\
**Post date:** [January 2, 2020, 2:47pm UTC](https://forums.suse.com/t/domain-does-not-route-to-service/16200/1 "2020-01-02T14:47:15Z")

</div>

(I had to change http and https to httpX and httpsX because forum will not let me post so many links 🙂)  
Adding custom domain to a service does not work for me.  
I have a test apache service running:

```
root@bog2 ~$ rio ps
NAME IMAGE ENDPOINT PORTS SCALE WEIGHT CREATED DETAIL
apache httpd:2.4 httpsX://apache-v0-default.lemhib.on-rio.io:31546 80 1 100% 14 minutes ago

```

I have created the router and registered a domain (it’s a CNAME for same host) for it

```
rio route add bb to apache
rio domain register hello.cahoots.pl router/bb
root@bog2 ~$ rio route  
NAME URL OPTS ACTION TARGET
router/bb https://bb-default.lemhib.on-rio.io:31546,https://hello.cahoots.pl to apache,port=80

```

This looks okay but I can only use first domain, not the hello.cahoots.pl to access the site. I returns 404 not found. What am I doing wrong?

When I inspect the apache service, it only has endpoints with [on-rio.io](http://on-rio.io) domain:

```
rio inspect apache                                                                                                                                                                                   

```

* * *

apiVersion: [rio.cattle.io/v1](http://rio.cattle.io/v1)  
kind: Service  
metadata:  
creationTimestamp: “2020-01-02T14:02:03Z”  
generateName: apache-v0  
generation: 1  
name: apache-v0hbdgb  
namespace: default  
resourceVersion: “42546”  
selfLink: /apis/rio.cattle.io/v1/namespaces/default/services/apache-v0hbdgb  
uid: cff4bf3e-b43d-4d05-87b2-14ec17b90c11  
spec:  
app: apache  
image: httpd:2.4  
ports:

- port: 80  
targetPort: 80  
version: v0  
volumes:
- hostpath: /data/doc  
path: /usr/local/apache2/htdocs  
status:  
appEndpoints:
- httpsX://apache-default.lemhib.on-rio.io:31546
- httpX://apache-default.lemhib.on-rio.io:32680  
buildLogToken: q9rrjkmz85b5xqdj5gpfvz4r7tv9sr8tw4m656md979wb67smcc2n7  
computedApp: apache  
computedVersion: v0  
computedWeight: 100  
conditions:
- lastUpdateTime: “2020-01-02T14:02:03Z”  
status: “True”  
type: BuildDeployed
- lastUpdateTime: “2020-01-02T14:02:04Z”  
status: “True”  
type: ServiceDeployed
- lastUpdateTime: “2020-01-02T14:02:04Z”  
status: “True”  
type: ServiceClusterRBAC  
deploymentReady: true  
endpoints:
- httpsX://apache-v0-default.lemhib.on-rio.io:31546
- httpX://apache-v0-default.lemhib.on-rio.io:32680  
scaleStatus:  
available: 1
