1 |
OK, it seems that hard lines in multipart configs seem to be an issue, so I'm |
2 |
doing this now. |
3 |
|
4 |
For a summary of why we're using hard lines you can read this thread |
5 |
http://thread.gmane.org/gmane.linux.gentoo.devel/45756/focus=45765 |
6 |
|
7 |
Basically, just using whitespace to seperate configs is nice and simple. |
8 |
What's more is everyone understands it. With CIDR notation, this is possible. |
9 |
For routes, it's a little more tricky as there are two values in use. |
10 |
|
11 |
config_eth0=("1.2.3.4 netmask 255.255.255.0" |
12 |
"5.6.7.8 netmask 255.255.0.0" ) |
13 |
routes_eth0=("1.2.4.0 netmask 255.255.255.0 gw 1.2.3.6" |
14 |
"5.6.7.9 gw 5.6.7.10" |
15 |
"default gw 1.2.3.1") |
16 |
|
17 |
becomes |
18 |
|
19 |
config_eth0="1.2.3.4 netmask 255.255.255.0 |
20 |
5.6.7.8 netmask 255.255.0.0" |
21 |
routes_eth0="1.2.4.0 netmask 255.255.255.0 gw 1.2.3.6 |
22 |
5.6.7.9 gw 5.6.7.10 |
23 |
default gw 1.2.3.1" |
24 |
|
25 |
becomes |
26 |
|
27 |
address_eth0="1.2.3.4/24 5.6.7.8/16" |
28 |
routes_eth0="1.2.4.0/24 1.2.3.6 5.6.7.8 5.6.7.10 default 1.2.3.1" |
29 |
|
30 |
Or we could adopt the BSD routing notation and do this |
31 |
routes_eth0="route_foo route_bar" |
32 |
route_foo="1.2.4.0/24 1.2.3.6 metric 5" |
33 |
route_bar="default 1.2.3.1" |
34 |
|
35 |
Yes, I've used the same "routes_eth0" variable, but we can change it's syntax |
36 |
based on the existance of address_eth0/config_eth0. |
37 |
|
38 |
So what are peoples feelings on this? Are you happy with the names? |
39 |
address_eth0? |
40 |
addr_eth0? |
41 |
addresses_eth0? |
42 |
ipaddress_eth0? |
43 |
ipaddr_eth0? |
44 |
ipaddresses_ath0? |
45 |
routes_eth0? |
46 |
static_routes_eth0? |
47 |
|
48 |
Speak up, or I'll make a decision by myself which will probably be done over |
49 |
the weekend. |
50 |
|
51 |
Thanks |
52 |
|
53 |
Roy |
54 |
-- |
55 |
gentoo-dev@l.g.o mailing list |