Uploaded image for project: 'Project Quay'
  1. Project Quay
  2. PROJQUAY-3348

Config tool crashes on validation if Elasticsearch is set to point to http server instead of https

    XMLWordPrintable

Details

    • Bug
    • Status: Planning
    • Major
    • Resolution: Unresolved
    • quay-v3.6.4
    • None
    • config-tool
    • False
    • False
    • Quay Enterprise
    • 0

    Description

      The config tool expects Elasticsearch to be hooked via https exclusively:

      https://github.com/quay/config-tool/blob/72307569e76cf89bcef4d5d3b154e1311981754d/pkg/lib/fieldgroups/elasticsearch/elasticsearch_validator.go#L85

      This hinders deployments of Quay on platforms where Elasticsearch is not behind a TLS certificate, i.e. it's only available via plain http. If an http hostname is tried, the validation fails:

      config-editor stdout | time="2022-02-21T15:20:57Z" level=debug msg="Received config bundle. Decoding into C
      config-editor stdout | time="2022-02-21T15:20:57Z" level=debug msg="Validating BuildManager"
      config-editor stdout | time="2022-02-21T15:20:57Z" level=debug msg="Validating ElasticSearch"
      config-editor stdout | e Get "https://QUAY_HOSTNAME:80/ocp-quay-prueba*": net/http: T
      config-editor stdout | 2022/02/21 15:21:07 [openshift-quay-config-editor-5bd765f945-mmfvt/KQ7sxF78z7-000050ay-QUAY_CONFIG/api/v1/config/validate?mode=online HTTP/1.1" from 10.129.
      ...
      config-editor stderr |  panic: runtime error: invalid memory address or nil pointer dereference
      

      Please check. Thanks!

      Attachments

        Activity

          People

            Unassigned Unassigned
            rhn-support-ibazulic Ivan Bazulic
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

            Dates

              Created:
              Updated: