[Cloudflare Tunnel] Two "Published application" from two Tunnels instances, under one domain
Let's say I have 2 locations, "My home" and "My parent's home", and I have created two Tunnels instances. And both location run an application (let's called them
my-nas
and parents-adguardhome
).
Is it possible to host those 2 applications under one domain homelab.example.com
, i.e.:
I have tried to setup 2 "Published application" from 2 Tunnel instances with the same domain, I got the following error message:
So does it means two tunnel instances can't share one domain (in this case homelab.example.com
) using different path? If so, will this behavior be changed in the future? Or are there any workarounds? Or I will have to use different subdomains for each Tunnel instances?
4 Replies
Feedback
Feedback has been submitted! Thank you :)
After some thought, the current behavior makes some sense: every Tunnel instance will have its own
*.cfargotunnel.com
CNAME, so it is impossible for one subdomain to have 2 different CNAME records.
But I am still interested in if there is any workarounds.Maybe you could look at origin rules?
https://developers.cloudflare.com/rules/origin-rules/features/#dns-record
https://blog.cloudflare.com/origin-rules/
The Cloudflare Blog
Where to? Introducing Origin Rules
Origin Rules is a dedicated product for ‘where does this traffic go where it leaves Cloudflare.’ Customers are able to match on an HTTP request using filters and override the host, port, SNI, and the origin a request resolves to.
Cloudflare Docs
Origin Rules settings
The following sections describe the available settings in Origin Rules.


Maybe you could also try page rules?
https://developers.cloudflare.com/rules/page-rules/
https://developers.cloudflare.com/rules/page-rules/manage/
Cloudflare Docs
Page Rules
Page Rules trigger one or more actions whenever a certain URL pattern is matched. Page Rules are available in Rules > Page Rules.