Skip to content

Commit

Permalink
Review batch 1
Browse files Browse the repository at this point in the history
  • Loading branch information
VariableDeclared committed Mar 27, 2024
1 parent 7fd24aa commit 071b46e
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 8 deletions.
8 changes: 5 additions & 3 deletions charmcraft.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -12,11 +12,13 @@ bases:
- name: ubuntu
channel: "20.04"
architectures:
- "amd64"
- amd64
- arm64
- name: ubuntu
channel: "22.04"
architectures:
- "amd64"
architectures:
- amd64
- arm64
parts:
charm:
build-packages:
Expand Down
9 changes: 4 additions & 5 deletions src/storage_manifests.py
Original file line number Diff line number Diff line change
Expand Up @@ -105,7 +105,7 @@ def __init__(self, charm, charm_config, kube_control, integrator):
ConfigRegistry(self),
CreateStorageClass(self, "default"), # creates csi-cinder-default
UpdateSecrets(self), # update secrets
UpdateControllerPlugin,
UpdateControllerPlugin(self),
],
)
self.integrator = integrator
Expand Down Expand Up @@ -151,7 +151,6 @@ def __call__(self, obj):
"""Update the controller args in Deployments."""
if not any(
[
(obj.kind == "DaemonSet" and obj.metadata.name == "csi-cinder-nodeplugin"),
(obj.kind == "Deployment" and obj.metadata.name == "csi-cinder-controllerplugin"),
]
):
Expand All @@ -161,6 +160,6 @@ def __call__(self, obj):
if container.name == "csi-provisioner":
for i, val in enumerate(container.args):
if "feature-gates" in val.lower():
container.args[i] = f"feature-gates=Topology={self.manifests.config.get('topology')}"
log.info(f"Disabling cinder topology awareness")

topology = str(self.manifests.config.get("topology")).lower()
container.args[i] = f"feature-gates=Topology={topology}"
log.info(f"Configuring cinder topology awareness=%s", topology)

0 comments on commit 071b46e

Please sign in to comment.