# /etc/conf.d/net per ESSID configuration

## ddriver

I think I've found a flaw in the design of /etc/conf.d/net variables. I wondered if anyone had any ideas of how to fix this.

What I want is to configure it so that one wireless interface (the internal one) will connect with a certain config when on my home network, but use DHCP elsewhere. My problem is that my machines will sometimes have two or more wireless interfaces connected and I don't want them to pick up the same IP address as my main wireless interface, as that would result in duplicated IP addresses.

From the documentation:

 *Quote:*   

> 2.c. Variable names and values
> 
> Variable names are dynamic. They normally follow the structure of variable_${interface|mac|essid|apmac}. For example, the variable dhcpcd_eth0 holds the value for dhcpcd options for eth0 and dhcpcd_essid holds the value for dhcpcd options when any interface connects to the ESSID "essid".

 

This notation is ambiguous, because it cannot cope with the unlikely but possible case where you have an interface with the same name as an ESSID. Worse though, I can only specify an interface OR an ESSID, there is no provision for specifying a combination, which is what I need to do in this case. I have tried it using the following combinations:

```
config_intwlan_MyESSID=192.168.0.152

config_MyESSID_intwlan=192.168.0.152
```

and neither of them work.

Any ideas?

----------

## NeddySeagoon

ddriver

Its not clear if you have followed the examples is /usr/share/doc/openrc-0.8.3-r1/net.example.bz2 or not

----------

