Documentation ¶
Index ¶
- Constants
- func GetJWTTokenClaim(jwtToken string) (*utils.MarketplaceClaims, error)
- func WithBearerAuth(rt http.RoundTripper, token string) http.RoundTripper
- func WithHeader(rt http.RoundTripper) withHeader
- type Auth
- type EntitlementKey
- type MarketplaceClient
- func (mhttp *MarketplaceClient) GetMarketplaceSecret() (*corev1.Secret, error)
- func (mhttp *MarketplaceClient) MigrateChildRRS3(account *MarketplaceClientAccount) error
- func (m *MarketplaceClient) RegistrationStatus(account *MarketplaceClientAccount) (RegistrationStatusOutput, error)
- func (m *MarketplaceClient) RhmAccountExists() (bool, error)
- func (m *MarketplaceClient) UnRegister(account *MarketplaceClientAccount) (RegistrationStatusOutput, error)
- type MarketplaceClientAccount
- type MarketplaceClientBuilder
- type MarketplaceClientConfig
- type RegisteredAccount
- type RegistrationStatusInput
- type RegistrationStatusOutput
Constants ¶
View Source
const ( PullSecretEndpoint = "provisioning/v1/rhm-operator/rhm-operator-secret" RegistrationEndpoint = "provisioning/v1/registered-clusters" MigrateChildRRS3Endpoint = "provisioning/v1/child-yaml-migration" AuthenticationEndpoint = "subscriptions/api/v1/keys/authentication" )
endpoints
View Source
const EnvStage = "stage"
View Source
const (
RegistrationStatusInstalled = "INSTALLED"
)
Variables ¶
This section is empty.
Functions ¶
func GetJWTTokenClaim ¶
func GetJWTTokenClaim(jwtToken string) (*utils.MarketplaceClaims, error)
GetJWTTokenClaims will parse JWT token and fetch the rhmAccountId
func WithBearerAuth ¶
func WithBearerAuth(rt http.RoundTripper, token string) http.RoundTripper
func WithHeader ¶
func WithHeader(rt http.RoundTripper) withHeader
Types ¶
type EntitlementKey ¶
type MarketplaceClient ¶
type MarketplaceClient struct {
// contains filtered or unexported fields
}
func (*MarketplaceClient) GetMarketplaceSecret ¶
func (mhttp *MarketplaceClient) GetMarketplaceSecret() (*corev1.Secret, error)
func (*MarketplaceClient) MigrateChildRRS3 ¶
func (mhttp *MarketplaceClient) MigrateChildRRS3(account *MarketplaceClientAccount) error
func (*MarketplaceClient) RegistrationStatus ¶
func (m *MarketplaceClient) RegistrationStatus(account *MarketplaceClientAccount) (RegistrationStatusOutput, error)
func (*MarketplaceClient) RhmAccountExists ¶
func (m *MarketplaceClient) RhmAccountExists() (bool, error)
func (*MarketplaceClient) UnRegister ¶
func (m *MarketplaceClient) UnRegister(account *MarketplaceClientAccount) (RegistrationStatusOutput, error)
type MarketplaceClientBuilder ¶
func NewMarketplaceClientBuilder ¶
func NewMarketplaceClientBuilder(cfg *config.OperatorConfig) *MarketplaceClientBuilder
func (*MarketplaceClientBuilder) NewMarketplaceClient ¶
func (b *MarketplaceClientBuilder) NewMarketplaceClient( token string, tokenClaims *utils.MarketplaceClaims, ) (*MarketplaceClient, error)
type MarketplaceClientConfig ¶
type MarketplaceClientConfig struct { Url string Token string Insecure bool Claims *utils.MarketplaceClaims }
type RegisteredAccount ¶
type RegistrationStatusInput ¶
type RegistrationStatusInput struct {
MarketplaceClientAccount
}
type RegistrationStatusOutput ¶
type RegistrationStatusOutput struct { StatusCode int Registration *RegisteredAccount RegistrationStatus string Err error }
func (RegistrationStatusOutput) TransformConfigStatus ¶
func (resp RegistrationStatusOutput) TransformConfigStatus() status.Conditions
Click to show internal directories.
Click to hide internal directories.