Docker 无法从Google cloud build访问pip主机

Docker 无法从Google cloud build访问pip主机,docker,ip,vpc,google-cloud-build,Docker,Ip,Vpc,Google Cloud Build,我正在尝试使用google cloud build创建docker映像,但它无法访问pip主机 下面是我得到的错误行 RUN pip install -vvv --extra-index-url http://[pip host] --trusted-host [pip host] -r requirements.txt 步骤2:步骤7/10:运行pip安装--额外索引url http://[pip主机]--受信任主机[pip主机]-r requirements.txt 步骤2:-->在14

我正在尝试使用google cloud build创建docker映像,但它无法访问pip主机

下面是我得到的错误行

RUN pip install -vvv --extra-index-url http://[pip host] --trusted-host [pip host] -r requirements.txt

步骤2:步骤7/10:运行pip安装--额外索引url http://[pip主机]--受信任主机[pip主机]-r requirements.txt
步骤2:-->在1400ecddf71f2中运行
步骤2:查找索引:https://pypi.org/simple,http://[pip主机]/simple/
步骤2:收集[some package==version](来自-r requirements.txt(第1行))
步骤#2:警告:在连接被“ConnectTimeoutError(,“连接到[pip主机]超时。(连接超时=15)”:简单/[某个包]中断后重试(重试(总计=4,连接=None,读取=None,重定向=None,状态=None))/
步骤#2:警告:在连接被“ConnectTimeoutError(,“连接到[pip主机]超时。(连接超时=15)”:简单/[某个包]中断后重试(重试(总计=3,连接=None,读取=None,重定向=None,状态=None))/

提前感谢

pip主机是一个私有主机,您是否可以共享cloudbuild.yaml,显然可以编辑任何私有信息cloudbuild.yaml
步骤:-name:'gcr.io/cloud builders/docker'args:['build','--network=cloudbuild','-t',gcr.io/${PROJECT\u ID}/image\u name:$BRANCH\u name'、'-f'、'Dockerfile'、'..'.]
Dockerfile
运行pip安装--额外索引url http://[pip主机]--受信任主机[pip主机]-r requirements.txt
您能尝试ping[pip主机]吗?看看它是否回答了这个问题,并且在这一点上是可以访问的


Step #2: Step 7/10 : RUN pip install --extra-index-url http://[pip host] --trusted-host [pip host] -r requirements.txt
Step #2:  ---> Running in 1400ecddf71f2
Step #2: Looking in indexes: https://pypi.org/simple, http://[pip host]/simple/
Step #2: Collecting [some package == version](from -r requirements.txt (line 1))
Step #2:   WARNING: Retrying (Retry(total=4, connect=None, read=None, redirect=None, status=None)) after connection broken by 'ConnectTimeoutError(<pip._vendor.urllib3.connection.HTTPConnection object at 0x7f58e9d64b70>, 'Connection to [pip host] timed out. (connect timeout=15)')': /simple/[some package]/
Step #2:   WARNING: Retrying (Retry(total=3, connect=None, read=None, redirect=None, status=None)) after connection broken by 'ConnectTimeoutError(<pip._vendor.urllib3.connection.HTTPConnection object at 0x7f58e9d5a9e8>, 'Connection to [pip host] timed out. (connect timeout=15)')': /simple/[some package]/