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

Avoid double admin password request on instances add #4235

Merged
merged 2 commits into from
Nov 25, 2023

Conversation

sblaisot
Copy link
Contributor

@sblaisot sblaisot commented Nov 23, 2023

When adding a new instance and cozy-stack admin password has not been set in the environment variable, then it asks twice for admin password, one time to effectively create the instance and then another time to check if all required applications have been installed.

This pull request get rid of code duplication between adminClient.NewInstanceClient() and newClientSafe() and create a new client from adminClient on instance creation to avoid asking for the admin password more than once.

@sblaisot sblaisot requested a review from a team as a code owner November 23, 2023 08:01
@sblaisot sblaisot merged commit 57f07fb into master Nov 25, 2023
6 checks passed
@sblaisot sblaisot deleted the inst_add_double_pass branch November 25, 2023 12:26
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants