Not able to access pip host from Google cloud build

I’m trying to create a docker image using google cloud build but it is failing to access the pip host.

below is the line I’m getting error

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


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]/

Thanks in advance

Source: StackOverflow