Bug 1827101 - oc adm release extract tries to pull image from quay.io even when local registry is specified
Summary: oc adm release extract tries to pull image from quay.io even when local regis...
Keywords:
Status: CLOSED DUPLICATE of bug 1823143
Alias: None
Product: OpenShift Container Platform
Classification: Red Hat
Component: oc
Version: 4.3.z
Hardware: Unspecified
OS: Linux
unspecified
unspecified
Target Milestone: ---
: ---
Assignee: Maciej Szulik
QA Contact: zhou ying
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2020-04-23 09:37 UTC by Leonid Titov
Modified: 2020-04-23 11:33 UTC (History)
3 users (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2020-04-23 11:33:53 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)

Description Leonid Titov 2020-04-23 09:37:18 UTC
Description of problem:

When try to do 'oc adm release extract' from local registry in disconnected environment, tool is trying to reach public 'quay.io' instead of local registry

Version-Release number of selected component (if applicable):

Detected on 4.3.8

How reproducible:

Always.

Steps to Reproduce:
1. Deploy local registry and mirror public content there according to the doc [1]
2. Issue a 'oc adm -a ${LOCAL_SECRET_JSON} release extract -v=7 --command=openshift-install "${LOCAL_REGISTRY}/${LOCAL_REPOSITORY}:${OCP_RELEASE}" 2>&1 | tee oc-release-extract.log' command 


Actual results:

it will eventually pull quay.io: 

I0423 10:02:58.869971    7170 extract_tools.go:315] Skipping openshift-install-mac-%s.tar.gz, does not match current OS darwin
I0423 10:02:58.870024    7170 extract_tools.go:323] Will extract usr/bin/openshift-install from quay.io/openshift-release-dev/ocp-v4.0-art-dev@sha256:958fb6dc2f5d44aaf34e073b0e69e38599df5fd4269c2bed96484aba8b388333
I0423 10:02:58.870205    7170 config.go:137] looking for config.json at /home/ltitov/.docker/config.json
I0423 10:02:58.870603    7170 config.go:145] found valid config.json at /home/ltitov/.docker/config.json
I0423 10:02:58.871040    7170 workqueue.go:54] worker 0 stopping
I0423 10:02:58.871073    7170 workqueue.go:60] work queue exiting
I0423 10:02:58.871237    7170 round_trippers.go:420] GET https://quay.io/v2/



Expected results:

All necessary things should be pulled from local registry.

Additional info:

Used environment vars and full log will be uploaded here shortly.
The 'oc adm release extract' will fail if the host machine can't access quay.io. This scenario is shown in full log.

1. https://docs.openshift.com/container-platform/4.3/installing/install_config/installing-restricted-networks-preparations.html#cli-installing-cli_installing-restricted-networks-preparations

Comment 3 Leonid Titov 2020-04-23 09:43:40 UTC
oc version --client=true
Client Version: 4.3.9

Comment 4 Maciej Szulik 2020-04-23 11:33:53 UTC

*** This bug has been marked as a duplicate of bug 1823143 ***


Note You need to log in before you can comment on or make changes to this bug.