Documentation ¶
Index ¶
- func NewLoginTokenSource(cacheFile string, forceLogin bool, oauthTokenSource oauth2.TokenSource, ...) oauth2.TokenSource
- func NewServicePrincipalTokenSource(cacheFile string, clientID string, oauthTokenSource oauth2.TokenSource) oauth2.TokenSource
- func NewWorkloadTokenSource(cacheFile string, providerResourceName string, ...) oauth2.TokenSource
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func NewLoginTokenSource ¶
func NewLoginTokenSource( cacheFile string, forceLogin bool, oauthTokenSource oauth2.TokenSource, oauthConfig oAuth2Config, ) oauth2.TokenSource
NewLoginTokenSource will create a token source that caches login tokens. Only one login token will be cached at a time.
The tokens will be cached under `login` in the cache file.
If forceLogin is set the existing cached token will be invalidated and a new token will be retrieved from the token source.
func NewServicePrincipalTokenSource ¶
func NewServicePrincipalTokenSource( cacheFile string, clientID string, oauthTokenSource oauth2.TokenSource, ) oauth2.TokenSource
NewServicePrincipalTokenSource will create a token source that caches service principal tokens. The tokens will be cached under `service-principals` in the cache file.
func NewWorkloadTokenSource ¶
func NewWorkloadTokenSource( cacheFile string, providerResourceName string, oauthTokenSource oauth2.TokenSource, ) oauth2.TokenSource
NewWorkloadTokenSource will create a token source that caches workload identity provider tokens. The tokens will be cached under `workloads` in the cache file.
Types ¶
This section is empty.