dynamiccreds

package
v0.4.2 Latest Latest
Warning

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

Go to latest
Published: Sep 23, 2025 License: MPL-2.0 Imports: 26 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GenerateToken

func GenerateToken(
	privateKey jwk.Key,
	issuer string,
	organization organization.Name,
	workspaceID resource.TfeID,
	workspaceName string,
	runID resource.TfeID,
	jobID resource.TfeID,
	phase run.PhaseType,
	audience string,
) ([]byte, error)

func Setup

func Setup(
	ctx context.Context,
	tokenGenerator TokenGenerator,
	workdir string,
	jobID resource.TfeID,
	phase run.PhaseType,
	environmentVariables []string,
) ([]string, error)

Setup cloud providers for dynamic credentials for a job.

Types

type Handlers

type Handlers struct {
	// contains filtered or unexported fields
}

type Options

type Options struct {
	Logger          logr.Logger
	HostnameService *internal.HostnameService
	PublicKeyPath   string
	PrivateKeyPath  string
}

type Service

type Service struct {
	// contains filtered or unexported fields
}

func NewService

func NewService(opts Options) (*Service, error)

func (*Service) AddHandlers

func (s *Service) AddHandlers(r *mux.Router)

func (*Service) PrivateKey

func (s *Service) PrivateKey() jwk.Key

type TokenGenerator

type TokenGenerator interface {
	GenerateDynamicCredentialsToken(ctx context.Context, jobID resource.TfeID, audience string) ([]byte, error)
}

Jump to

Keyboard shortcuts

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