Documentation
¶
Index ¶
- Constants
- func CreateSuffixString() string
- func Delete(namespace, cluster string) error
- func GetK8sClient() (*kubernetes.Clientset, error)
- func GetProviderName(provider string) (string, error)
- func GetRemoteK8sClient(secret *coreV1.Secret) (*kubernetes.Clientset, error)
- func GetRemoteK8sClientByKubeConfig(kubeConfig []byte) (*kubernetes.Clientset, error)
- func Insert(clusterManager *clusterV1alpha1.ClusterManager) error
- func IsOK(check int) bool
- func List(namespace, cluster string) ([]byte, error)
- func LowestNonZeroResult(i, j ctrl.Result) ctrl.Result
- func MergeJson(dest []byte, source []byte) []byte
- func SetHyperregistryOIDC(config OidcConfig, secret *coreV1.Secret, hostpath string) error
- func SetHyperregistryServiceURI(hostpath string, serviceName string, urlParameter map[string]string) string
- func URIToSecretName(uriType, uri string) (string, error)
- type OidcConfig
Constants ¶
View Source
const ( KubeNamespace = "kube-system" ApiGatewayNamespace = "api-gateway-system" IngressNginxNamespace = "ingress-nginx" ArgoNamespace = "argocd" HyperregistryNamespace = "hyperregistry" OpenSearchNamespace = "kube-logging" )
View Source
const ( ProviderAws = "AWS" ProviderAwsLogo = "AWS" ProviderVsphere = "VSPHERE" ProviderVsphereLogo = "vSphere" ProviderUnknown = "Unknown" )
View Source
const ( ClmSecretTypeKubeconfig = "kubeconfig" ClmSecretTypeArgo = "argocd" ClmSecretTypeSAToken = "token" )
View Source
const ( ArgoApiGroup = "argocd.argoproj.io" ArgoServiceAccount = "argocd-manager" ArgoServiceAccountTokenSecret = "argocd-manager-token" ArgoClusterRole = "argocd-manager-role" ArgoClusterRoleBinding = "argocd-manager-role-binding" ArgoSecretTypeCluster = "cluster" ArgoSecretTypeGit = "repo" )
View Source
const ( AnnotationKeyOwner = "owner" AnnotationKeyCreator = "creator" AnnotationKeyArgoClusterSecret = "argocd.argoproj.io/cluster.secret" AnnotationKeyArgoManagedBy = "managed-by" AnnotationKeyTraefikServerTransport = "traefik.ingress.kubernetes.io/service.serverstransport" AnnotationKeyTraefikEntrypoints = "traefik.ingress.kubernetes.io/router.entrypoints" AnnotationKeyTraefikMiddlewares = "traefik.ingress.kubernetes.io/router.middlewares" AnnotationKeyTraefikServerScheme = "traefik.ingress.kubernetes.io/service.serversscheme" )
View Source
const ( LabelKeyHypercloudIngress = "ingress.tmaxcloud.org/name" LabelKeyClmSecretType = "cluster.tmax.io/clm-secret-type" LabelKeyArgoSecretType = "argocd.argoproj.io/secret-type" LabelKeyCapiClusterName = "cluster.x-k8s.io/cluster-name" LabelKeyArgoTargetCluster = "cluster" )
View Source
const (
HARBOR_SERVICE_SET_OIDC_CONFIG = "/api/v2.0/configurations"
)
View Source
const ( // defunct // MultiApiServerServiceSelectorKey = "hypercloud4" // MultiApiServerServiceSelectorValue = "multi-api-server" IngressNginxName = "ingress-nginx-controller" )
View Source
const (
KubeconfigSuffix = "-kubeconfig"
)
Variables ¶
This section is empty.
Functions ¶
func CreateSuffixString ¶
func CreateSuffixString() string
func GetK8sClient ¶
func GetK8sClient() (*kubernetes.Clientset, error)
func GetProviderName ¶
func GetRemoteK8sClient ¶
func GetRemoteK8sClient(secret *coreV1.Secret) (*kubernetes.Clientset, error)
func GetRemoteK8sClientByKubeConfig ¶
func GetRemoteK8sClientByKubeConfig(kubeConfig []byte) (*kubernetes.Clientset, error)
func Insert ¶
func Insert(clusterManager *clusterV1alpha1.ClusterManager) error
func LowestNonZeroResult ¶
LowestNonZeroResult compares two reconciliation results and returns the one with lowest requeue time.
func SetHyperregistryOIDC ¶
func SetHyperregistryOIDC(config OidcConfig, secret *coreV1.Secret, hostpath string) error
func URIToSecretName ¶
Types ¶
type OidcConfig ¶
type OidcConfig struct {
AuthMode string `json:"auth_mode,omitempty"`
OidcAdminGroup string `json:"oidc_admin_group,omitempty"`
OidcAutoOnBoard bool `json:"oidc_auto_onboard,omitempty"`
OidcClientId string `json:"oidc_client_id,omitempty"`
OidcClientSecret string `json:"oidc_client_secret,omitempty"`
OidcEndpoint string `json:"oidc_endpoint,omitempty"`
OidcGroupsClaim string `json:"oidc_groups_claim,omitempty"`
OidcName string `json:"oidc_name,omitempty"`
OidcScope string `json:"oidc_scope,omitempty"`
OidcUserClaim string `json:"oidc_user_claim,omitempty"`
OidcVerifyCert bool `json:"oidc_verify_cert,omitempty"`
}
Click to show internal directories.
Click to hide internal directories.