Skip to content

Warehouse - Not picking up credentials for Harbor Helm charts from secret #4703

Description

@stephenpope

Checklist

  • I've searched the issue queue to verify this is not a duplicate bug report.
  • I've included steps to reproduce the bug.
  • I've pasted the output of kargo version.
  • I've pasted logs, if applicable.

Description

When adding a warehouse resource to a private Harbor OCI Helm chart. The credentials I have put in my secret do not seem to be picked up. The process is erroring saying it is unable to authenticate.

Steps to Reproduce

Note: name field left blank as per documentation when dealing with OCI charts.

Secret

apiVersion: v1
kind: Secret
metadata:
  name: helm-repo
  namespace: kargo-project
  labels:
    kargo.akuity.io/cred-type: helm
data:
  password: XXXX
  repoURL: oci://harbor.domain.io
  username: XXXX
type: Opaque

Warehouse

apiVersion: kargo.akuity.io/v1alpha1
kind: Warehouse
metadata:
  name: my-warehouse
  namespace: kargo-project
spec:
  freightCreationPolicy: Automatic
  interval: 5m0s
  subscriptions:
  - chart:
      discoveryLimit: 20
      repoURL: oci://harbor.domain.io/platform-charts/myapplication
      semverConstraint: ^0.2.0

Error

Unable to discover artifacts: error discovering charts: error discovering latest chart versions in repository "oci://harbor.domain.io/platform-charts/myapplication":

error retrieving versions of chart "" from repository "oci://harbor.domain.io/platform-charts/myapplication": 

error retrieving versions of chart from repository "oci://harbor.domain.io/platform-charts/myapplication":
 GET "https://harbor.domain.io/v2/platform-charts/myapplication/tags/list": unexpected status code 401: 

unauthorized: unauthorized to access repository: platform-charts/myapplication, action: pull: unauthorized to access repository: platform-charts/myapplication, action: pull

Other attempts

I have tried updating the secret to have different combinations of URL ...

.. all without any luck.

Credentials : When I try "https://harbor.domain.io/v2/platform-charts/myapplication/tags/list" with the correct credentials it returns so my conclusion is that it is not matching/picking up credentails.

Version

Client Version: 1.6.1
Server Version: v1.6.1

Metadata

Metadata

Assignees

No one assigned

    Labels

    kind/bugSomething isn't working as intended; If unsure that something IS a bug, start a discussion insteadneeds/areaIssue or PR needs to be labeled to indicate what parts of the code base are affectedneeds/priorityPriority has not yet been determined; a good signal that maintainers aren't fully committed

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions