-
Notifications
You must be signed in to change notification settings - Fork 9.3k
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] problems deploying chart mastodon-init never finished when initJob.createAdmin is true #14485
Comments
Please note in the values.yaml file the initJob:
createAdmin: true |
Yes, yaml format is valid which is copied from charts/mastodon/value.yaml. Only the following config works.
|
Hi @showxu, Thank you for reporting this issue. Could you please share the values $ k get cm <your-release-name>-mastodon-default -o yaml
apiVersion: v1
data:
DB_HOST: test-postgresql
DB_NAME: bitnami_mastodon
DB_PORT: "5432"
DB_USER: bn_mastodon
ES_ENABLED: "true"
ES_HOST: test-elasticsearch
ES_PORT: "9200"
MASTODON_ADMIN_EMAIL: [email protected]
MASTODON_ADMIN_USERNAME: user
... There was an issue with the Mastodon default values, that forced us to change the default email Version 1.0.0 of the chart still uses |
Additionally, I would like to mention that failed pods from previous deployment jobs won't be deleted automatically, so it is possible that the mastodon-init pod corresponds to a previously failed deployment using the default |
Since I always use My failed deployment values.yaml as follows: adminUser: "admin"
## @param adminEmail Mastodon admin email
##
adminEmail: "[email protected]"
## @param adminPassword Mastodon admin password
##
adminPassword: "abc1234567890" It failed and I think this user name "admin" is preserved, so I changed to: adminUser: "admin2"
## @param adminEmail Mastodon admin email
##
adminEmail: "[email protected]"
## @param adminPassword Mastodon admin password
##
adminPassword: "abc1234567890" also failed, and then I use my real one: adminUser: "showxu"
## @param adminEmail Mastodon admin email
##
adminEmail: "[email protected]"
## @param adminPassword Mastodon admin password
##
adminPassword: "abc1234567890" and it fails again. Both 'admin2' and 'showxu' can be created by tootctl. |
By the way, I didn't use the configmap, I use the values.yaml directly which was copied form this repo like: helm install mastodon -f './application/mastodon/values.yaml' bitnami/mastodon |
That is what I meant, Pods from failed jobs are not removed after |
For the |
To my case, I always used |
I was able to reproduce the The list of reserved usernames in the latest version (4.0.2) is:
|
After several deployment to docker-desktop, everything is ok and I think I can't reproduce this issue with |
It seems that only the first deployment you can set createAdmin: true (which is the default), after that, all updates or re-installation will fail unless you set it to be false. I think the admin info probably is in database, which usually we don't delete. Maybe the create process should check if the admin user is already in the db and not try to create even it's set to be true? |
See bitnami/charts#14485. If the admin user/email is already exist, the current code exists with error instead of skipping account creation, because the testing expects "been taken" string from tootctl command, however tootctl in the 4.2.0 release that I tested, return different string: ``` res=$(tootctl accounts create "$MASTODON_ADMIN_USERNAME" --email "$MASTODON_ADMIN_EMAIL" "--confirmed" "--role" "Owner") $ echo $res Failure/Error: email taken Failure/Error: account.username taken ``` Simply change the testing string to "taken" fix this issue. Signed-off-by: Xueshan Feng <[email protected]>
Thank you so much for the PR! |
Name and Version
mastodon-1.0.0 4.0.2
What steps will reproduce the bug?
mastodon-1.0.0 4.0.2 deployed on both TKG and docker-desktop
values.yaml
$ kubectl logs mastodon-init-5l8sb
, console output:Are you using any custom parameters or values?
NO
What is the expected behavior?
state of
mastodon-web-xxxx
shows Completed instead of NetReadyWhat do you see instead?
Additional information
I have to turn off the
initJob.createAdmin: false
, and create admin manually withtootctl
.The text was updated successfully, but these errors were encountered: