common

package
v1.52.0 Latest Latest
Warning

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

Go to latest
Published: Apr 25, 2024 License: Apache-2.0 Imports: 20 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var CopyImageROSTemplate string

CopyImageROSTemplate contains the content of CopyImage ROS template. https://www.alibabacloud.com/help/doc-detail/116189.htm?spm=a2c63.l28256.b99.201.713413a3FkLSIx

Functions

func GetEncryptImageStackName added in v1.25.0

func GetEncryptImageStackName(imageName, imageVersion, regionID string) string

GetEncryptImageStackName returns the encrypt image stack name for the given image name and version.

func IsStateEmpty added in v1.9.0

func IsStateEmpty(ctx context.Context, tf terraformer.Terraformer) (bool, error)

IsStateEmpty checks the Terraformer state: 1. is empty or not; 2. contains resources or not

func NewTerraformer

func NewTerraformer(
	logger logr.Logger,
	factory terraformer.Factory,
	config *rest.Config,
	purpose string,
	infra *extensionsv1alpha1.Infrastructure,
	disableProjectedTokenMount bool,
) (
	terraformer.Terraformer,
	error,
)

NewTerraformer creates a new Terraformer.

func NewTerraformerWithAuth added in v1.7.0

func NewTerraformerWithAuth(
	logger logr.Logger,
	factory terraformer.Factory,
	config *rest.Config,
	purpose string,
	infra *extensionsv1alpha1.Infrastructure,
	disableProjectedTokenMount bool,
) (
	terraformer.Terraformer,
	error,
)

NewTerraformerWithAuth creates a new Terraformer and initializes it with the credentials.

func TerraformerEnvVars added in v1.20.0

func TerraformerEnvVars(secretRef corev1.SecretReference) []corev1.EnvVar

TerraformerEnvVars computes the Terraformer environment variables from the given secret ref.

func UseEncryptedSystemDisk added in v1.25.0

func UseEncryptedSystemDisk(volume interface{}) (bool, error)

UseEncryptedSystemDisk checks whether the given volume needs encryption If volume is unexpected, it will returns error to avoid unexpected result

Types

type ImageEncrypter added in v1.25.0

type ImageEncrypter interface {
	TryToGetEncryptedImageID(ctx context.Context, timeout time.Duration, interval time.Duration) (string, error)
}

ImageEncrypter declares interfaces to operate an encrypted image

func NewImageEncryptor added in v1.25.0

func NewImageEncryptor(client alicloudclient.ROS, regionID, imageName, imageVersion, sourceImageID string) ImageEncrypter

NewImageEncryptor creates an ImageEncrypter instance

Jump to

Keyboard shortcuts

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