Documentation
¶
Index ¶
- Constants
- func CompareTwoContainerEnvs(s1 []v1.EnvVar, s2 []v1.EnvVar) bool
- func Get(ctx context.Context, k8sClient client.Client, ...) (v1beta1.Configuration, error)
- func GetProviderNamespacedName(configuration v1beta1.Configuration) *crossplane.Reference
- func Interface2String(v interface{}) (string, error)
- func IsDeletable(ctx context.Context, k8sClient client.Client, ...) (bool, error)
- func RawExtension2Map(raw *runtime.RawExtension) (map[string]interface{}, error)
- func RenderConfiguration(configuration *v1beta1.Configuration, terraformBackendNamespace string, ...) (string, error)
- func RenderTemplate(backend *v1beta1.Backend, namespace string) (string, error)
- func ReplaceTerraformSource(remote string, githubBlockedStr string) string
- func SetRegion(ctx context.Context, k8sClient client.Client, namespace, name string, ...) (string, error)
- func Update(ctx context.Context, k8sClient client.Client, ...) error
- func ValidConfigurationObject(configuration *v1beta1.Configuration) (types.ConfigurationType, error)
Constants ¶
const ( // GithubPrefix is the constant of GitHub domain GithubPrefix = "https://github.com/" // GithubKubeVelaContribPrefix is the prefix of GitHub repository of kubevela-contrib GithubKubeVelaContribPrefix = "https://github.com/kubevela-contrib" // GiteeTerraformSourceOrg is the Gitee organization of Terraform source GiteeTerraformSourceOrg = "https://gitee.com/kubevela-terraform-source" // GiteePrefix is the constant of Gitee domain GiteePrefix = "https://gitee.com/" )
Variables ¶
This section is empty.
Functions ¶
func CompareTwoContainerEnvs ¶
CompareTwoContainerEnvs compares two slices of v1.EnvVar
func Get ¶ added in v0.2.10
func Get(ctx context.Context, k8sClient client.Client, namespacedName apitypes.NamespacedName) (v1beta1.Configuration, error)
Get will get the Configuration
func GetProviderNamespacedName ¶ added in v0.3.2
func GetProviderNamespacedName(configuration v1beta1.Configuration) *crossplane.Reference
GetProviderNamespacedName will get the provider namespaced name
func Interface2String ¶ added in v0.2.6
Interface2String converts an interface{} type to string
func IsDeletable ¶ added in v0.3.2
func IsDeletable(ctx context.Context, k8sClient client.Client, configuration *v1beta1.Configuration) (bool, error)
IsDeletable will check whether the Configuration can be deleted immediately If deletable, it means no external cloud resources are provisioned
func RawExtension2Map ¶ added in v0.2.6
func RawExtension2Map(raw *runtime.RawExtension) (map[string]interface{}, error)
RawExtension2Map will convert rawExtension to map This function is copied from oam-dev/kubevela
func RenderConfiguration ¶ added in v0.1.19
func RenderConfiguration(configuration *v1beta1.Configuration, terraformBackendNamespace string, configurationType types.ConfigurationType) (string, error)
RenderConfiguration will compose the Terraform configuration with hcl/json and backend
func RenderTemplate ¶ added in v0.2.6
RenderTemplate renders Backend template
func ReplaceTerraformSource ¶ added in v0.2.15
ReplaceTerraformSource will replace the Terraform source from GitHub to Gitee
func SetRegion ¶ added in v0.2.10
func SetRegion(ctx context.Context, k8sClient client.Client, namespace, name string, providerObj *v1beta1.Provider) (string, error)
SetRegion will set the region for Configuration
func Update ¶ added in v0.2.10
func Update(ctx context.Context, k8sClient client.Client, configuration *v1beta1.Configuration) error
Update will update the Configuration
func ValidConfigurationObject ¶
func ValidConfigurationObject(configuration *v1beta1.Configuration) (types.ConfigurationType, error)
ValidConfigurationObject will validate a Configuration
Types ¶
This section is empty.