accessentry

package
v0.199.0 Latest Latest
Warning

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

Go to latest
Published: Dec 13, 2024 License: Apache-2.0 Imports: 24 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func MakeStackName

func MakeStackName(clusterName string, accessEntry api.AccessEntry) string

MakeStackName creates a stack name for the specified access entry.

Types

type Creator

type Creator struct {
	ClusterName  string
	StackCreator StackCreator
}

A Creator creates access entries.

func (*Creator) Create

func (m *Creator) Create(ctx context.Context, accessEntries []api.AccessEntry) error

Create creates the specified access entries.

func (*Creator) CreateTasks

func (m *Creator) CreateTasks(ctx context.Context, accessEntries []api.AccessEntry) *tasks.TaskTree

CreateTasks creates a TaskTree for creating access entries.

type CreatorInterface

type CreatorInterface interface {
	// Create creates access entries.
	Create(ctx context.Context, accessEntries []api.AccessEntry) error
	// CreateTasks creates a TaskTree for creating access entries.
	CreateTasks(ctx context.Context, accessEntries []api.AccessEntry) *tasks.TaskTree
}

CreatorInterface creates access entries.

type Getter

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

func NewGetter

func NewGetter(clusterName string, eksAPI awsapi.EKS) *Getter

func (*Getter) Get

func (aeg *Getter) Get(ctx context.Context, principalARN api.ARN) ([]Summary, error)

type GetterInterface added in v0.177.0

type GetterInterface interface {
	Get(ctx context.Context, principalARN api.ARN) ([]Summary, error)
}

type MigrationOptions added in v0.177.0

type MigrationOptions struct {
	TargetAuthMode string
	Approve        bool
	Timeout        time.Duration
}

type Migrator added in v0.177.0

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

func NewMigrator added in v0.177.0

func NewMigrator(
	clusterName string,
	eksAPI awsapi.EKS,
	iamAPI awsapi.IAM,
	clientSet kubernetes.Interface,
	aeCreator CreatorInterface,
	aeGetter GetterInterface,
	curAuthMode ekstypes.AuthenticationMode,
	tgAuthMode ekstypes.AuthenticationMode,
) *Migrator

func (*Migrator) MigrateToAccessEntry added in v0.177.0

func (m *Migrator) MigrateToAccessEntry(ctx context.Context, options MigrationOptions) error

type Remover

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

func NewRemover

func NewRemover(clusterName string, stackRemover StackRemover, eksAPI awsapi.EKS) *Remover

func (*Remover) Delete

func (aer *Remover) Delete(ctx context.Context, accessEntries []api.AccessEntry) error

func (Remover) DeleteTasks

func (aer Remover) DeleteTasks(ctx context.Context, accessEntries []api.AccessEntry) (*tasks.TaskTree, error)

type StackCreator

type StackCreator interface {
	CreateStack(ctx context.Context, stackName string, resourceSet builder.ResourceSetReader, tags, parameters map[string]string, errs chan error) error
	TroubleshootStackFailureCause(ctx context.Context, stack *cfntypes.Stack, desiredStatus cfntypes.StackStatus)
}

type StackRemover

type StackRemover interface {
	DescribeStack(ctx context.Context, s *cfntypes.Stack) (*cfntypes.Stack, error)
	DeleteStackBySpecSync(ctx context.Context, s *cfntypes.Stack, errs chan error) error
	ListAccessEntryStackNames(ctx context.Context, clusterName string) ([]string, error)
}

type Summary

type Summary struct {
	PrincipalARN     string             `json:"principalARN"`
	KubernetesGroups []string           `json:"kubernetesGroups,omitempty"`
	AccessPolicies   []api.AccessPolicy `json:"accessPolicies,omitempty"`
}

Directories

Path Synopsis
Code generated by counterfeiter.
Code generated by counterfeiter.

Jump to

Keyboard shortcuts

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