kubernetes

package
v0.0.0-...-c6aef44 Latest Latest
Warning

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

Go to latest
Published: Jul 26, 2024 License: Apache-2.0 Imports: 16 Imported by: 1

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func EnsureClusterRole

func EnsureClusterRole(ctx context.Context, kubeconfig []byte, projectName string) error

func EnsureClusterRoleBinding

func EnsureClusterRoleBinding(ctx context.Context, kubeconfig []byte, projectName string) error

func EnsureCommonClusterRole

func EnsureCommonClusterRole(ctx context.Context, kubeconfig []byte, projectName string) error

func EnsureCommonClusterRoleBinding

func EnsureCommonClusterRoleBinding(ctx context.Context, kubeconfig []byte, projectName string) error

func EnsureNamespace

func EnsureNamespace(ctx context.Context, kubeconfig []byte, projectName string) error

func EnsureRoleBinding

func EnsureRoleBinding(ctx context.Context, kubeconfig []byte, projectId string, namespace string) error

func GetAwsAccountIdSecret

func GetAwsAccountIdSecret(ctx context.Context) (awsAccountId string, err error)

func GetAwsSecret

func GetAwsSecret(ctx context.Context) (awsAccessKeyId string, awsSecretAccessKey string, err error)

func GetClientAdminCluster

func GetClientAdminCluster(ctx context.Context) (*kubernetes.Clientset, error)

func GetClientFromClusterId

func GetClientFromClusterId(ctx context.Context, clusterId string) (*kubernetes.Clientset, error)

func GetDynamicClientAdminCluster

func GetDynamicClientAdminCluster(ctx context.Context) (*dynamic.DynamicClient, error)

쿠버네티스 기본 타입 이외의 타입(예: 정책 템플릿, 정책 등)을 처리하기 위한 dynamic client 생성

func GetKubeconfig

func GetKubeconfig(ctx context.Context, clusterId string, configType KubeconfigType) ([]byte, error)

func GetKubernetesVserion

func GetKubernetesVserion(ctx context.Context) (string, error)

func GetKubernetesVserionByClusterId

func GetKubernetesVserionByClusterId(ctx context.Context, clusterId string) (string, error)

func GetResourceApiVersion

func GetResourceApiVersion(ctx context.Context, kubeconfig []byte, kind string) (string, error)

func MergeKubeconfigsWithSingleUser

func MergeKubeconfigsWithSingleUser(kubeconfigs []string) (string, error)

func RemoveClusterRole

func RemoveClusterRole(ctx context.Context, kubeconfig []byte, projectName string) error

func RemoveClusterRoleBinding

func RemoveClusterRoleBinding(ctx context.Context, kubeconfig []byte, projectName string) error

func RemoveCommonClusterRole

func RemoveCommonClusterRole(ctx context.Context, kubeconfig []byte, projectName string) error

func RemoveCommonClusterRoleBinding

func RemoveCommonClusterRoleBinding(ctx context.Context, kubeconfig []byte, projectName string) error

func RemoveRoleBinding

func RemoveRoleBinding(ctx context.Context, kubeconfig []byte, projectName string, namespace string) error

Types

type KubeconfigType

type KubeconfigType string
const (
	KubeconfigForAdmin KubeconfigType = "admin"
	KubeconfigForUser  KubeconfigType = "user"
)

Jump to

Keyboard shortcuts

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