Cannot save connected WIFI information into wpa_supplicant.conf
DJNoblesse opened this issue · 1 comments
-
I'm submitting a ...
- bug report
- feature request
- support request
-
Do you want to request a feature or report a bug?
Report a Bug -
What is the current behavior?
Cannot save connected WIFI information into wpa_supplicant.conf -
If the current behavior is a bug, please provide the steps to reproduce and if possible a minimal demo of the problem
- run docker container on boot
# Add below command to ~/.config/lxsession/LXDE-pi/autostart
docker run --rm --privileged --net host \
-v /path/to/wificfg.json:/cfg/wificfg.json \
-v /path/to/wpa_supplicant.conf:/etc/wpa_supplicant/wpa_supplicant.conf \
cjimti/iotwifi
- Try to connect WIFI network
$ curl -w "\n" -d '{"ssid":"MYSSID","psk":"mypassword"}' \
-H "Content-Type: application/json" \
-X POST localhost:8080/connect
- check wpa_supplicant.conf (or just reboot and check network status)
$ sudo docker exec CONTAINER_ID ls -al /etc/wpa_supplicant/
-
What is the expected behavior?
Save WIFI information into wpa_supplicant.conf and can reconnect to the network after reboot. -
What is the motivation / use case for changing the behavior?
N/A -
Please tell us about your environment:
- Device: Raspberry Pi 3 Model B+
- OS: Raspbian Stretch 9.4 (NO NOOBS)
-
Other information (e.g. detailed explanation, stacktraces, related issues, suggestions how to fix, links for us to have context, eg. stackoverflow, gitter, etc)
It does not write the wpa_supplicant.conf, it stores the network in the wpa_supplicant network interface. Network configurations should survive a reboot. This is technically not a bug and the intended design.