shared

package
v0.8.0 Latest Latest
Warning

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

Go to latest
Published: Apr 23, 2024 License: Apache-2.0 Imports: 42 Imported by: 1

Documentation

Index

Constants

View Source
const (
	SignAlgo = rsa.Algorithm
)

Variables

View Source
var (

	// TestUserToken is the token generated for API access on the created test user.
	TestUserToken = "91efc1d52e9d6069729f373c2cad057da974f11e" //nolint:gosec // this is a test key
	BaseURL       = "http://127.0.0.1:3000"
	Owner         = "e2e-tester"
)

internal values.

Functions

func AddComponentVersionToRepository

func AddComponentVersionToRepository(component Component, scheme string, componentModifications ...ComponentModification) error

AddComponentVersionToRepository takes a component description and optional resources. Then pushes that component into the locally forwarded registry.

func CreateSecret added in v0.3.2

func CreateSecret(name string, data map[string][]byte, stringData map[string]string, namespace string) features.Func

Creates a secret

func DeleteSecret added in v0.3.2

func DeleteSecret(name string) features.Func

DeleteSecret Deletes a secret

func ForwardPortForAppName

func ForwardPortForAppName(name string, port int, stopChannel chan struct{}) env.Func

ForwardPortForAppName port forwards at test setup phase

func InstallFlux

func InstallFlux(version string) env.Func

InstallFlux creates a flux installation with a given version.

func PortForward added in v0.3.2

func PortForward(port int, stopChannel chan struct{}, podName string, ctx context.Context, config *envconf.Config) (context.Context, error)

PortForward forwards the given port for the given pod name.

func RemoveGitServer

func RemoveGitServer(namespace string) env.Func

RemoveGitServer removes the previously installed Gitea server.

func RunTiltForControllers

func RunTiltForControllers(controllers ...string) env.Func

RunTiltForControllers executes tilt for a list of controllers.

func ShutdownPortForward

func ShutdownPortForward(stopChannel chan struct{}) env.Func

ShutdownPortForward sends a signal to the stop channel.

func StartGitServer

func StartGitServer(namespace string) env.Func

StartGitServer installs a Gitea Git server into the cluster using the deployment configuration files provided under ./gitea folder.

Types

type Component

type Component struct {
	Name    string
	Version string
	Sign    *Sign
}

Component presents a simple layout for a component. If `Sign` is not empty, it's used to sign the component. It should be the byte representation of a private key.

type ComponentModification added in v0.3.0

type ComponentModification func(compvers ocm.ComponentVersionAccess) error

ComponentModification defines functions that can modify the generated component version.

func BlobResource added in v0.3.0

func BlobResource(resource Resource) ComponentModification

BlobResource creates a blob type resource for local access.

func ComponentVersionRef added in v0.3.0

func ComponentVersionRef(ref ComponentRef) ComponentModification

ComponentVersionRef creates a component version reference for the given component version.

func ImageRefResource added in v0.3.0

func ImageRefResource(ref string, resource Resource) ComponentModification

ImageRefResource creates an image reference type resource.

type ComponentRef added in v0.2.0

type ComponentRef struct {
	Name          string
	Version       string
	ComponentName string
}

type CreateOptions added in v0.2.0

type CreateOptions struct {
	Resource     *Resource
	ComponentRef *ComponentRef
}

CreateOptions presents a simple layout for a resource that AddComponentVersionToRepository will use.

type Resource

type Resource struct {
	Name    string
	Version string
	Data    string
	Type    string
}

type Sign

type Sign struct {
	Name string
	Key  []byte
}

Sign defines the two needed values to perform a component signing.

Directories

Path Synopsis
steps

Jump to

Keyboard shortcuts

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