Uploaded image for project: 'OpenShift Bugs'
  1. OpenShift Bugs
  2. OCPBUGS-55699

Empty proxy variables are causing issues during the build

XMLWordPrintable

    • None
    • False
    • Hide

      None

      Show
      None
    • None
    • Important
    • None
    • In Progress
    • Bug Fix
    • Hide
      Problem:
      Irrespective of default proxy settings these proxy variables are set on build containers.
      If any defaults are set they reflect those setting ,if not set they are set to null on the build container. Having these null variables are causing problems to some customers as its breaking some required apps on container
      HTTP_PROXY,http_proxy,HTTPS_PROXY,https_proxy,NO_PROXY,no_proxy
      Fix:
      Code changed only to add these proxy variables only if they are defined in defaults and if they are not null.
      Show
      Problem: Irrespective of default proxy settings these proxy variables are set on build containers. If any defaults are set they reflect those setting ,if not set they are set to null on the build container. Having these null variables are causing problems to some customers as its breaking some required apps on container HTTP_PROXY,http_proxy,HTTPS_PROXY,https_proxy,NO_PROXY,no_proxy Fix: Code changed only to add these proxy variables only if they are defined in defaults and if they are not null.
    • None
    • None
    • None
    • None

      This is a clone of issue OCPBUGS-55642. The following is the description of the original issue:

      Description of problem:

      IHAC where the injected Proxy Env Variables into the Build pod are causing the build to fail. Unfortunately, the build contains a build step by external binary which complains about the proxy not in the right format. (the assumption is that once env variable is configured, it expects some format like "http{s}" or domain, etc).
      
      Note that cluster runs without any configured Proxy, so builds should not use any proxy.
      
      We also see that the fix from the bug below introduced the issue as it was working in 4.15 and no longer works in 4.16 (seems like the external binary ignored the upper case variables)
      https://issues.redhat.com/browse/OCPBUGS-12699 
          

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

      OpenShift 4.16.37
          

      How reproducible:

      on currently failing environment
          

      Actual results:

      the build fails with external binary complaining about the format
          

      Expected results:

      proxy variables should be excluded
          

      Additional info:

      Additional question is why those variables are injected, if they are not used?
      
      The BuildConfig doesn't have any ENV configured about the Proxy.
      Even setting the env variables through the BuildConfig will result that the variable is added but no value is added.
      
      ////
          - name: HTTP_PROXY
          - name: http_proxy
          - name: HTTPS_PROXY
          - name: https_proxy
          - name: NO_PROXY
          - name: no_proxy
      ///
          

              rh-ee-kmemane Kunal Memane
              openshift-crt-jira-prow OpenShift Prow Bot
              None
              None
              Moe Basim Moe Basim (Inactive)
              None
              Votes:
              0 Vote for this issue
              Watchers:
              5 Start watching this issue

                Created:
                Updated:
                Resolved: