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

Switch dashboard's createDockerRegistrySecret to use resources API. #3916

Merged
merged 1 commit into from
Jan 4, 2022

Conversation

absoludity
Copy link
Contributor

@absoludity absoludity commented Dec 8, 2021

Signed-off-by: Michael Nelson minelson@vmware.com

Description of the change

Switches the Secret.createDockerRegistrySecret helper from using the k8s API directly to using the resources plugin.

Tested IRL to ensure both the dashboard change and the backend grpc function work together as expected (which they do).

Benefits

  • No longer receive the secret data over the network when creating a secret,
  • One less call-site using the k8s API

Possible drawbacks

Applicable issues

Additional information

Next up is switching the dashboard's Secret.list to use the plugin's GetSecretNames which will be trickier, as it also involves updating the dashboard to no longer require the secret data for the UX interaction.

@absoludity absoludity marked this pull request as ready for review December 8, 2021 06:51
@absoludity absoludity force-pushed the 3896-secrets-backend-2 branch from be5935e to f201bff Compare December 10, 2021 02:01
@absoludity absoludity force-pushed the 3896-secrets-dashboard-1 branch from 29ec032 to 7182417 Compare December 10, 2021 02:05
@absoludity absoludity force-pushed the 3896-secrets-backend-2 branch from f201bff to 7ebab5f Compare December 13, 2021 18:58
@absoludity absoludity force-pushed the 3896-secrets-dashboard-1 branch from 7182417 to 3ef2bee Compare December 13, 2021 19:00
@absoludity absoludity force-pushed the 3896-secrets-backend-2 branch from 7ebab5f to 275bf2d Compare December 13, 2021 20:00
@absoludity absoludity force-pushed the 3896-secrets-dashboard-1 branch from 3ef2bee to 64ff9c3 Compare December 13, 2021 20:02
Copy link
Contributor

@antgamdia antgamdia left a comment

Choose a reason for hiding this comment

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

Great, thanks!

namespace,
);
dispatch(createImagePullSecret(secret));
await Secret.createPullSecret(currentCluster, name, user, password, email, server, namespace);
Copy link
Contributor

Choose a reason for hiding this comment

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

Not sure if we can/want use the Context here instead of passing the cluster/ns directly

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Yep, we probably can now, but will need to update the form props and call-sites etc.

@stale
Copy link

stale bot commented Dec 28, 2021

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

@stale stale bot added the stale Automatic label to stale issues due inactivity to be closed if no further action label Dec 28, 2021
@stale stale bot closed this Jan 1, 2022
@antgamdia
Copy link
Contributor

We probably want to keep this PR open.

@antgamdia antgamdia reopened this Jan 3, 2022
@stale stale bot removed stale Automatic label to stale issues due inactivity to be closed if no further action labels Jan 3, 2022
@absoludity absoludity force-pushed the 3896-secrets-backend-2 branch from 275bf2d to 6866aea Compare January 4, 2022 04:45
Base automatically changed from 3896-secrets-backend-2 to master January 4, 2022 05:10
Signed-off-by: Michael Nelson <minelson@vmware.com>
@absoludity absoludity force-pushed the 3896-secrets-dashboard-1 branch from 64ff9c3 to fe69999 Compare January 4, 2022 05:11
@absoludity absoludity merged commit 4f4b7c7 into master Jan 4, 2022
@absoludity absoludity deleted the 3896-secrets-dashboard-1 branch January 4, 2022 06:31
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.

3 participants