Hi Balena support team,
I’m trying to deactivate and delete the wifi network connections configured by balena wifi-connect in the docker container.
I installed and run wifi-connect in my django container. I didn’t installed Network-Manager in the container. But I was able to execute wifi-connect by adding some settings(dbus mount and network host setting) to django service in my docker-compose.yml file.
Also, I was able to deactivate and delete the wifi network connection by running the following commands on host OS.
sudo nmcli connection down id “TP-LINK-REAL3D” || true
sudo nmcli connection delete id “TP-LINK-REAL3D” || true
Now what I want to is to deactivate and delete the wifi network connection in the contanier, not in host OS. However, when I run the nmcli commands above, the container doesn’t recognize nmcli command because network-manager is not installed in the container.
So I installed network manager in the container by the following command.
apt-get update && apt-get install -y network-manager && systemctl mask NetworkManager.service
But I still can’t use nmcli commands in the container.
- Is there any way to run nmcli commands directly in the container without installing network-manger in the container?
- Even after network manager is installed on the container i still can’t run nmcli command. How can I fix it?
I’ll share my docker-compose.yml file as necessary.
Thanks in advance.