I have a directory apkmirror-scraper-compose
with the following structure:
.
├── docker-compose.yml
├── privoxy
│ ├── config
│ └── Dockerfil
I had the same error, but in my case, it was because I had too many containers running (about 220).
Following Peter Hauge's comment, upon running docker network ls
I saw (among other lines) the following:
NETWORK ID NAME DRIVER SCOPE
dc6a83d13f44 bridge bridge local
ea98225c7754 docker_gwbridge bridge local
107dcd8aa889 host host local
The line with NAME
and DRIVER
as both host
seems to be what he is referring to with "networks already created on your host". So, following https://gist.github.com/bastman/5b57ddb3c11942094f8d0a97d461b430, I ran the command
docker network rm $(docker network ls | grep "bridge" | awk '/ / { print $1 }')
Now docker-compose up
works (although newnym.py
produces an error).
I fixed this issue by steps :
turn off your network (wireless or wired...).
reboot your system.
before turning on your network on PC, execute command docker-compose up, it's going to create new network.
then you can turn network on and go on ...
You can try
$sudo service network-manager restart
Worked for me.
I ran in this problem with OpenVPN working as well and I've found a solution where you should NOT stop/start OpenVPN server.
Idea that You should specify what exactly subnet you want to use. In docker-compose.yml
write:
networks:
default:
driver: bridge
ipam:
config:
- subnet: 172.16.57.0/24
That's it. Now, default
network will be used and if your VPN did not assign you something from 172.16.57.*
subnet, you're fine.
This happened to me because I was using OpenVPN
. I found a way that I don't need to stop using the VPN or manually add a network to the docker-compose file nor run any crazy script.
I switched to WireGuard
instead of OpenVPN
. More specifically, as I am running the nordvpn solution, I installed WireGuard and used their version of it, NordLynx.