- html - 出于某种原因,IE8 对我的 Sass 文件中继承的 html5 CSS 不友好?
- JMeter 在响应断言中使用 span 标签的问题
- html - 在 :hover and :active? 上具有不同效果的 CSS 动画
- html - 相对于居中的 html 内容固定的 CSS 重复背景?
当我运行 docker-compose 时,它只是挂起。我的代码的第一行是打印语句,我没有看到任何输出。docker-compose
version: "3"
services:
grip-sim-results-parser:
container_name: grip-sim-results-parser
build: .
ports:
- "5000:5000"
Dockerfile
FROM library/python:3.7-stretch
RUN apt-get update
RUN apt-get install -y vim
ADD . /code
WORKDIR /code
COPY requirements.txt /
RUN pip3 install --trusted-host pypi.org -r /requirements.txt
CMD ["python3", "app.py"]
docker-compose版本
user@ubuntu:~/projects/grip/grip-sim-results-parser$ docker-compose --version
docker-compose version 1.22.0, build f46880fe
Docker 版本
user@ubuntu:~/projects/grip/grip-sim-results-parser$ docker --version
Docker version 18.06.1-ce, build e68fc7a
Linux版本
user@ubuntu:~/projects/grip/grip-sim-results-parser$ uname -a
Linux ubuntu 4.13.0-46-generic #51-Ubuntu SMP Tue Jun 12 12:36:29 UTC 2018 x86_64 x86_64 x86_64 GNU/Linux
应用程序.py
....
def main():
print('main')
docker-compose 输出
user@ubuntu:~/projects/grip/grip-sim-results-parser$ docker-compose --verbose up --build
compose.config.config.find: Using configuration files: ./docker-compose.yml
docker.utils.config.find_config_file: Trying paths: ['/home/user/.docker/config.json', '/home/user/.dockercfg']
docker.utils.config.find_config_file: Found file at path: /home/user/.docker/config.json
docker.auth.load_config: Found 'auths' section
docker.auth.parse_auth: Found entry (registry='https://index.docker.io/v1/', username='jcald1')
urllib3.connectionpool._make_request: http://localhost:None "GET /v1.25/version HTTP/1.1" 200 543
compose.cli.command.get_client: docker-compose version 1.22.0, build f46880fe
docker-py version: 3.4.1
CPython version: 3.6.6
OpenSSL version: OpenSSL 1.1.0f 25 May 2017
compose.cli.command.get_client: Docker base_url: http+docker://localhost
compose.cli.command.get_client: Docker version: Platform={'Name': ''}, Components=[{'Name': 'Engine', 'Version': '18.06.1-ce', 'Details': {'ApiVersion': '1.38', 'Arch': 'amd64', 'BuildTime': '2018-08-21T17:23:27.000000000+00:00', 'Experimental': 'false', 'GitCommit': 'e68fc7a', 'GoVersion': 'go1.10.3', 'KernelVersion': '4.13.0-46-generic', 'MinAPIVersion': '1.12', 'Os': 'linux'}}], Version=18.06.1-ce, ApiVersion=1.38, MinAPIVersion=1.12, GitCommit=e68fc7a, GoVersion=go1.10.3, Os=linux, Arch=amd64, KernelVersion=4.13.0-46-generic, BuildTime=2018-08-21T17:23:27.000000000+00:00
compose.cli.verbose_proxy.proxy_callable: docker inspect_network <- ('gripsimresultsparser_default')
urllib3.connectionpool._make_request: http://localhost:None "GET /v1.25/networks/gripsimresultsparser_default HTTP/1.1" 404 61
compose.cli.verbose_proxy.proxy_callable: docker info <- ()
urllib3.connectionpool._make_request: http://localhost:None "GET /v1.25/info HTTP/1.1" 200 None
compose.cli.verbose_proxy.proxy_callable: docker info -> {'Architecture': 'x86_64',
'BridgeNfIp6tables': True,
'BridgeNfIptables': True,
'CPUSet': True,
'CPUShares': True,
'CgroupDriver': 'cgroupfs',
'ClusterAdvertise': '',
'ClusterStore': '',
'ContainerdCommit': {'Expected': '468a545b9edcd5932818eb9de8e72413e616e86e',
'ID': '468a545b9edcd5932818eb9de8e72413e616e86e'},
...
compose.cli.verbose_proxy.proxy_callable: docker inspect_network <- ('grip-sim-results-parser_default')
urllib3.connectionpool._make_request: http://localhost:None "GET /v1.25/networks/grip-sim-results-parser_default HTTP/1.1" 200 590
compose.cli.verbose_proxy.proxy_callable: docker inspect_network -> {'Attachable': True,
'ConfigFrom': {'Network': ''},
'ConfigOnly': False,
'Containers': {},
'Created': '2018-10-02T22:17:49.401421224-04:00',
'Driver': 'bridge',
'EnableIPv6': False,
'IPAM': {'Config': [{'Gateway': '172.27.0.1', 'Subnet': '172.27.0.0/16'}],
'Driver': 'default',
'Options': None},
...
compose.cli.verbose_proxy.proxy_callable: docker containers <- (all=False, filters={'label': ['com.docker.compose.project=grip-sim-results-parser', 'com.docker.compose.oneoff=False']})
urllib3.connectionpool._make_request: http://localhost:None "GET /v1.25/containers/json?limit=-1&all=0&size=0&trunc_cmd=0&filters=%7B%22label%22%3A+%5B%22com.docker.compose.project%3Dgrip-sim-results-parser%22%2C+%22com.docker.compose.oneoff%3DFalse%22%5D%7D HTTP/1.1" 200 3
compose.cli.verbose_proxy.proxy_callable: docker containers -> (list with 0 items)
compose.cli.verbose_proxy.proxy_callable: docker containers <- (all=False, filters={'label': ['com.docker.compose.project=gripsimresultsparser', 'com.docker.compose.oneoff=False']})
urllib3.connectionpool._make_request: http://localhost:None "GET /v1.25/containers/json?limit=-1&all=0&size=0&trunc_cmd=0&filters=%7B%22label%22%3A+%5B%22com.docker.compose.project%3Dgripsimresultsparser%22%2C+%22com.docker.compose.oneoff%3DFalse%22%5D%7D HTTP/1.1" 200 3
compose.cli.verbose_proxy.proxy_callable: docker containers -> (list with 0 items)
compose.cli.verbose_proxy.proxy_callable: docker containers <- (all=True, filters={'label': ['com.docker.compose.project=grip-sim-results-parser', 'com.docker.compose.service=grip-sim-results-parser', 'com.docker.compose.oneoff=False']})
urllib3.connectionpool._make_request: http://localhost:None "GET /v1.25/containers/json?limit=-1&all=1&size=0&trunc_cmd=0&filters=%7B%22label%22%3A+%5B%22com.docker.compose.project%3Dgrip-sim-results-parser%22%2C+%22com.docker.compose.service%3Dgrip-sim-results-parser%22%2C+%22com.docker.compose.oneoff%3DFalse%22%5D%7D HTTP/1.1" 200 1133
compose.cli.verbose_proxy.proxy_callable: docker containers -> (list with 1 items)
compose.cli.verbose_proxy.proxy_callable: docker inspect_container <- ('1f8f0b4c36a90c4771e7a2373986dcaed61dbfd140c66b5840bf310edd0c0e68')
urllib3.connectionpool._make_request: http://localhost:None "GET /v1.25/containers/1f8f0b4c36a90c4771e7a2373986dcaed61dbfd140c66b5840bf310edd0c0e68/json HTTP/1.1" 200 None
compose.cli.verbose_proxy.proxy_callable: docker inspect_container -> {'AppArmorProfile': 'docker-default',
'Args': ['app.py'],
'Config': {'ArgsEscaped': True,
'AttachStderr': False,
'AttachStdin': False,
'AttachStdout': False,
'Cmd': ['python3', 'app.py'],
'Domainname': '',
'Entrypoint': None,
'Env': ['PATH=/usr/local/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin',
...
compose.service.build: Building grip-sim-results-parser
compose.cli.verbose_proxy.proxy_callable: docker build <- (path='/home/user/grip-sim-results-parser', tag='grip-sim-results-parser_grip-sim-results-parser', rm=True, forcerm=False, pull=False, nocache=False, dockerfile=None, cache_from=None, labels=None, buildargs={}, network_mode=None, target=None, shmsize=None, extra_hosts=None, container_limits={'memory': None}, gzip=False, isolation=None, platform=None)
docker.api.build._set_auth_headers: Looking for auth config
docker.api.build._set_auth_headers: Sending auth config ('https://index.docker.io/v1/')
urllib3.connectionpool._make_request: http://localhost:None "POST /v1.25/build?t=grip-sim-results-parser_grip-sim-results-parser&q=False&nocache=False&rm=True&forcerm=False&pull=False HTTP/1.1" 200 None
compose.cli.verbose_proxy.proxy_callable: docker build -> <generator object APIClient._stream_helper at 0x7f5717d10a98>
Step 1/8 : FROM library/python:3.7-stretch
---> a9d071760c82
Step 2/8 : RUN apt-get update
---> Using cache
---> 75cc76eecf8a
Step 3/8 : RUN apt-get install -y vim
---> Using cache
---> af651ad63dda
Step 4/8 : ADD . /code
---> Using cache
---> 5ae41ae91671
Step 5/8 : WORKDIR /code
---> Using cache
---> a709b10facf8
Step 6/8 : COPY requirements.txt /
---> Using cache
---> 3d1a13239b96
Step 7/8 : RUN pip3 install --trusted-host pypi.org -r /requirements.txt
---> Using cache
---> 7e6d00d828ae
Step 8/8 : CMD ["python3", "app.py"]
---> Using cache
---> 1a2bdd386cd1
Successfully built 1a2bdd386cd1
Successfully tagged grip-sim-results-parser_grip-sim-results-parser:latest
compose.cli.verbose_proxy.proxy_callable: docker close <- ()
compose.cli.verbose_proxy.proxy_callable: docker close -> None
compose.cli.verbose_proxy.proxy_callable: docker containers <- (all=True, filters={'label': ['com.docker.compose.project=grip-sim-results-parser', 'com.docker.compose.service=grip-sim-results-parser', 'com.docker.compose.oneoff=False']})
urllib3.connectionpool._make_request: http://localhost:None "GET /v1.25/containers/json?limit=-1&all=1&size=0&trunc_cmd=0&filters=%7B%22label%22%3A+%5B%22com.docker.compose.project%3Dgrip-sim-results-parser%22%2C+%22com.docker.compose.service%3Dgrip-sim-results-parser%22%2C+%22com.docker.compose.oneoff%3DFalse%22%5D%7D HTTP/1.1" 200 1133
compose.cli.verbose_proxy.proxy_callable: docker containers -> (list with 1 items)
compose.cli.verbose_proxy.proxy_callable: docker inspect_image <- ('grip-sim-results-parser_grip-sim-results-parser')
urllib3.connectionpool._make_request: http://localhost:None "GET /v1.25/images/grip-sim-results-parser_grip-sim-results-parser/json HTTP/1.1" 200 None
compose.cli.verbose_proxy.proxy_callable: docker inspect_image -> {'Architecture': 'amd64',
'Author': '',
'Comment': '',
'Config': {'ArgsEscaped': True,
'AttachStderr': False,
'AttachStdin': False,
'AttachStdout': False,
'Cmd': ['python3', 'app.py'],
'Domainname': '',
'Entrypoint': None,
...
compose.cli.verbose_proxy.proxy_callable: docker inspect_container <- ('1f8f0b4c36a90c4771e7a2373986dcaed61dbfd140c66b5840bf310edd0c0e68')
urllib3.connectionpool._make_request: http://localhost:None "GET /v1.25/containers/1f8f0b4c36a90c4771e7a2373986dcaed61dbfd140c66b5840bf310edd0c0e68/json HTTP/1.1" 200 None
compose.cli.verbose_proxy.proxy_callable: docker inspect_container -> {'AppArmorProfile': 'docker-default',
'Args': ['app.py'],
'Config': {'ArgsEscaped': True,
'AttachStderr': False,
'AttachStdin': False,
'AttachStdout': False,
'Cmd': ['python3', 'app.py'],
'Domainname': '',
'Entrypoint': None,
'Env': ['PATH=/usr/local/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin',
...
compose.parallel.feed_queue: Pending: {<Service: grip-sim-results-parser>}
compose.parallel.feed_queue: Starting producer thread for <Service: grip-sim-results-parser>
Starting grip-sim-results-parser ...
compose.parallel.feed_queue: Pending: {<Container: grip-sim-results-parser (1f8f0b)>}
compose.parallel.feed_queue: Starting producer thread for <Container: grip-sim-results-parser (1f8f0b)>
compose.cli.verbose_proxy.proxy_callable: docker attach <- ('1f8f0b4c36a90c4771e7a2373986dcaed61dbfd140c66b5840bf310edd0c0e68', stdout=True, stderr=True, stream=True)
urllib3.connectionpool._make_request: http://localhost:None "POST /v1.25/containers/1f8f0b4c36a90c4771e7a2373986dcaed61dbfd140c66b5840bf310edd0c0e68/attach?logs=0&stdout=1&stderr=1&stream=1 HTTP/1.1" 101 0
urllib3.connectionpool._make_request: http://localhost:None "GET /v1.25/containers/1f8f0b4c36a90c4771e7a2373986dcaed61dbfd140c66b5840bf310edd0c0e68/json HTTP/1.1" 200 None
compose.cli.verbose_proxy.proxy_callable: docker attach -> <docker.types.daemon.CancellableStream object at 0x7f5717d32908>
compose.cli.verbose_proxy.proxy_callable: docker start <- ('1f8f0b4c36a90c4771e7a2373986dcaed61dbfd140c66b5840bf310edd0c0e68')
compose.parallel.feed_queue: Pending: set()
compose.parallel.feed_queue: Pending: set()
compose.parallel.feed_queue: Pending: set()
compose.parallel.feed_queue: Pending: set()
compose.parallel.feed_queue: Pending: set()
compose.parallel.feed_queue: Pending: set()
compose.parallel.feed_queue: Pending: set()
compose.parallel.feed_queue: Pending: set()
compose.parallel.feed_queue: Pending: set()
compose.parallel.feed_queue: Pending: set()
compose.parallel.feed_queue: Pending: set()
compose.parallel.feed_queue: Pending: set()
compose.parallel.feed_queue: Pending: set()
compose.parallel.feed_queue: Pending: set()
compose.parallel.feed_queue: Pending: set()
compose.parallel.feed_queue: Pending: set()
urllib3.connectionpool._make_request: http://localhost:None "POST /v1.25/containers/1f8f0b4c36a90c4771e7a2373986dcaed61dbfd140c66b5840bf310edd0c0e68/start HTTP/1.1" 204 0
compose.cli.verbose_proxy.proxy_callable: docker start -> None
Starting grip-sim-results-parser ... done
compose.parallel.feed_queue: Pending: set()
compose.parallel.parallel_execute_iter: Finished processing: <Service: grip-sim-results-parser>
compose.parallel.feed_queue: Pending: set()
Attaching to grip-sim-results-parser
compose.cli.verbose_proxy.proxy_callable: docker events <- (filters={'label': ['com.docker.compose.project=grip-sim-results-parser', 'com.docker.compose.oneoff=False']}, decode=True)
urllib3.connectionpool._make_request: http://localhost:None "GET /v1.25/events?filters=%7B%22label%22%3A+%5B%22com.docker.compose.project%3Dgrip-sim-results-parser%22%2C+%22com.docker.compose.oneoff%3DFalse%22%5D%7D HTTP/1.1" 200 None
compose.cli.verbose_proxy.proxy_callable: docker events -> <docker.types.daemon.CancellableStream object at 0x7f5717ce9cc0>
最佳答案
要查看 python 的输出,请尝试将以下行添加到 docker-compose.yml
:
grip-sim-results-parser:
environment:
- PYTHONUNBUFFERED=1
关于python - docker-compose 附加后挂起,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/52619154/
我有一个应用程序,当通过 eclipse 运行时,它会导致 eclipse 本身挂起。如果我将此应用程序导出为 jar 并运行它,它工作正常。但是,如果我运行(或调试)它,应用程序将显示为启动(根据
我正在将项目从 Rails2 切换到 Rails3。我跑: rails server 服务器启动没有错误: => Booting WEBrick => Rails 3.0.7 application
当我尝试使用 XCode 打开特定项目时,它挂起。当它挂起时,它显示以下屏幕: 其他项目可以正常打开,虽然挂起的项目也打开了,意味着我什么也做不了。我的 CPU 全速运行(风扇开始运转),我必须退出多
我正在使用 BNHtmlPdfKit 将 Html 呈现为 PDF。它工作得很好,但在 iOS8 中它只是挂起 [renderer drawPageAtIndex:i inRect:renderer.
我一直在尝试在 eclipse 中创建一个项目,并且有一个名为 InitRemoteEditJob 的工作正在阻止一切。它甚至没有被取消。 请建议怎么办? 最佳答案 这个错误有很多原因。 你可以试试这
我使用这个函数来发出 cURL 请求: function curl_request($options) //single custom cURL request. { $ch = curl_i
当我尝试归档某个项目时,Xcode 无法响应。如果让他一个人呆着,他会在很长一段时间后设法打开管理器。文件在那里。如果从 library/developer/xcode/archives 中手动删除,
有时我的 Eclipse 挂起,我需要猛烈地杀死它。但是,我一直无法正确地做到这一点。似乎 kill -9 实际上并没有以正确的方式关闭它,因为我仍然可以看到挂起的窗口。什么命令序列会正确杀死我的 E
我有一个JavaFX 8应用,它有时会挂起/冻结。我觉得我已经排除了造成此问题的许多原因,但它仍在发生。 不幸的是,我无法按需复制冻结/挂起。实际上,这仅发生在(到目前为止)我同事的计算机上。它可能在
我正在尝试学习网络基础知识,并且已经从this教程构建了回显服务器。我用telnet检查了服务器,它工作正常。 现在,当我使用Internet上的许多客户端示例中的一些示例时: // Create a
我正在尝试使用 SwiftUI 实现使用 Apple 登录,但在我输入正确的密码后它挂起。 我正在使用真实用户和模拟器以及 XCode 12.0 Beta。不幸的是,我现在没有可供测试的设备。我也尝试
我包括此简单的错误处理功能来格式化错误: date_default_timezone_set('America/New_York'); // Create the error handler. fun
我正在尝试为 VisualVM 安装一些插件,但它一直卡在下面的屏幕上 - 告诉我“请等待安装程序发现插件依赖项”。我运行的是 Ubuntu 12.04。当我尝试从“可用插件”列表中安装它们时,以及当
如果堆分配/取消分配/重新分配在另一个线程中进行,DbgHelp 库的 MiniDumpWriteDump() 将挂起。这是调用堆栈:DbgHelp 暂停其他线程,然后无限期地等待这些线程获得的互斥量
我正在尝试在 Eclipse C++ 版本中安装新软件。 帮助 -> 安装新软件。当我去安装新软件时,它会挂起或需要几个小时才能移动百分比。 我读到这是 JRE7 中的一个已知错误,我假设我在安装它后
这个问题已经有答案了: process.waitFor() never returns (12 个回答) 已关闭 3 年前。 我使用以下代码运行命令: open class AppRunner {
我正在尝试为 VisualVM 安装一些插件,但它一直卡在下面的屏幕上 - 告诉我“请等待安装程序发现插件依赖项”。我正在运行 Ubuntu 12.04。当我尝试从“可用插件”列表安装它们时,以及当我
如果堆分配/取消分配/重新分配在另一个线程中进行,DbgHelp 库的 MiniDumpWriteDump() 将挂起。这是调用堆栈:DbgHelp 暂停其他线程,然后无限期地等待这些线程获得的互斥量
尝试调试竞争条件,其中我们的应用程序的轮询器线程之一永远不会返回,导致 future 的轮询器永远不会被调度。用抽象术语来说,在捕获问题时隐藏我们的业务逻辑,这就是我们的代码路径。 我们必须更新远程服
我在程序完成时遇到 Java 的 ExecutorCompletionService 问题。 我需要使用 ExecutorCompletionService 而不是 ExecutorService 因
我是一名优秀的程序员,十分优秀!