-
Notifications
You must be signed in to change notification settings - Fork 0
Open
Description
2019-12-16 08:13:35
desc
get err when run image in vm
expected
Starting xxx ... done
actual
ERROR: for nginx-1.17-alpine a bytes-like object is required, not 'str'
ERROR: for nginx a bytes-like object is required, not 'str'
Traceback (most recent call last):
File "site-packages/docker/api/client.py", line 261, in _raise_for_status
File "site-packages/requests/models.py", line 940, in raise_for_status
requests.exceptions.HTTPError: 500 Server Error: Internal Server Error for url: http+docker://localhost/v1.22/containers/4e5bbce451720d688957fce5e67d30379648b7652ee261fb635bdaa3bf11be47/start
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "compose/service.py", line 625, in start_container
File "compose/container.py", line 241, in start
File "site-packages/docker/utils/decorators.py", line 19, in wrapped
File "site-packages/docker/api/container.py", line 1095, in start
File "site-packages/docker/api/client.py", line 263, in _raise_for_status
File "site-packages/docker/errors.py", line 31, in create_api_error_from_http_exception
docker.errors.APIError: 500 Server Error: Internal Server Error ("b'driver failed programming external connectivity on endpoint nginx-1.17-alpine (b5036045fcde103ededebe92e42cd080024d2981738925f0981656189a54b15c): Bind for 0.0.0.0:8080 failed: port is already allocated'")
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "bin/docker-compose", line 6, in <module>
File "compose/cli/main.py", line 72, in main
File "compose/cli/main.py", line 128, in perform_command
File "compose/cli/main.py", line 1107, in up
File "compose/cli/main.py", line 1103, in up
File "compose/project.py", line 570, in up
File "compose/parallel.py", line 112, in parallel_execute
File "compose/parallel.py", line 210, in producer
File "compose/project.py", line 556, in do
File "compose/service.py", line 568, in execute_convergence_plan
File "compose/service.py", line 510, in _execute_convergence_start
File "compose/parallel.py", line 112, in parallel_execute
File "compose/parallel.py", line 210, in producer
File "compose/service.py", line 508, in <lambda>
File "compose/service.py", line 620, in start_container_if_stopped
File "compose/service.py", line 627, in start_container
TypeError: a bytes-like object is required, not 'str'
[2136] Failed to execute script docker-compose
behavior
docker-compose up -d
my env
PM:WIN10
VM:CENTOS 7.7
CM:APLINE 3.xx
note:win+virtual+sharedir
find some thing:
#find factor for:Bind for 0.0.0.0:8080 failed: port is already allocated'
ps -aux | grep -v grep | grep docker-proxy
#> 172.20.1.2 -container-port 8080
#reason: nginx uses 8080:80 and tomcat uses 8080:8080
how to solve:
#update docker-compose.yml ports for nginx and tomcat serve
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels