1 |
Anyone know if there's a way to get /etc/hosts to support the notion of |
2 |
an include file? I did my homework and found nothing, maybe someone else |
3 |
knows more. |
4 |
|
5 |
I really do need this, I have an app that discovers things on the |
6 |
network and knows their address. This makes it's automated way into DNS |
7 |
but takes a few days, and another app needs to use the fqdn right now. |
8 |
So /etc/hosts is the way to go for the interim three days. |
9 |
|
10 |
I've worked around it by creating /etc/hosts.d/ containing a header and |
11 |
a data file. cat the two and redirect to /etc/hosts.d/hosts and the real |
12 |
hosts file is a symlink to that. It's a sub-directory as none of these |
13 |
apps run as root and only root can modiy the real hosts file. |
14 |
|
15 |
This works well enough, but a supported include mechanism would make |
16 |
life so much simpler, not to mention easier for my colleagues to |
17 |
understand what the blazes I set up :-) |
18 |
|
19 |
|
20 |
|
21 |
-- |
22 |
Alan McKinnon |
23 |
alan.mckinnon@×××××.com |