Skip to content
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: Allow using boolean and integer as a value in with MM_* config helm parameters #447

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

mike-code
Copy link

Fixes #238

Summary

This fix allows setting integers and booleans as values for helm parameters.

Description

Without this fix, using boolean as a value in any config.MM_* helm parameter would result in the following error

$ helm template my-setup . --set config.MM_SERVICESETTINGS_ENABLEAPIUSERDELETION="true"
Error: template: mattermost-team-edition/templates/secret-config.yaml:13:24: executing "mattermost-team-edition/templates/secret-config.yaml" at <b64enc>: wrong type for value; expected string; got bool

A workaround would be to wrap the quoted boolean in single quotes ie.

--set config.MM_SERVICESETTINGS_ENABLEAPIUSERDELETION='"true"'

however this environment variable would be rejected by the mattermost server and thus the user API deletion would still be disabled.

@mattermost-build
Copy link
Contributor

Hello @mike-code,

Thanks for your pull request! A Core Committer will review your pull request soon. For code contributions, you can learn more about the review process here.

Per the Mattermost Contribution Guide, we need to add you to the list of approved contributors for the Mattermost project.

Please help complete the Mattermost contribution license agreement?
Once you have signed the CLA, please comment with /check-cla and confirm that the CLA check is green.

This is a standard procedure for many open source projects.

Please let us know if you have any questions.

We are very happy to have you join our growing community! If you're not yet a member, please consider joining our Contributors community channel to meet other contributors and discuss new opportunities with the core team.

@mike-code mike-code changed the title Fixes issue with MM_* vars not accepting boolean Fix: Allow using boolean and integer as a value in with MM_* config helm parameters Feb 29, 2024
@mattermost-build
Copy link
Contributor

This PR has been automatically labelled "stale" because it hasn't had recent activity.
A core team member will check in on the status of the PR to help with questions.
Thank you for your contribution!

@mike-code
Copy link
Author

/check-cla

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

configJSON is not working as per readme
2 participants