weaveworks / weave-gitops-enterprise

This repo provides the enterprise level features for the weave-gitops product, including CAPI cluster creation and team workspaces.
https://docs.gitops.weave.works/
Apache License 2.0
160 stars 29 forks source link

Using more than one Helm repositories for profiles for installation #1177

Open saeedfazal opened 2 years ago

saeedfazal commented 2 years ago

Currently only one HelmRepository object weaveworks-chartscan be defined pointing to a single helm chart repository for profile installation. However, as a user I want to configure multiple helm repositories to be used and available for profile installation during CAPI cluster creation.

User story:

foot commented 2 years ago

User story:

At the moment can only have a single profile-repo (helmrepo).

foot commented 2 years ago

The helmrepo caching system might already support caching multiple repos etc.

There are places in EE at least where we assume a single repo. Places to consider:

foot commented 1 year ago

Technically we can support multiple helm repos now.. it doesn't work in the UI really, from gitops create template it would though

apiVersion: templates.weave.works/v1alpha2
kind: GitOpsTemplate
metadata:
  name: multi-profile
  namespace: default
  annotations:
    templates.weave.works/profiles-enabled: "false"
    templates.weave.works/delimiters: "${{,}}"
spec:
  renderType: templating
  params:
    - name: CLUSTER_NAME
      required: true
      description: This is used for the cluster naming.
  charts:
    items:
      - chart: cert-manager
        targetNamespace: cert-manager
        version: 0.0.8
        template:
          content:
            metadata:
              namespace: ${{ .params.NAMESPACE }}
            spec:
              chart:
                spec:
                  sourceRef:
                    name: bitnami
                    namespace: ${{ .params.NAMESPACE }}
      - chart: weave-policy-agent
        targetNamespace: policy-agent
        template:
          content:
            metadata:
              namespace: ${{ .params.NAMESPACE }}
            spec:
              chart:
                spec:
                  sourceRef:
                    name: profiles-catalog
                    namespace: ${{ .params.NAMESPACE }}
  resourcetemplates:
    - path: "${{ .params.NAMESPACE }}/helmrepos/bitnami.yaml"
      content:
        - apiVersion: source.toolkit.fluxcd.io/v1beta1
          kind: HelmRepository
          metadata:
            name: bitnami
            namespace: ${{ .params.NAMESPACE }}
          spec:
            url: https://charts.bitnami.com/bitnami
    - path: "${{ .params.NAMESPACE }}/helmrepos/profiles-catalog.yaml"
      content:
        - apiVersion: source.toolkit.fluxcd.io/v1beta1
          kind: HelmRepository
          metadata:
            name: profiles-catalog
            namespace: ${{ .params.NAMESPACE }}
          spec:
            url: https://charts.bitnami.com/bitnami
bigkevmcd commented 1 year ago

This is in-progress.

foot commented 9 months ago

cc @LappleApple we underestimated this one and are putting it on pause for now.