You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on Jun 16, 2021. It is now read-only.
When fed to libcompose, while libcompose is trying to merge the info, it should detect the repetition of ports and error out, but it goes forward and merges it:
$ libcompose -f docker-compose1.yml -f docker-compose2.yml up
WARN[0000] Note: This is an experimental alternate implementation of the Compose CLI (https://github.com/docker/compose)
INFO[0000] [0/1] [web]: Starting
INFO[0000] Recreating web
ERRO[0001] Failed Starting web : Error response from daemon: driver failed programming external connectivity on endpoint multiple_web_1 (747ef1b25524286894a48c8946e1a77dba778fd6dd0245163c8f40e7acaba5b2): Bind for 0.0.0.0:80 failed: port is already allocated
ERRO[0001] Failed to start: web : Error response from daemon: driver failed programming external connectivity on endpoint multiple_web_1 (747ef1b25524286894a48c8946e1a77dba778fd6dd0245163c8f40e7acaba5b2): Bind for 0.0.0.0:80 failed: port is already allocated
Error response from daemon: driver failed programming external connectivity on endpoint multiple_web_1 (747ef1b25524286894a48c8946e1a77dba778fd6dd0245163c8f40e7acaba5b2): Bind for 0.0.0.0:80 failed: port is already allocated
This works fine on docker-compose:
$ docker-compose -f docker-compose1.yml -f docker-compose2.yml up
Recreating multiple_web_1
Attaching to multiple_web_1
web_1 | AH00558: httpd: Could not reliably determine the server's fully qualified domain name, using 172.21.0.2. Set the 'ServerName' directive globally to suppress this message...
containers
$ docker ps
CONTAINER ID IMAGE COMMAND CREATED STATUS PORTS NAMES
b98955e1a601 centos/httpd "/run-httpd.sh" 7 seconds ago Up 5 seconds 0.0.0.0:80->80/tcp multiple_web_1
$ libcompose -f docker-compose1.yml -f docker-compose2.yml up
WARN[0000] Note: This is an experimental alternate implementation of the Compose CLI (https://github.com/docker/compose)
INFO[0000] [0/1] [web]: Starting
INFO[0000] Recreating web
INFO[0001] [1/1] [web]: Started
web_1 | AH00558: httpd: Could not reliably determine the server's fully qualified domain name, using 172.21.0.2. Set the 'ServerName' directive globally to suppress this message...
containers:
$ docker ps
CONTAINER ID IMAGE COMMAND CREATED STATUS PORTS NAMES
8ec86cfdd3c7 centos/httpd "/run-httpd.sh" 8 seconds ago Up 6 seconds 0.0.0.0:32776->80/tcp, 0.0.0.0:32777->80/tcp multiple_web_1
The thing to note here is that it worked here because the same container port was exposed on two different ports on the host machine. Before it failed because it tried to map on the same port which was 80.
So the issue is solved by finding the repetition of ports in code before doing the deployment.
The text was updated successfully, but these errors were encountered:
With respect to port it is not giving any errors but the data is repeated as well when using list form of specifying ports! See kubernetes/kompose#596 (comment) for more details!
Sign up for freeto subscribe to this conversation on GitHub.
Already have an account?
Sign in.
I have two docker-compose files which are similar:
which looks like this:
When fed to libcompose, while libcompose is trying to merge the info, it should detect the repetition of ports and error out, but it goes forward and merges it:
This works fine on docker-compose:
containers
When the docker-compose files are like this:
Just changed the port from
"80:80"
to"80"
.Now starting this:
containers:
The thing to note here is that it worked here because the same container port was exposed on two different ports on the host machine. Before it failed because it tried to map on the same port which was
80
.So the issue is solved by finding the repetition of ports in code before doing the deployment.
The text was updated successfully, but these errors were encountered: