However, when I try to run this with docker-compose up I get this error:
Creating network “0_dev_default” with driver “host”
ERROR: only one instance of “host” network is allowed
There aren’t any other containers running when I do a docker ps or anything.
Can anyone advise me on what I’m getting wrong?
Thanks for any and all assistance,
Doug.
Had same issue, looks like that you can not have 2nd host driver network as Docker by default has one created already. Thus you would need just to use it instead of creating new network. Just add: network_mode: host under your container
Thanks maksimluzik,
Explaining why the issue .On network drivers you cannot create host and null network because these are replicating the default setting of the host network and the null network . you can just refer them
$ docker network create --driver null my-none
Error response from daemon: only one instance of "null" network is allowed $ docker network create --driver host my-host Error response from daemon: only one instance of "host" network is allowed