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

Define a default admin username and password with an env variable #4560

Closed
dramamask opened this issue Aug 23, 2023 · 3 comments · Fixed by #4927
Closed

Define a default admin username and password with an env variable #4560

dramamask opened this issue Aug 23, 2023 · 3 comments · Fixed by #4927
Assignees
Labels
enhancement feature request A wish for Unleash to do something it doesn't already do. good first issue

Comments

@dramamask
Copy link

Describe the feature request

I'm using the unleash docker image.
Is there a way to set the default username and password for the Unleash UI admin user? I know I can log in and create a new admin user, or use an api call to do so. Those options are not ideal for us though.
I really like the unleash env variables INIT_CLIENT_API_TOKENS and the other ones like it. It would be great if there was a similar way to initialize the admin username and password.

Background

One of our products, that uses Unleash, is deployed to our customer by means of basically a docker compose file. If the customer buys the product they get an installer that spins up the docker compose file on their own server. On the customer's server. I want to be able to put a custom Unleash UI username and password in that docker-compose file.

Solution suggestions

Env variables seem like a good way to do it to me. It's basically the same thing that is done with default tokens.

@ivarconr
Copy link
Member

This sounds reasonable to me. I assume this should only take effect when the admin user is actually created, and not override the password, if already set?

@dramamask
Copy link
Author

Correct @ivarconr. That's how I imagine it to work. Just like it works with the tokens.

@nunogois nunogois moved this from New to Todo in Issues and PRs Sep 4, 2023
@ivarconr ivarconr added the feature request A wish for Unleash to do something it doesn't already do. label Oct 2, 2023
@jonasws
Copy link
Contributor

jonasws commented Oct 4, 2023

@ivarconr Is this something you've gotten around to? If not, I'll be happy to pick this up!
UPDATE: This ended up being such a simple change that I took the liberty to open a PR. Feel free to close as a duplicate if you already have something in the works for this one!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement feature request A wish for Unleash to do something it doesn't already do. good first issue
Projects
Archived in project
Development

Successfully merging a pull request may close this issue.

4 participants