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

If User Does not set admin username then create a username with random string #67

Open
kgcarr opened this issue Mar 20, 2020 · 2 comments
Labels
enhancement New feature or request

Comments

@kgcarr
Copy link
Member

kgcarr commented Mar 20, 2020

for security, we should not have a default admin user named admin

@kgcarr kgcarr mentioned this issue Mar 20, 2020
@chenzhiwei
Copy link
Contributor

just get a chance to review the code, I think the operator should expose the secret name that contains the username and password.

The approach should be something like:

spec:
  mongoCredentialRef: mongo-user

In the controller logic:

  1. The default value of mongoCredentialRef should be mongo-user.
  2. If user want to customize the user/pass, they can create a secret before installing
    kubectl create secret generic mongo-user --from-literal username=user --from-literal password=pass
    
  3. If this secret does not exist, then the controller should create one with random values

@kgcarr
Copy link
Member Author

kgcarr commented Mar 24, 2020

I think this is a good recommendation. It will have to be Q2 at this point though

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants