I'd like to use a user-defined wpa_supplicant.conf file when using wifi in STA mode. I want to accomplish this by adding an 'option' field to the wireless config file that, when in STA mode, lets me point to a custom wpa_supplicant.conf file to use. I need some guidance on how to do this (perhaps through netifd)
I will be frequently moving my LEDE device and it will be connecting to multiple different wifi AP's depending on where I am with it. Right now, there appears to be no way to configure in /etc/config/wireless to connect to one of multiple different wifi AP's when they become available to the OS.
I can configure multiple wifi AP's in the wireless file for a single wlan device. However, LEDE creates an instance of wpa_Supplicant for every AP entry. This results in LEDE attempting to connect to every wifi ap simultaneously if they are available. I want it to connect to only one AP at a time (based on priority) not all of them.
You can configure wpa_supplicant to do exactly that with the "priority" field in the wpa_supplicant.conf file but it looks like there's no way to use my own conf file.
My attempts at getting control of wpa_supplicant are being negated by netifd. Anytime I want to make a change or restart wifi, netifd wipes out my wpa_supplicant.conf and generates its own. If i try to kill wpa_supplicant, netifd simply restarts it and regenerates its wpa_supplicant.conf. I suppose it is possible to accomplish this by not using /etc/config/wireless and managing the wifi device completely separately. But then it's being managed outside of the LEDE config system / uci and it'd be nice to keep it within that if possible.
It appears that netifd allows for "plugins" and extensions by reading in scripts located in the /lib/netifd directory, but I have no idea how these scripts work, how they are called by netifd and what their interdpendencies are. The best documentation I can find on it (LEDE wiki and git ) gives a general overview at best.
Again, I am looking for any guidance on how to accomplish this or to where i can find better details/documentation on netifd. Thank you for your time!