mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-09-03 02:07:38 +00:00
allow multiple of --service-account-issuer
This commit is contained in:
@@ -69,7 +69,7 @@ func TestDynamicClientBuilder(t *testing.T) {
|
||||
if opts.Authentication.ServiceAccounts == nil {
|
||||
opts.Authentication.ServiceAccounts = &kubeoptions.ServiceAccountAuthenticationOptions{}
|
||||
}
|
||||
opts.Authentication.ServiceAccounts.Issuer = iss
|
||||
opts.Authentication.ServiceAccounts.Issuers = []string{iss}
|
||||
opts.Authentication.ServiceAccounts.KeyFiles = []string{tmpfile.Name()}
|
||||
},
|
||||
ModifyServerConfig: func(config *controlplane.Config) {
|
||||
|
@@ -54,6 +54,7 @@ import (
|
||||
"k8s.io/kubernetes/test/integration/framework"
|
||||
)
|
||||
|
||||
// This key is for testing purposes only and is not considered secure.
|
||||
const ecdsaPrivateKey = `-----BEGIN EC PRIVATE KEY-----
|
||||
MHcCAQEEIEZmTmUhuanLjPA2CLquXivuwBDHTt5XYwgIr/kA1LtRoAoGCCqGSM49
|
||||
AwEHoUQDQgAEH6cuzP8XuD5wal6wf9M6xDljTOPLX2i8uIp/C/ASqiIGUeeKQtX0
|
||||
@@ -87,7 +88,7 @@ func TestServiceAccountTokenCreate(t *testing.T) {
|
||||
masterConfig.GenericConfig.Authentication.APIAudiences = aud
|
||||
masterConfig.GenericConfig.Authentication.Authenticator = bearertoken.New(
|
||||
serviceaccount.JWTTokenAuthenticator(
|
||||
iss,
|
||||
[]string{iss},
|
||||
[]interface{}{&pk},
|
||||
aud,
|
||||
serviceaccount.NewValidator(serviceaccountgetter.NewGetterFromClient(
|
||||
|
Reference in New Issue
Block a user