Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

bugfix: insecure flag not working for OCI registries with auth #89

Merged
merged 1 commit into from
Sep 12, 2024

Conversation

juan131
Copy link
Contributor

@juan131 juan131 commented Sep 12, 2024

Description

Dealing with OCI registries was failing when authentication was required if the registry used invalid certificates even if the insecure flag was provided. Check the error below:

    ⚠️  Failed syncing "aaa-x.y.z" chart: Failed to push Helm chart: failed to authorize: failed to fetch oauth token: Post "https://REGISTRY_HOST/service/token": tls: failed to verify certificate: x509: “REGISTRY_HOST” certificate is not trusted
    ✘  Error syncing charts: Failed to push Helm chart: failed to authorize: failed to fetch oauth token: Post "https://REGISTRY_HOST/service/token": tls: failed to verify certificate: x509: “REGISTRY_HOST” certificate is not trusted

Changes Made

This PR addresses this issue by ensuring we use an appropriate TLS client configuration when creating the docker authorizer

Signed-off-by: juan131 <jariza@vmware.com>
pkg/artifacts/helm.go Show resolved Hide resolved
pkg/artifacts/helm.go Show resolved Hide resolved
@juan131 juan131 requested a review from mpermar September 12, 2024 09:23
@juan131 juan131 merged commit e4b48c1 into vmware-labs:main Sep 12, 2024
2 checks passed
@juan131 juan131 deleted the bugfix/insecure-oci-registry branch September 12, 2024 10:00
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants