auth

package
v0.29.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Aug 7, 2023 License: MPL-2.0 Imports: 12 Imported by: 1

Documentation

Overview

Package auth package

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type OIDCTokenGetter added in v0.26.0

type OIDCTokenGetter func() (string, error)

OIDCTokenGetter is a callback for returning the OIDC token that is used to login to the service account

type TokenProvider

type TokenProvider interface {
	GetToken() (string, error)
}

TokenProvider is an interface with a GetToken method.

func NewServiceAccountTokenProvider

func NewServiceAccountTokenProvider(endpointURL string, accountPath string, oidcTokenGetter OIDCTokenGetter) (TokenProvider, error)

NewServiceAccountTokenProvider returns a new instance of this provider.

Constructor arguments for options service account path and token values take priority over the environment variables. For now,

func NewStaticTokenProvider

func NewStaticTokenProvider(token string) (TokenProvider, error)

NewStaticTokenProvider returns a new instance of this provider.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL