Comment 9 for bug 2045897

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to platform-armada-app (master)

Reviewed: https://review.opendev.org/c/starlingx/platform-armada-app/+/906374
Committed: https://opendev.org/starlingx/platform-armada-app/commit/855c7b1da9ab3779397ffffbc49b7a6e03bca115
Submitter: "Zuul (22348)"
Branch: master

commit 855c7b1da9ab3779397ffffbc49b7a6e03bca115
Author: Gabriel de Araújo Cabral <email address hidden>
Date: Tue Jan 23 10:15:33 2024 -0300

    Add check for csi-snapshotter container creation

    This commit introduces a check to determine whether or not the
    csi-snapshotter container will be created in each provisioner's
    pod.

    The only scenario in which the 'provisioner.snapshotter.enabled'
    field will automatically be set to 'true' and the csi-snapshotter
    container will be created during apply is with:
    - CRDs created: volumesnapshotclasses, volumesnapshots and
      volumesnapshotcontents.
    - Snapshot-controller pod created and using the correct image
      according to the K8s version.

    In all other scenarios, 'provisioner.snapshotter.enabled' will be
    set to 'false' during apply and the container will not be created.

    Remembering that the user can create/remove the container manually
    if desired via helm override.

    Depends-on: https://review.opendev.org/c/starlingx/platform-armada-app/+/904875

    Test Plan:
     PASS: Build a new app package with the code changes
     PASS: Successfully execute upload, apply, remove, and delete
           operations for platform-integ-apps
     PASS: In an environment with CRDs and snapshot-controller using
           the correct image version according to Kubernetes, apply the
           app and verify that the snaphotter field is 'enabled: true'
           and the container has been created in both provisioner pods
     PASS: In an environment with CRDs but with snapshot-controller
           using the incorrect image version according to Kubernetes,
           apply the app and verify that the snaphotter field is
           'enabled: false' and the container has not been created
     PASS: In an environment without CRDs and snapshot-controller, apply
           the app and verify that snaphotter field is 'enabled: false'
           and the container has not been created
     PASS: Manually create/remove csi-snapshotter container via
           helm-override

    Partial-Bug: 2045897

    Change-Id: I7dbcbba520c9758de84e8dae5a553ec1fee69518
    Signed-off-by: Gabriel de Araújo Cabral <email address hidden>