Missing elements in values.yaml, rendering problems in helm templates (#7)
Open
rk@tigase.net opened 2 days ago

Issue: https://tigase.dev/tigase/helm-charts/~issues/4

Fix consists in

  1. updating values.yaml with the correct names of parameters referred to in templates
  2. and fixing templates/ to ensure correct YAML indentation.

Tested using:

    % helm template inventory-checker . -n inventory-checker-test -f values.yaml --debug

and deploying the configuration on namespace:

    % kubectl get ns inventory-checker-test || kubectl create ns inventory-checker-test
    //..
    % helm upgrade --install inventory-checker . -n inventory-checker-test -f values.yaml
    Release "inventory-checker" has been upgraded. Happy Helming!
NAME: inventory-checker
LAST DEPLOYED: Tue Sep  2 14:36:53 2025
NAMESPACE: inventory-checker-test
STATUS: deployed
REVISION: 2
TEST SUITE: None
    % kubectl get all -n inventory-checker-test
    NAME                                              READY   STATUS    RESTARTS   AGE
pod/inventory-checker-kaui-c66644c4c-jc4xj        1/1     Running   0          58m
pod/inventory-checker-killbill-59777b7657-ftgn4   1/1     Running   0          58m

NAME                                      TYPE           CLUSTER-IP      EXTERNAL-IP       PORT(S)          AGE
service/inventory-checker-kaui            ClusterIP      10.96.189.222   <none>            8080/TCP         3m27s
service/inventory-checker-killbill        LoadBalancer   10.96.37.65     141.148.143.149   8080:30333/TCP   3m27s
service/inventory-checker-test-kaui       ClusterIP      10.96.135.217   <none>            8080/TCP         7d16h
service/inventory-checker-test-killbill   LoadBalancer   10.96.69.71     132.226.65.52     8080:30743/TCP   7d16h

NAME                                         READY   UP-TO-DATE   AVAILABLE   AGE
deployment.apps/inventory-checker-kaui       1/1     1            1           58m
deployment.apps/inventory-checker-killbill   1/1     1            1           58m

NAME                                                    DESIRED   CURRENT   READY   AGE
replicaset.apps/inventory-checker-kaui-c66644c4c        1         1         1       58m
replicaset.apps/inventory-checker-killbill-59777b7657   1         1         1       58
 % 

Source branch is outdated
There are merge conflicts. Please follow this instruction to resolve the conflicts
Pull request can not be merged now as it is pending review
  • Andrzej Wójcik (Tigase) commented 1 day ago

    I'm sorry, but I do not think those changes resolve the issues and from my quick review they are introducing issues as well, ie.:

    • file killbill/templates/deployment.yaml there are hardcoded labels,
    • files killbill/templates/inventory-checker-ingress.yaml and killbill/templates/inventory-checker-service.yaml are using .Values.sidecar.name while whole sidecar section was removed from values.yaml (at least that is how it looks like).

    As for indentation issues, if you would pull changes from the master branch, you would see that those were already resolved by me about 2 weeks ago (on 20th of August)

    As for mentioned issue with missing parameters in values.yaml, you mentioned killbill.databaseName in _helpers.yaml. Those were included in depoyment file, and used .Values.database.killbill and not .Values.killbill.databaseName. Without changes you introduced to _helpers.yaml I do not see any incorrect or missing values in values.yaml files.

    I would prefer to reduce (or not introduce any new) changes to the values in values.yaml and their names as we do have separate values.yaml file that is used for deployment and we will need to adjust it as well during deployment. Each rename forces us to remember to rename value used by Helm/Flux.

  • rk@tigase.net commented 22 hours ago

    Aim of this PR is re-enabling the inventory checker sidecar, which I previously disabled. The immediate goal is to:

    • Introduce the inventory checker image in the Helm chart
    • Do so safely, without activating the sidecar or modifying unrelated chart components

    Although some changes in this PR previously overlapped with issues that have now been fixed in master, I started addressing them independently before those fixes were present.

    I began this work on Aug 19, based on a local branch that predates some recent changes to master. At the time, master still had YAML indentation issues that caused helm template to fail. I began fixing them independently, unaware that these were fixed in master on Aug 20:

      % git merge-base bugfix/sidecar-res master
      3d2540011754f291460f85448b69c1edfd5e094c
      % git show -s --format=%ci  3d2540011754f291460f85448b69c1edfd5e094c
      2025-08-19 19:12:39 -0700
      %
    

    This confirms that I started work before the indentation fixes were committed to master on Aug 20. However, I disagree with your comment that

    I’m sorry, but I do not think those changes resolve the issues…

    This PR does contain the fixes to the indentation issues. This is demonstrated by the fact that helm renders templates from my branch into a test cluster without error:

     % git branch --show-current       
     bugfix/sidecar-res
     % 
     % helm upgrade --install inventory-checker . -n inventory-checker-test -f values.yaml
      <test cluster 'inventory-checker' up and running>
     %
    

    However, the fixes in my branch for the indentation issues are the fixes you committed to master on Aug 20: your fixes percolated into this PR by my use of git pull origin master after Aug 20:

      %
      % git log --graph --oneline --decorate
      //...
       *   3b31ded Merge branch 'bugfix/fix-deployment-yaml'
       |\
       | * faa8c35 (bugfix/fix-deployment-yaml) Added missing separator between sidecar and ingress
       | * aa3e774 fix: prevent duplicate image tags in Kill Bill deployment
       |/
       //..
      %
    

    In any case, I want to refocus this PR as follows.

    What This PR Does

    • Adds inventory-checker.image definition back to values.yaml
    • Safely introduces that image into the Helm deployment templates (without activating the sidecar)
    • Keeps scope narrow, preparing for a clean future re-enable

    This PR does not

    • enable the sidecar container
    • modify service or ingress for inventory checker
    • affect killbill-prod behavior

    I am going to now focus this PR on defining the sidecar image and activiating it using helm charts.

pull request 1 of 1
Submitter rk@tigase.net
Target master
Source bugfix/sidecar-res
Assignees
Merge Strategy
Create Merge Commit
Auto Merge OFF
Enable this option to merge the pull request automatically when ready (all reviewers approved, all required jobs passed etc.)
Watchers (3)
Reference
pull request tigase/helm-charts#7
Please wait...
Page is in error, reload to recover