Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func CreateACRDockerCfg ¶
func CreateACRDockerCfg(acrFQDN string, accessToken types.AccessToken) string
CreateACRDockerCfg creates an ACR docker config using given access token.
Types ¶
type ACRTokenExchanger ¶
type ACRTokenExchanger interface {
ExchangeACRAccessToken(armToken types.AccessToken, acrFQDN string) (types.AccessToken, error)
}
ACRTokenExchanger is the interface to exchange an ACR access token.
type Authorizer ¶
type Authorizer struct {
// contains filtered or unexported fields
}
Authorizer is an instance of authorizer
func (*Authorizer) AcquireACRAccessTokenWithClientID ¶
func (az *Authorizer) AcquireACRAccessTokenWithClientID(clientID string, acrFQDN string) (types.AccessToken, error)
AcquireACRAccessTokenWithClientID acquires ACR access token using managed identity client ID.
func (*Authorizer) AcquireACRAccessTokenWithResourceID ¶
func (az *Authorizer) AcquireACRAccessTokenWithResourceID(identityResourceID string, acrFQDN string) (types.AccessToken, error)
AcquireACRAccessTokenWithResourceID acquires ACR access token using managed identity resource ID (/subscriptions/{id}/resourceGroups/{group}/providers/Microsoft.ManagedIdentity/userAssignedIdentities/{name}).
type Interface ¶
type Interface interface { AcquireACRAccessTokenWithResourceID(identityResourceID string, acrFQDN string) (types.AccessToken, error) AcquireACRAccessTokenWithClientID(clientID string, acrFQDN string) (types.AccessToken, error) }
Interface is the authorizer interface to acquire ACR access tokens.
type ManagedIdentityTokenRetriever ¶
type ManagedIdentityTokenRetriever interface {
AcquireARMToken(clientID string, resourceID string) (types.AccessToken, error)
}
ManagedIdentityTokenRetriever is the interface to acquire an ARM access token.
type TokenExchanger ¶
type TokenExchanger struct {
// contains filtered or unexported fields
}
TokenExchanger is an instance of ACRTokenExchanger
func NewTokenExchanger ¶
func NewTokenExchanger() *TokenExchanger
NewTokenExchanger returns a new token exchanger
func (*TokenExchanger) ExchangeACRAccessToken ¶
func (te *TokenExchanger) ExchangeACRAccessToken(armToken types.AccessToken, acrFQDN string) (types.AccessToken, error)
ExchangeACRAccessToken exchanges an ARM access token to an ACR access token
type TokenRetriever ¶
type TokenRetriever struct {
// contains filtered or unexported fields
}
TokenRetriever is an instance of ManagedIdentityTokenRetriever
func NewTokenRetriever ¶
func NewTokenRetriever() *TokenRetriever
NewTokenRetriever returns a new token retriever
func (*TokenRetriever) AcquireARMToken ¶
func (tr *TokenRetriever) AcquireARMToken(clientID string, resourceID string) (types.AccessToken, error)
AcquireARMToken acquires the managed identity ARM access token
Source Files ¶
Directories ¶
Path | Synopsis |
---|---|
Package mock_authorizer is a generated GoMock package.
|
Package mock_authorizer is a generated GoMock package. |