docker 容器pip、git安装异常;容器内web对外端口ping不通

1、docker 容器pip、git安装异常

错误信息:

git clone https://github.com/vllm-project/vllm.git

Cloning into 'vllm'...

fatal: unable to access 'https://github.com/vllm-project/vllm.git/': Failed to connect to

127.0.0.1 port 10808: Connection refused
pip install vllm Looking

in indexes: https://pypi.org/simple, https://pypi.ngc.nvidia.com

WARNING: Retrying (Retry(total=4, connect=None, read=None,

redirect=None, status=None)) af ter connection broken by

'ProxyError('Cannot connect to proxy.',

NewConnectionError('_vendor.urllib3.connection.HTTPSConnection object

at 0x7f26fe64fb50>: Failed to establish a new connection: Errno 111

Connection refused')

基本是代理问题:

解决方法(-env http_proxy= --env https_proxy= 设置docker容器运行代理为空):

复制代码
docker run --env http_proxy= --env https_proxy= --gpus all -it -v /mn**ng/:/work  容器image bash

2、容器内web对外端口ping不通

虽然docker -p 7860:7860 端口可以正常映射,但ip不是0.0.0.0也不行,必须设置0.0.0.0从外部才能正确访问容器内部启动的web

复制代码
 docker run --gpus all -it -v /m****/:/work -p 18600:18600 llm:v14 python /work/Qwen-7B-main/web_demo.py  -c /work/q***odel --server-port 18600  --server-name 0.0.0.0
相关推荐
Eloudy11 小时前
git format-patch 、git diff 与 git apply
git·构建
技术小结-李爽12 小时前
【工具】git安装及配置
git
营养充电站13 小时前
KMP全栈开发:从Android到AI Agent的技术演进与实践
人工智能·算法·docker·jupyter
小义_14 小时前
K8s 全网高频常用命令大全
docker·容器·kubernetes
技术小结-李爽18 小时前
【工具】git与gitee和gitlab和github等等有什么区别?
git·gitee·gitlab
Haku Coder19 小时前
0基础学习Git——基础篇
git·学习
兵bing21 小时前
Docker Compose 配置文件归纳总结-千问
运维·docker·容器
蓝田~1 天前
Java镜像1.2GB→200MB的瘦身之路:Docker多阶段构建+K8s Pod OOMKilled(137)排查,后端部署避坑指南
java·docker·kubernetes
TechWJ1 天前
Excel报表越做越乱?用Metabase搭建可更新的数据仪表盘
docker·数据分析·excel·metabase·报表工具
为伴只为你1 天前
将已有git工程转为使用LFS
git