jlesage / docker-firefox

Docker container for Firefox
MIT License
1.42k stars 267 forks source link

WEB_LISTENING_PORT does not work with --network=container #158

Closed EvgeniyDoctor closed 1 year ago

EvgeniyDoctor commented 1 year ago

I'm trying to run a container that depends on another one:

docker run -d \
--name=browser \
-v /config:/config \
-e WEB_LISTENING_PORT=5801 \
--network=container:ovpn_client \
--shm-size 2g \
jlesage/firefox:v22.12.2

and i get this:

[xvnc        ] Fatal server error:
[xvnc        ] (EE) vncExtInit: failed to bind socket: Address in use (98)
[xvnc        ] (EE)
[supervisor  ] service 'xvnc' failed to be started: not ready after 5000 msec, giving up.
[supervisor  ] stopping service 'xvnc'...
[supervisor  ] service 'xvnc' exited (with status 1).
[finish      ] executing container finish scripts...
[finish      ] all container finish scripts executed.

I need run a few firefox instances with different port but with one dependency.

I tried:

jlesage commented 1 year ago

I think it's the VNC port that conflicts. Can you try to add -e VNC_LISTENING_PORT=-1 to your docker run command ?

EvgeniyDoctor commented 1 year ago

Yes, it helped.