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

[bitnami/mastodon] Move defaultConfig and defaultSecretConfig to default-configmap.yaml and default-secret.yaml respectively and add mastodon secret env vars #19179

Merged
merged 20 commits into from
Nov 2, 2023

Conversation

jessebot
Copy link
Contributor

@jessebot jessebot commented Sep 7, 2023

Description of the change

Moves the templated values for defaultConfig and defaultSecretConfig into default-configmap.yaml and default-secret.yaml respectively.

Also makes the adminUser, adminEmail, and smtp.server values optional, so that they can be provided via an external secret instead.

Adds new otpSecret, secretBaseKey, vapidPublicKey and vapidPrivateKey as parameters, as they did not have them before but are required as per mastodon secrets docs. I didn't see anything in the Bitnami helm chart or Bitnami container for mastodon that actually generates these though, so I put a note that you need to use rake to generate them.

defaultConfig and defaultSecret are currently gone, because you can still specify extra ConfigMap/Secret values, or alternative ConfigMap/Secret.

Benefits

This allows users to use external tools that utilize go templating, e.g. Argo CD ApplicationSets using generators, without running into conflicts.

Possible drawbacks

Not sure there are any, as alternative or extra configuration can still be specified for both ConfigMap/Secrets.

There's enough mastodon parameters, perhaps it makes sense to have a mastodon.secrets param that we nest params like otpSecret, secretBaseKey, vapidPublicKey and vapidPrivateKey under.

Applicable issues

Additional information

Let me know if there's anything you want to change.

Checklist

  • Chart version bumped in Chart.yaml according to semver. This is not necessary when the changes only affect README.md files.
  • Variables are documented in the values.yaml and added to the README.md using readme-generator-for-helm
  • Title of the pull request follows this pattern [bitnami/<name_of_the_chart>] Descriptive title
  • All commits signed off and in agreement of Developer Certificate of Origin (DCO)

…and default-secret.yaml respectively

Signed-off-by: jessebot <jessebot@linux.com>
Signed-off-by: jessebot <jessebot@linux.com>
@bitnami-bot bitnami-bot added this to Triage in Support Sep 7, 2023
@github-actions github-actions bot added the triage Triage is needed label Sep 7, 2023
…d none' conditional

Signed-off-by: jessebot <jessebot@linux.com>
@carrodher carrodher moved this from Triage to In progress in Support Sep 8, 2023
@carrodher carrodher added the verify Execute verification workflow for these changes label Sep 8, 2023
@github-actions github-actions bot added in-progress and removed triage Triage is needed labels Sep 8, 2023
@bitnami-bot bitnami-bot removed the request for review from carrodher September 8, 2023 10:43
Signed-off-by: jessebot <jessebot@linux.com>
… passed into mastodon default secret

Signed-off-by: jessebot <jessebot@linux.com>
…eady pass it in with the default-secret

Signed-off-by: jessebot <jessebot@linux.com>
@jessebot jessebot changed the title [bitnami/mastodon] Move defaultConfig and defaultSecretConfig to default-configmap.yaml and default-secret.yaml respectively [bitnami/mastodon] Move defaultConfig and defaultSecretConfig to default-configmap.yaml and default-secret.yaml respectively and add mastodon secret env vars Sep 8, 2023
… it's no longer in use

Signed-off-by: JesseBot <jessebot@linux.com>
Signed-off-by: JesseBot <jessebot@linux.com>
@github-actions
Copy link

github-actions bot commented Oct 8, 2023

This Pull Request has been automatically marked as "stale" because it has not had recent activity (for 15 days). It will be closed if no further activity occurs. Thank you for your contribution.

@github-actions github-actions bot added the stale 15 days without activity label Oct 8, 2023
…e existing secret parameter

Signed-off-by: jessebot <jessebot@linux.com>
@jessebot
Copy link
Contributor Author

@fevisera no problem, and thanks for circling back around to this :) I've addressed and/or corrected everything. Happy to chat more about anything here or fix any other bugs you notice.

@fevisera
Copy link
Contributor

Hi,

Sorry for the delay. Kindly take a moment to check the comment I added regarding the chart version bump.

Thanks.

@github-actions github-actions bot moved this from In progress to Pending in Support Oct 26, 2023
bitnami/mastodon/Chart.yaml Outdated Show resolved Hide resolved
Signed-off-by: JesseBot <jessebot@linux.com>
@github-actions github-actions bot moved this from Pending to In progress in Support Oct 29, 2023
@jessebot
Copy link
Contributor Author

@fevisera thanks again for reviewing! I've responded and I think this is finally ready to go :)

@fevisera
Copy link
Contributor

Hi @jessebot,

I'm having an issue running the cluster with the current modifications. It seems a data.server parameter is being missed in smtp-secret.yml. By adding the following line fixes to me:

 data:
   login: {{ .Values.smtp.login | b64enc | quote }}
   password: {{ .Values.smtp.password | b64enc | quote }}
+  server: {{ .Values.smtp.server | b64enc | quote }}
 {{- end }}

Could you please have a look at it?

Also, I left some other comments related to some typos.

Please, bump the version and I believe this would be all.

Thanks!

@github-actions github-actions bot moved this from In progress to Pending in Support Oct 31, 2023
bitnami/mastodon/README.md Outdated Show resolved Hide resolved
bitnami/mastodon/values.yaml Outdated Show resolved Hide resolved
jessebot and others added 2 commits November 2, 2023 09:54
Signed-off-by: JesseBot <jessebot@linux.com>
Signed-off-by: Bitnami Containers <bitnami-bot@vmware.com>
@github-actions github-actions bot moved this from Pending to In progress in Support Nov 2, 2023
@jessebot
Copy link
Contributor Author

jessebot commented Nov 2, 2023

Taking a look later today!

By the way, when you find an easy fix, such as a typo or grammar issue on a PR, you can add Suggestions via the plus/minus button in the comment window on the file:
screenshot of the suggestions button

then it automatically generates a suggestions block where you can put in your changes, such as this example:
suggestions screenshot of editing a line to add more details

Which then shows up as something that can easily be clicked and added either in a batch to one large commit or in individual commits by the PR author, or if maintainer edits are turned on, by the reviewer. Example:
suggestions screenshot showing the suggestion feature in action

You can read more here on how to apply suggestions if someone has made a suggestion on a PR you've submitted or edits by maintainers are turned on:
https://docs.github.com/en/pull-requests/collaborating-with-pull-requests/reviewing-changes-in-pull-requests/incorporating-feedback-in-your-pull-request

This hasn't been a big problem for me on this PR or anything, I just wanted to give a friendly tip as it can help speed up the time it takes to collaborate in the future.

Signed-off-by: JesseBot <jessebot@linux.com>
Signed-off-by: jessebot <jessebot@linux.com>
@jessebot
Copy link
Contributor Author

jessebot commented Nov 2, 2023

Committed your smtp secret suggestion. Thanks for taking the time to test all of this 💙

Copy link
Contributor

@fevisera fevisera left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hi @jessebot,

Thanks a lot for your tip! It is incredibly helpful, and I will definitely use it.

Also, thanks for reviewing the suggestions and applying the changes once again.

LGTM!

@fevisera fevisera merged commit 6175b41 into bitnami:main Nov 2, 2023
8 checks passed
@bitnami-bot bitnami-bot moved this from In progress to Solved in Support Nov 2, 2023
@github-actions github-actions bot removed this from Solved in Support Nov 9, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
mastodon solved verify Execute verification workflow for these changes
Projects
None yet
4 participants