Uploaded image for project: 'Red Hat OpenStack Services on OpenShift'
  1. Red Hat OpenStack Services on OpenShift
  2. OSPRH-1363

CRs should be modified with kustomize instead of using copied samples

XMLWordPrintable

    • Icon: Epic Epic
    • Resolution: Done
    • Icon: Normal Normal
    • rhos-18.0.0
    • None
    • None
    • None
    • kustomize-crs
    • False
    • Hide

      None

      Show
      None
    • False
    • Proposed
    • No Docs Impact
    • To Do
    • Proposed
    • Proposed
    • 0% To Do, 0% In Progress, 100% Done
    • Rejected
    • 2024Q2

      As part of the discussion on how to decouple ci-framework and install_yamls in Brno, there was a proposal raised that the general UX for our product when it comes to creating CRs ought to be starting with our provided samples and using kustomize to modify them as needed.

      This differs from what we presently recommend in the docs which document different procedures that typically start with copying a sample and then modifying the copy before using oc create/apply to manage the CR.

      Instead, we ought to document writing kustomization files, then the user running oc kustomize to modify those files as they are passed to oc create/apply.

      The following reasons support this approach:

      1. It more closely matches what we already automate in install_yamls where kustomization files are generated instead of modifying samples directly.
      2. It ensures that ci-framework can apply all needed customizations for a deployment (or any operation) using kustomize. This is not necessarily the case today and has led to custom modules being developed to transform YAML as required. It has also led to reliance on install_yamls doing some transformations
      3. It's more apparent what changes customers have applied to samples when looking at the kustomization files versus looking at a modified sample and having to diff files.
      4. While it should be minimal (or never) that we have breaking CRD API changes, it will be easier for users to update their kustomizations instead of having to update an entire copied sample.

      Users may also want to write CRs from scratch. That is valid as well and may be easier in some complex cases. However, when it comes to starting from a provided sample, using kustomize ought to be the approach.

       

              rhn-engineering-faguiard Fabricio Aguiar de Oliveira
              jslagle@redhat.com James Slagle
              rhos-dfg-df
              Votes:
              0 Vote for this issue
              Watchers:
              15 Start watching this issue

                Created:
                Updated:
                Resolved: