Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func WithBearerToken ¶
func WithBearerToken(token string) grpc.CallOption
WithBearerToken returns a grpc.CallOption that adds a standard HTTP Bearer token to all requests sent from a client.
func WithInsecureBearerToken ¶
func WithInsecureBearerToken(token string) grpc.CallOption
WithInsecureBearerToken returns a grpc.CallOption that adds a standard HTTP Bearer token to all requests sent from an insecure client.
Must be used in conjunction with `insecure.NewCredentials()`.
Types ¶
type ClientOptions ¶
type ClientOptions func(*Config)
func WithAuthEnabled ¶
func WithAuthEnabled(clientId string, clientSecret string, authServerTokenUrl string) ClientOptions
func WithHTTPTLSConfig ¶
func WithHTTPTLSConfig(tlsConfig *tls.Config) ClientOptions
func WithHTTPUrl ¶
func WithHTTPUrl(url string) ClientOptions
func WithTLSInsecure ¶
func WithTLSInsecure(insecure bool) ClientOptions
func WithgRPCUrl ¶
func WithgRPCUrl(url string) ClientOptions
type InventoryClient ¶
type InventoryClient struct { K8sClusterService kessel.KesselK8SClusterServiceClient K8SPolicyIsPropagatedToK8SClusterServiceClient kesselrel.KesselK8SPolicyIsPropagatedToK8SClusterServiceClient PolicyServiceClient kessel.KesselK8SPolicyServiceClient RhelHostServiceClient kessel.KesselRhelHostServiceClient // contains filtered or unexported fields }
func New ¶
func New(config *Config) (*InventoryClient, error)
func (InventoryClient) GetTokenCallOption ¶
func (a InventoryClient) GetTokenCallOption() ([]grpc.CallOption, error)
type InventoryHttpClient ¶
type InventoryHttpClient struct { K8sClusterService kessel.KesselK8SClusterServiceHTTPClient K8SPolicyIsPropagatedToK8SClusterServiceHTTPClient kesselrel.KesselK8SPolicyIsPropagatedToK8SClusterServiceHTTPClient PolicyServiceClient kessel.KesselK8SPolicyServiceHTTPClient RhelHostServiceClient kessel.KesselRhelHostServiceHTTPClient // contains filtered or unexported fields }
func NewHttpClient ¶
func NewHttpClient(ctx context.Context, config *Config) (*InventoryHttpClient, error)
func (InventoryHttpClient) GetTokenHTTPOption ¶
func (a InventoryHttpClient) GetTokenHTTPOption() ([]http.CallOption, error)
type TokenClient ¶
type TokenClient struct { EnableOIDCAuth bool Insecure bool // contains filtered or unexported fields }
func NewTokenClient ¶
func NewTokenClient(config *Config) *TokenClient
NewTokenClient creates and returns a new TokenClient client.
func (*TokenClient) GetCachedToken ¶
func (a *TokenClient) GetCachedToken(tokenKey string) (string, error)
func (*TokenClient) GetToken ¶
func (a *TokenClient) GetToken() (*TokenResponse, error)
type TokenResponse ¶
Click to show internal directories.
Click to hide internal directories.