Multiple domains

In the past, I have used one domain name for Nextcloud, music servers, etc., and another for my website and for comms.

I have found several references to the settings handling of domain names in the manual and FAQs, but haven’t been able to establish whether it is possible to attach two domain names to a FBX and then apply them to separate apps. Is this possible?

I have a static IP.

Apache virtual host is one tool. That will set the URL based on the hostname of the request.

You can have multiple hostnames and SSL certificates for your FreedomBox. I have something like this:

  • a dynamic DNS host name with FreedomBox DDNS service which gets my external interface address into DNS directory
  • a CNAME in my domain that points to the FreedomBox DDNS host name

Both have a let’s encrypt certificate and you can connect using either DNS name.

2 Likes

Of course! Apache Virtual Host! I’ve gone down a Freedom box research tunnel and not sat back and thought it through.

Thank you.

@danceswithcats Adding multiple static domain names (domains which you have purchased and have control over) to FreedomBox can be achieved by going to System → Name Services and adding “regular domains”. For dynamic domains (like mydomain.fbx.one) you can do so from System → Dynamic DNS. Currently, there can be only one Tor .onion domain and only one Pagekite domain.

When multiple domains are present, FreedomBox will configure Apache to respond to all of them using virtual host configuration and obtain/maintain TLS certificates for all of them. Applications also become available each of the domains automatically.

Assigning apps to a specific domain is not supported yet. Some apps (like Matrix Synapse) only work (or work better) with one domain and in those cases, we allow selecting a single domain from app’s configuration page.

Assigning apps to only work with some domains can be achieved with manual Apache configuration as @joseph pointed out. Not many ask for this.

2 Likes

That’s amazing, @Sunil

Thank you so much.