rancher / elemental-operator

The Elemental operator is responsible for managing the OS versions and maintaining a machine inventory to assist with edge or baremetal installations.
Apache License 2.0
40 stars 17 forks source link

Add list of supported Channels #797

Closed anmazzotti closed 1 month ago

anmazzotti commented 1 month ago

This PR introduces support to define a list of "official" channels. The intention is to consume this list to offer out-of-the-box options to users who are using the Elemental UI extension. Each channel definition contains some human readable information that can be used to provide a list.

This is aligned with the channels documentation.

The defaultName can also be used to provide an opinionated name for the channel during creation.

Currently it looks like this:

apiVersion: elemental.cattle.io/v1beta1
kind: Metadata
metadata:
  annotations:
    meta.helm.sh/release-name: elemental-operator
    meta.helm.sh/release-namespace: cattle-elemental-system
  creationTimestamp: "2024-07-11T08:43:41Z"
  generation: 2
  labels:
    app.kubernetes.io/managed-by: Helm
  name: elemental-operator
  namespace: cattle-elemental-system
  resourceVersion: "7824"
  uid: 7de42596-dbc1-4607-ae9e-4366060b81d2
spec:
  annotations:
    catalog.cattle.io/auto-install: elemental-operator-crds=match
    catalog.cattle.io/certified: rancher
    catalog.cattle.io/display-name: Elemental
    catalog.cattle.io/kube-version: '>= 1.23.0-0'
    catalog.cattle.io/namespace: cattle-elemental-system
    catalog.cattle.io/os: linux
    catalog.cattle.io/permits-os: linux
    catalog.cattle.io/provides-gvr: elemental.cattle.io/v1beta1
    catalog.cattle.io/rancher-version: '>= 2.7.0-0'
    catalog.cattle.io/release-name: elemental-operator
    catalog.cattle.io/scope: management
    catalog.cattle.io/type: cluster-tool
    catalog.cattle.io/upstream-version: v1.7.0-dev
  appVersion: v1.7.0-dev
  channels:
    - baseOS: SLE Micro
      baseOSVersion: "5.5"
      defaultName: sle-micro-5-5
      description: Default channel that can be used for any generic workload.
      uri: registry.opensuse.org/isv/rancher/elemental/dev/containers/rancher/elemental-channel/sle-micro:5.5
    - baseOS: SLE Micro
      baseOSVersion: "5.5"
      defaultName: sle-micro-5-5-kvm
      description: Ready to be used with KVM. Contains QEMU Guest agent by default.
      flavor: KVM
      uri: registry.opensuse.org/isv/rancher/elemental/dev/containers/rancher/elemental-channel/sle-micro:5.5-kvm
    - baseOS: SLE Micro
      baseOSVersion: "5.5"
      defaultName: sle-micro-5-5-rt
      description: Channel that can be used for any generic workload with a Real-Time kernel.
      flavor: RT
      uri: registry.opensuse.org/isv/rancher/elemental/dev/containers/rancher/elemental-channel/sle-micro:5.5-rt
anmazzotti commented 1 month ago

Closing this PR in favor of a different solution.