Hostname / Domain / TLD

What type of hardware are you using: Virtual machine
What YunoHost version are you running: yunohost 12 / yunohost 13
How are you able to access your server: The webadmin
SSH
Direct access via physical keyboard/screen
Are you in a special context or did you perform specific tweaking on your YunoHost instance ?: no

Describe your issue

Starting to install yunohost I would like to use hostname.domain.TLD
The tld is “local”, “yunohost” ist the hostname and I got a domain “Mydomain”. Getting asked what domain and tld I would like to use I put in “mydomain.local”. Afterwards the hostname of my system is “mydomain” and nothing works with that within my network.
putting it back on the former hostname and I can access the system but yunohost does not work fine installing software.
I need to keep “mydomain.local” for all the rest of my local net.

Share relevant logs or error messages

none at the moment

Hi @BlackWolf,

I think there may be a confusion between hostname and domain in the YunoHost context. Let me try to clarify.

How YunoHost handles domains and hostnames

When YunoHost asks you for a domain during postinstall, it expects a domain name like mydomain.local → not a full hostname.domain.tld structure. It’s also known that YunoHost modifies the system’s hostname based on the main domain you choose during postinstall (ref: GitHub issue #2065). This is why your hostname changed after setting up mydomain.local.

The .local TLD and mDNS

Domains ending in .local are fully supported since YunoHost v4.3. They use the mDNS protocol instead of standard DNS, meaning they are published automatically but only on your local network.

An important limitation: mDNS does not support subdomains :

So mydomain.local works, but yunohost.mydomain.local is not possible.

Also, if your existing network already relies on mydomain.local being resolved through standard DNS (e.g. by your router or a local DNS server), having YunoHost also publish mydomain.local via mDNS could create a naming conflict → which may explain why things break on your network. (Note: this is my hypothesis based on how mDNS works, not something explicitly documented by YunoHost.)

How to solve this

Option A – Use a fake TLD like .test

The official YunoHost documentation for VMs suggests using a dummy domain like yolo.test when you don’t have a real domain:

you can set up a dummy domain such as yolo.test and tweak your local /etc/hosts file such that this dummy domain points to the appropriate IP

So you could reinstall with mydomain.test (or any name you like), then add a line in the /etc/hosts file of each client machine:

192.168.x.x   mydomain.test

Or, if your router supports custom DNS entries, configure it there so all devices resolve it automatically.

This way, your existing mydomain.local network stays untouched.

Option B – Keep .local but with a unique name

If you prefer the mDNS auto-discovery convenience, just pick a .local name that doesn’t conflict with anything on your network → for example myserver.local. YunoHost will also always publish yunohost.local by default.

Option C – Use a free YunoHost subdomain

YunoHost offers free domains under .nohost.me, .noho.st, or .ynh.fr with automatic DNS configuration. This avoids any local conflict entirely.

In short

The key takeaway: use a different domain name for YunoHost than the one your local network already uses. Option A (.test TLD + /etc/hosts) is probably the cleanest for a local VM setup.

Hope this helps! :wink:

1 Like

Ok
So I undertand that the essense of your answer is:
use a different

  • domain name

because that is set as

  • hostname in
    • /etc/hostname.

Interesting

Thanks, I will think about it.

Even if I am using my on local domain with the tld “local” I need to

choose the first option of the three options regarding the domain as I have a domain and I want to to use it.

Thanks