-
Notifications
You must be signed in to change notification settings - Fork 9
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
generate: check for existing public key in manifest #650
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm not sure about this. If I generate twice like this:
contrast generate --seedshare-owner-key=alice.pem deploy.yml
contrast generate --seedshare-owner-key=bob.pem deploy.yml
Would I really expect both alice and bob to be in the manifest? I think it might be less surprising if we cleared out the keys and then added what's given as flag.
We should match the behavior of workload owner keys (or update it, too). |
This is the current behavior for workload owner keys, as far as I can see. |
We could rename the flag to something like |
I say that's a good solution, wdyt @burgerdev ? |
Calling the flags |
0d5512d
to
29251ec
Compare
This makes it more obvious to the user that this flag only *adds* keys, but never removes existing keys.
29251ec
to
6c5cb38
Compare
I also applied the change suggested in #670 (comment) to the |
If you call
generate
twice with the same seed share owner public key, the public key would just have been appended to the list instead of checking if the public key is already present in the manifest. Now, callinggenerate
twice will result in the same manifest.