NatLabRockies / NatLabRockies/openstudio-server-helm

Chore: remove dead-code configmaps/nfs-cm.yaml and configmaps/nfs/exports

Open Beginner friendly
#104 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Go Template
Stars
12
Forks
24
PR merge metrics
No merged PRs in 30d

Description

Summary

Two files in the chart are dead code — they have never been rendered by
helm template and no template references them.

Files

  • openstudio-server/configmaps/nfs-cm.yaml — at the root of
    configmaps/, not under templates/. helm template only
    renders files under templates/, so this file is never emitted.
    The helm-unittest output and the rendered chart confirm: no
    ConfigMap or nfs-cm reference appears in the rendered output.

  • openstudio-server/configmaps/nfs/exports — referenced only by
    the dead nfs-cm.yaml (which uses
    (.Files.Glob "configmaps/nfs/*").AsConfig). Since
    nfs-cm.yaml is never rendered, the contents of this exports
    file are also never used.

Verification

helm template smoketest ./openstudio-server --set provider.name=google | grep -i "kind: ConfigMap"
# (no output)

helm template smoketest ./openstudio-server --set provider.name=google | grep -i "nfs-cm"
# (no output)

Background

The chart started on a helm create scaffold and was hand-rolled
after that. The NFS exports ConfigMap was originally meant to seed
the NFS server provisioner subchart, but the real NFS provisioning
path is the subchart's own PVC + RBAC, not a ConfigMap. The dead
files have been in the repo since the chart's inception and were
spotted during the PR #102 review.

Proposed change

Delete both files in a single chore commit. No template or value
changes; helm template output is byte-identical before and after.

git rm openstudio-server/configmaps/nfs-cm.yaml
git rm openstudio-server/configmaps/nfs/exports
# optionally: remove the now-empty configmaps/nfs/ directory

Out of scope

  • The chart's other working NFS bits (templates/nfs/nfs-pvc.yaml,
    the nfs-server-provisioner subchart in Chart.yaml) — these are
    load-bearing and stay.
  • Any change to the rendered chart at default values.

Related

  • PR #102 review (C2 finding)

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Inspect openstudio-server/configmaps/nfs-cm.yaml and openstudio-server/configmaps/nfs/exports, then run the provided helm template and grep commands to confirm neither file contributes rendered output. Remove both files without changing templates or values, and verify the rendered chart remains unchanged and the configmaps/nfs directory is empty or removed.

Written by the indexing model from the issue text.

Assessment

Tech stack
helm
Domain
infrastructure
Issue type
Refactor
Difficulty
1/5
Estimated time
Under an hour
Activity status
Quiet
Clarity
Clearly specified
Newbie friendliness
91/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.