-
Notifications
You must be signed in to change notification settings - Fork 37
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fix configMap key value template #110
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@nuriel77 - thank you for your contribution. I verified these changes locally on my machine, as well. The changes look good, except for one more place that needs to be updated. Can you also update this template too? Thanks.
pulsar-helm-chart/helm-chart-sources/pulsar/templates/bookkeeper/bookkeeper-configmap.yaml
Lines 71 to 74 in 3fd374a
{{ toYaml .Values.bookkeeper.configData | indent 2 }} | |
# Workaround for double-quoted values in old values files | |
BOOKIE_MEM: {{ .Values.bookkeeper.configData.BOOKIE_MEM }} | |
BOOKIE_GC: {{ .Values.bookkeeper.configData.BOOKIE_GC }} |
@michaeljmarshall you're right. I missed those because I only searched for |
I'll take care of bumping the version.
Thanks for finding that other reference. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
It looks like our Circle CI tests didn't run. I think that is likely because this is from a new fork of our helm chart. I'll need to look into this before we can merge the PR. |
@nuriel77 - based on reading through this doc https://circleci.com/docs/2.0/oss/#build-pull-requests-from-forked-repositories, I am wondering if the following applies to your fork:
We have |
I guess it is. Never worked with CircleCI. In any case, I don't think I could have pushed a PR directly to the repository, but only via a fork, right? |
That's helpful. I assumed that the documentation meant something specific for CircleCI. Since you've never worked with it before, maybe this line (
That is correct. I have definitely seen tests run for PRs opened in forks, so it should work. I'll take a closer look in about 12 hours. |
I am going to close and reopen this PR to see if it triggers the CI. It's possible that my initial "Request Changes" prevented CI from running. |
Overview
In this commit, based on issue 103 I suggested to omit the
toYaml
and instead use key value iteration to produce the configMap configData.This should solve the issue of duplicated keys in the configMap and also keep backward compatibility with values provided with two sets of double quotes.
@michaeljmarshall I wasn't sure if I have to bump the Chart's version or is that something your automation takes care of.
Tested Values
I have tested using
helm template .
while testing different ways of configuring the values for configData:Option 1:
Option 2:
Option 3 (should be the same for single-quotes):
Option 4:
Outputs
I have tested the output of the configMaps that could be produced by the chart:
pulsar-bastion:
pulsar-broker:
pulsar-brokerSts:
pulsar-function-extra:
pulsar-proxy:
pulsar-proxy-ws
pulsar-zookeepernp
pulsar-zookeeper: