Uploaded image for project: 'OpenShift Windows Containers'
  1. OpenShift Windows Containers
  2. WINC-1286

Allow use of OCP internal registry for Windows workloads

XMLWordPrintable

    • Icon: Story Story
    • Resolution: Unresolved
    • Icon: Normal Normal
    • None
    • WMCO 10.17.0
    • None
    • 5
    • False
    • None
    • False

      Description

      OpenShift clusters have an internal registry. This registry is available within the cluster hostnetwork at `image-registry.openshift-image-registry.svc`. On Linux nodes, the cluster-dns-operator adds a /etc/hosts file entry
      which allows the registry address to be resolved, and images to be pulled.

      127.0.0.1   localhost localhost.localdomain localhost4 localhost4.localdomain4
      ::1         localhost localhost.localdomain localhost6 localhost6.localdomain6
      172.30.154.17 image-registry.openshift-image-registry.svc image-registry.openshift-image-registry.svc.cluster.local # openshift-generated-node-resolver
      

      Without an equivalent mechanism for updating the hosts file for Windows nodes, the internal registry is unusable, without a user manually intervening and adding an entry to the hosts file.

      Engineering details

      To test this, a Windows image can be copied to the internal registry by following the instructions in the OCP docs. Podman pull/push is described in the doc, but it will not work if you are doing this from a debug pod on a Linux node. Instead the image can be copied with skopeo.

      skopeo copy docker://mcr.microsoft.com/powershell:lts-nanoserver-ltsc2022 docker://image-registry.openshift-image-registry.svc:5000/openshift/powershell:lts-nanoserver-ltsc2022 
      

      The image can then be referenced in the pod spec:

            containers: 
              - name: windowswebserver
                image: image-registry.openshift-image-registry.svc:5000/openshift/powershell:lts-nanoserver-ltsc2022
      
      

      Acceptance Criteria

      • Windows workloads can use images pushed to the internal registry

              Unassigned Unassigned
              rh-ee-ssoto Sebastian Soto
              Votes:
              0 Vote for this issue
              Watchers:
              5 Start watching this issue

                Created:
                Updated: