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

Want to deploy ACK controllers from helm repository #958

Closed
nab-gha opened this issue Sep 15, 2021 · 5 comments
Closed

Want to deploy ACK controllers from helm repository #958

nab-gha opened this issue Sep 15, 2021 · 5 comments
Labels
kind/enhancement Categorizes issue or PR as related to existing feature enhancements.

Comments

@nab-gha
Copy link

nab-gha commented Sep 15, 2021

Is your feature request related to a problem?
Although #461 and #550 are closed I still can't work out how to access the helm repository that the ACK controller helm charts are deployed to.

Describe the solution you'd like
Be able to do helm repo add to get access to helm charts. My actual preferred approach is to create a 'helmrepositories.source.toolkit.fluxcd.io' custom resource that can be used to install ACK controllers using the Flux2 Helm-Controller.

Describe alternatives you've considered
Alternative is to reference the helm charts directory in the github repo for each ACK controller

@nab-gha nab-gha added the kind/enhancement Categorizes issue or PR as related to existing feature enhancements. label Sep 15, 2021
@vijtrip2
Copy link
Contributor

Helm repo is setup and functional. Are you exporting following variable before pulling chart? export HELM_EXPERIMENTAL_OCI=1

Please see this doc which installs ACK controllers using Helm.

And looks like the support for OCI charts is yet not present in fluxcd, but the issue is open.
fluxcd/source-controller#124

@dervos
Copy link

dervos commented Sep 16, 2021

A workaround is possible by using the GitRepository source kind instead of HelmRepository:

apiVersion: source.toolkit.fluxcd.io/v1beta1
kind: GitRepository
metadata:
  name: s3-controller
spec:
  interval: 1h0m0s
  ref:
    tag: v0.0.3
  url: https://github.com/aws-controllers-k8s/s3-controller

And referencing the chart location in the helm release:

apiVersion: helm.toolkit.fluxcd.io/v2beta1
kind: HelmRelease
metadata:
  name: ack-s3-controller
spec:
  releaseName: ack-s3-controller
  chart:
    spec:
      chart: ./helm/
      sourceRef:
        kind: GitRepository
        name: s3-controller

Keep in mind that you're now relying on the referenced repositories versioning instead of referencing the helm version in your HelmRelease, which can have unexpected side-effects.

@vijtrip2
Copy link
Contributor

vijtrip2 commented Sep 16, 2021

@dervos , very good suggestion.
I want to add one thing to your suggestion. main branch can have breaking changes so in the url you can specify the exact source release like https://github.com/aws-controllers-k8s/s3-controller/tree/v0.0.3 , and it will be identical to pulling the helm OCI chart from public ecr repo.

@dervos
Copy link

dervos commented Sep 20, 2021

@vijtrip2: I would recommend against referencing the specific version using the URL. GitRepository references the specific version using spec.ref.tag for git tags. Documentation: https://fluxcd.io/docs/components/source/api/#source.toolkit.fluxcd.io/v1beta1.GitRepositoryRef

@vijtrip2
Copy link
Contributor

Please reopen if the suggestion from @dervos does not fix your problem.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
kind/enhancement Categorizes issue or PR as related to existing feature enhancements.
Projects
None yet
Development

No branches or pull requests

3 participants