1 |
On 08/28/2016 11:15 AM, William Hubbs wrote: |
2 |
> Ok all, |
3 |
> |
4 |
> here is what openrc-0.22 is going to do in terms of setting the host |
5 |
> name. |
6 |
> |
7 |
> If /etc/hostname exists, the first word of that file will be used as the |
8 |
> host name. |
9 |
> Otherwise, if the value is set in /etc/conf.d/hostname it will be used. |
10 |
> Otherwise, OpenRC will not touch the hostname. |
11 |
> |
12 |
> One advantage of this, on Linux, is that you can set your host name in |
13 |
> the kernel and this setting will be respected. |
14 |
> |
15 |
> Also, this means the script by default can run in containers if they |
16 |
> allow overriding the hostname inside the container. |
17 |
> |
18 |
> William |
19 |
> |
20 |
I didn't see anyone else reply to this so I will. I think that's the |
21 |
best way of supporting both without requiring (much) putzing around. If |
22 |
a user changes /etc/conf.d/hostname and it doesn't change, the fix would |
23 |
be to delete (or update) /etc/hostname and all is good in the world again. |
24 |
|
25 |
Supporting kernel-level hostname as a side effect is even better. No |
26 |
complaints here! |
27 |
|
28 |
-- |
29 |
Daniel Campbell - Gentoo Developer |
30 |
OpenPGP Key: 0x1EA055D6 @ hkp://keys.gnupg.net |
31 |
fpr: AE03 9064 AE00 053C 270C 1DE4 6F7A 9091 1EA0 55D6 |