creator

package
v2.17.0 Latest Latest
Warning

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

Go to latest
Published: Jun 9, 2021 License: Apache-2.0 Imports: 15 Imported by: 0

Documentation

Overview

Package creator offers a service to fetch a list of credentials.

Index

Constants

View Source
const (
	AppLabel          = "app"
	AppValue          = "credentiald"
	ManagedByLabel    = "giantswarm.io/managed-by"
	ManagedByValue    = "credentiald"
	OrganizationLabel = "giantswarm.io/organization"
	ServiceTypeLabel  = "giantswarm.io/service-type"
	ServiceTypeValue  = "system"

	ResourceCreatedMessageFormat = "A new set of credentials has been created with ID '%s'"
)

Variables

This section is empty.

Functions

func IsAlreadyExists

func IsAlreadyExists(err error) bool

IsAlreadyExists asserts alreadyExistsError.

func IsInvalidConfig

func IsInvalidConfig(err error) bool

IsInvalidConfig asserts invalidConfigError.

func IsInvalidProvider

func IsInvalidProvider(err error) bool

IsInvalidProvider asserts invalidProviderError.

Types

type Config

type Config struct {
	K8sClient kubernetes.Interface
	Logger    micrologger.Logger

	IDLength         int
	NameFormat       string
	SecretsNamespace string
}

type Request

type Request struct {
	Organization string
	Provider     string

	AWS   aws.Request
	Azure azure.Request
}

type Response

type Response struct {
	Code    string
	Message string

	CredentialID string
	Organization string
}

type Service

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

func New

func New(config Config) (*Service, error)

func (*Service) Create

func (s *Service) Create(ctx context.Context, request Request) (Response, error)

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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