fixture

package
v1.1.0-rc.2.p1 Latest Latest
Warning

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

Go to latest
Published: Apr 16, 2020 License: Apache-2.0 Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	BestEffort    = corev1.ResourceRequirements{}
	BurstbleSmall = corev1.ResourceRequirements{
		Requests: corev1.ResourceList{
			corev1.ResourceCPU:    resource.MustParse("100m"),
			corev1.ResourceMemory: resource.MustParse("100Mi"),
		},
		Limits: corev1.ResourceList{
			corev1.ResourceCPU:    resource.MustParse("1000m"),
			corev1.ResourceMemory: resource.MustParse("2Gi"),
		},
	}
	BurstbleMedium = corev1.ResourceRequirements{
		Requests: corev1.ResourceList{
			corev1.ResourceCPU:    resource.MustParse("100m"),
			corev1.ResourceMemory: resource.MustParse("100Mi"),
		},
		Limits: corev1.ResourceList{
			corev1.ResourceCPU:    resource.MustParse("2000m"),
			corev1.ResourceMemory: resource.MustParse("4Gi"),
		},
	}
	// hard-coded region and s3 bucket in our aws account for e2e testing
	// TODO create s3 bucket in current region dynamically
	AWSRegion = "us-west-2"
	Bucket    = "backup.e2e.us-west-2.tidbcloud.com"
	S3Secret  = "s3-secret"
)

Functions

func GetBackupCRDWithBR

func GetBackupCRDWithBR(tc *v1alpha1.TidbCluster, backupFolder string) *v1alpha1.Backup

func GetBackupRole

func GetBackupRole(tc *v1alpha1.TidbCluster, serviceAccountName string) *rbacv1beta1.Role

func GetBackupRoleBing

func GetBackupRoleBing(tc *v1alpha1.TidbCluster, serviceAccountName string) *rbacv1beta1.RoleBinding

func GetBackupSecret

func GetBackupSecret(tc *v1alpha1.TidbCluster, password string) *corev1.Secret

func GetBackupServiceAccount

func GetBackupServiceAccount(tc *v1alpha1.TidbCluster, serviceAccountName string) *corev1.ServiceAccount

func GetRestoreCRDWithBR

func GetRestoreCRDWithBR(tc *v1alpha1.TidbCluster, backupFolder string) *v1alpha1.Restore

func GetS3Secret

func GetS3Secret(tc *v1alpha1.TidbCluster, accessKey, secretKey string) *corev1.Secret

func GetTidbCluster

func GetTidbCluster(ns, name, version string) *v1alpha1.TidbCluster

GetTidbCluster returns a TidbCluster resource configured for testing

func GetTidbClusterAutoScaler

func GetTidbClusterAutoScaler(name, ns string, tc *v1alpha1.TidbCluster, tm *v1alpha1.TidbMonitor) *v1alpha1.TidbClusterAutoScaler

func NewTidbMonitor

func NewTidbMonitor(name, namespace string, tc *v1alpha1.TidbCluster, grafanaEnabled, persist bool) *v1alpha1.TidbMonitor

Types

This section is empty.

Jump to

Keyboard shortcuts

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