[lxc-users] Dotted container names now invalid?

Mark Constable markc at renta.net
Wed Oct 7 00:28:02 UTC 2015

On 06/10/15 20:48, St├ęphane Graber wrote:
>>> Why are dotted domain-like container names now invalid?
> As the container name is set as the container hostname and may be
> included in DNS records through the use of DHCP, we needed it to comply
> to both hostname and DNS records specifications.

Right, so I was abusing the hostname part and using it as a full domainname
for the container, which was very convenient. It also allowed me to easily
see the full domainname of each container via lxc list.

However this change now introduces a problem I am not sure how to get
around in that if I want to set up various vhosts such as...




for typical hosting purposes then I cannot have multiple hostnames of
www, www and another www (times 1000+).

So now I have to come up with some otherwise useless scheme to provide
dummy hostnames where I have to use some persistent centralised database
to map and keep track of, ie;...

client1w -> www.example1.org
client2w -> www.example2.org
client3w -> www.example3.org

client1m -> mail.example1.org
client2m -> mail.example2.org
client3m -> mail.example3.org

Which is incredibly lame compared to how 0.18 worked.

> This results in the following rule:
>   - Hostname must be between 1 and 63 characters in length
>   - The character set is alpha numberical characters and hyphens
>   - Hostname may not started with a digit or an hyphen
>   - Hostname may not end with an hyphen

Surely DHCP can also work with full domainnames?

Is there any chance this restriction could be loosened slightly to include
a dot char to re-enable a FQDN for container names?

More information about the lxc-users mailing list