-
Notifications
You must be signed in to change notification settings - Fork 11
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
Add workloadapi options for cmd-registry-memory #56
base: main
Are you sure you want to change the base?
Add workloadapi options for cmd-registry-memory #56
Conversation
Signed-off-by: denis-tingajkin <denis.tingajkin@xored.com>
Signed-off-by: denis-tingajkin <denis.tingajkin@xored.com>
source, err := workloadapi.NewX509Source(ctx) | ||
source, err := workloadapi.NewX509Source(ctx, | ||
workloadapi.WithClientOptions(workloadapi.WithLogger(log.Entry(ctx))), | ||
workloadapi.WithDefaultX509SVIDPicker(func(svids []*x509svid.SVID) *x509svid.SVID { |
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.
So I'm not clear why we are using the SVID Picker here...
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.
Actually the deployment can fetch few svids. By default workloadapi.NewX509Source
just picks first.
So I think we should pick svid for registry if for that has been added spire entry.
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.
Hmm... I'm inclined to not worry about it right now... in practice at least in K8s, I believe its only returning one SVID, and this forces an SVID schema on users they may not want.
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.
in practice at least in K8s, I believe its only returning one SVID
I guess it is related to user spire setup...
This PR syncs files with https://github.com/networkservicemesh/cmd-template Revision: https://github.com/networkservicemesh/cmd-template/commits/5e735856d8be1fb56c377c31bb57f8094d8f38f6 commit 5e735856d8be1fb56c377c31bb57f8094d8f38f6 Author: Denis Tingaikin <49399980+denis-tingajkin@users.noreply.github.com> Date: Tue Dec 29 13:49:50 2020 +0700 update golangci linter (#56) Signed-off-by: denis-tingajkin <denis.tingajkin@xored.com> Signed-off-by: NSMBot <nsmbot@networkservicmesh.io>
Signed-off-by: denis-tingajkin denis.tingajkin@xored.com
Motivation
Added svid picker
Added spire logging