Bug 2042710 - Custom imagepullsecret reference information not found when creating pod using console in openshift
Summary: Custom imagepullsecret reference information not found when creating pod usin...
Alias: None
Product: OpenShift Container Platform
Classification: Red Hat
Component: Dev Console
Version: 4.8
Hardware: Unspecified
OS: Unspecified
Target Milestone: ---
: 4.12.z
Assignee: Avik Kundu
QA Contact: spathak@redhat.com
Depends On:
TreeView+ depends on / blocked
Reported: 2022-01-20 01:37 UTC by congliang pan
Modified: 2023-03-09 01:31 UTC (History)
11 users (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Last Closed: 2023-03-09 01:31:14 UTC
Target Upstream Version:

Attachments (Terms of Use)

System ID Private Priority Status Summary Last Updated
Github openshift console pull 11058 0 None open Bug 2042710: Custom imagepullsecret reference information not found when creating pod using console in openshift 2022-02-15 15:09:06 UTC

Comment 4 Jakub Hadvig 2022-02-01 06:33:09 UTC
So this in not a bug really. Not sure why we are not showing the ImagePullSecret field on the Pod's page but will create an RFE for that.
Regarding "Image url shows the real external address." that works by design, since is an external image is referenced it will be pulled into the local registry, and thats the address you are seeing (the local one).

From this I think the only thing that we can do is to surface the ImagePullSecret field. Would that make sense?

Comment 6 Jakub Hadvig 2022-02-10 09:08:15 UTC
The issue is that the 'web console -> developer -> +add -> container image' flow that you are referring to, will pull the image from external registry into the internal registry and from it create a deployment (from the pulled image in the internal registry) thats not an issue, thats by design. Its due to the fact that you are creating a deployment, which needs to have images present on the cluster in case of scaling.
One way to fix this is to incorporate the application version into the image name. Then it will be visible in both images(internal and external).

Only thing that we can deliver is to show the imagePullSecret.

Comment 8 Jakub Hadvig 2022-02-11 08:42:40 UTC
Tested the flow on 4.7.0-0.nightly-2022-02-10-184638
Created the pod using the "web console -> developer -> +add -> container image" workflow, using the "quay.io/redhattraining/hello-world-nginx:v1.0" image.

$ oc get clusterversion
NAME      VERSION                             AVAILABLE   PROGRESSING   SINCE   STATUS
version   4.7.0-0.nightly-2022-02-10-184638   True        False         3m53s   Cluster version is 4.7.0-0.nightly-2022-02-10-184638

$ oc get pod hello-world-nginx-9785dbfcd-4tpm5 -n default -o yaml
  - image: image-registry.openshift-image-registry.svc:5000/default/hello-world-nginx@sha256:941928d702a2f08c986017b1eed3417d83952f05de55d657787512e82714dd89

Will check the specificversion tha you are using but even if that behaviour is different it will be due to the API changes.

Comment 12 Yanping Zhang 2022-03-01 07:50:15 UTC
Tested on ocp 4.11 cluster with payload 4.11.0-0.nightly-2022-02-27-122819.
Steps to check:
1. Created the pod using the "web console -> developer -> +add -> container image" workflow, input a private image in "Image name from external registry" field, create an image pull secret, after input all required fields, click "Create" button.
2. After deployment is created successfully, check on the created pod's detail page, there is a field "Image pull secret", it shows secret from pod yaml "spec"->"imagePullSecrets". But the secret is not the one created from step 1.
3. Check image url of pod, it keeps using internal address.

@Tim, from the fix pr, the fix will only containing "show image pull secret on pod's detail page", the customer's second requirement about showing the real external image url won't be addressed for this time, right? BTW, could you help to confirm if it's an issue that the image pull secret name in pod's yaml is not the one I created for image pull in my step 2?

Comment 13 Tim Grein 2022-03-01 12:47:54 UTC

I'll check if it's a requirement to show the real external image url

Comment 14 Yanping Zhang 2022-03-09 03:37:30 UTC
@Jakub, could you help to confirm the 2 questions mentioned in Comment12 ? And I want to know if pr11058 is the final solution for the bug.

Comment 15 Yanping Zhang 2022-03-17 02:00:35 UTC
Since the fix doesn't meet expected results in bug description fully, assign it back first. Pls feel free to change the bug status if there is new conclusion/update for the bug.

Comment 17 Jakub Hadvig 2022-04-07 21:03:55 UTC
So from looking at the code this looks like an issue in the dev-console, cause the created secret is not used as an imagePullSecret.
Our team delivered https://github.com/openshift/console/pull/11058 as I mentioned in https://bugzilla.redhat.com/show_bug.cgi?id=2042710#c6

Re-assigning to the Dev-Console team for any additional work.

Comment 19 Prashanth Sundararaman 2022-10-06 13:53:24 UTC
Has this been fixed in 4.12 as well? any more actions needed on this bug?

Comment 20 Shiftzilla 2023-03-09 01:31:14 UTC
OpenShift has moved to Jira for its defect tracking! This bug can now be found in the OCPBUGS project in Jira.


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