Documentation ¶
Index ¶
- Constants
- Variables
- func DiffBasedOnVersion(_, old, new string, _ *schema.ResourceData) bool
- func DiffCidr(_, old, new string, _ *schema.ResourceData) bool
- func DiffExpiryDate(_, old, new string, _ *schema.ResourceData) bool
- func ForceNewForFlowlogChanges(_ context.Context, d *schema.ResourceDiff, _ interface{}) error
- func ImageSetData(d *schema.ResourceData, image *ionoscloud.Image) error
- func IpBlockSetData(d *schema.ResourceData, ipBlock *ionoscloud.IpBlock) error
- func K8sClusterProperties(ctx context.Context, cluster ionoscloud.KubernetesCluster, ...) (map[string]any, error)
- func NewClientByType(clientOpts ClientOptions, clientType clientType) interface{}
- func Provider() *schema.Provider
- func SetCdromProperties(image ionoscloud.Image) map[string]interface{}
- func SetCubeVolumeProperties(volume ionoscloud.Volume) map[string]interface{}
- func SetServerProperties(server ionoscloud.Server) map[string]interface{}
- func SetVolumeProperties(volume ionoscloud.Volume) map[string]interface{}
- func VerifyUnavailableIPs(val interface{}, key string) (warns []string, errs []error)
- type ClientOptions
- type Config
- type KubeConfig
- type Label
- type LabelsService
Constants ¶
const ( K8sVersion = "1.26.4" UpgradedK8sVersion = "1.26.6" K8sBucket = "test_k8s_terraform_v7" K8sPrivateClusterNodeSubnet = "192.168.0.0/16" )
K8s values
const DNSRecordConfig = DNSZoneConfig + ` resource ` + constant.DNSRecordResource + ` ` + constant.DNSRecordTestResourceName + ` { zone_id = ` + constant.DNSZoneResource + `.` + constant.DNSZoneTestResourceName + `.id ` + recordNameAttribute + ` = "` + recordNameValue + `" ` + recordTypeAttribute + ` = "` + recordTypeValue + `" ` + recordContentAttribute + ` = "` + recordContentValue + `" ` + recordTtlAttribute + ` = ` + recordTtlValue + ` ` + recordPriorityAttribute + ` = ` + recordPriorityValue + ` ` + recordEnabledAttribute + ` = ` + recordEnabledValue + ` } `
const DNSZoneConfig = ` resource ` + constant.DNSZoneResource + ` ` + constant.DNSZoneTestResourceName + ` { ` + zoneNameAttribute + ` = "` + zoneNameValue + `" ` + zoneDescriptionAttribute + ` = "` + zoneDescriptionValue + `" ` + zoneEnabledAttribute + ` = ` + zoneEnabledValue + ` } `
const HDDImage = "HDD"
const ImmutableError = "attribute is immutable, therefore not allowed in update requests"
const LoggingPipelineConfig = ` resource ` + constant.LoggingPipelineResource + ` ` + constant.LoggingPipelineTestResourceName + ` { ` + pipelineNameAttribute + ` = "` + pipelineNameValue + `" ` + pipelineLog + ` } `
Standard configuration
const ServerImagePassword = ` resource ` + constant.RandomPassword + ` "server_image_password" { length = 16 special = false } `
const ServerImagePasswordUpdated = ` resource ` + constant.RandomPassword + ` "server_image_password_updated" { length = 16 special = false } `
Variables ¶
var Version = "DEV"
Functions ¶
func DiffBasedOnVersion ¶
func DiffBasedOnVersion(_, old, new string, _ *schema.ResourceData) bool
DiffBasedOnVersion used for k8 node pool and cluster ignores downgrades of the patch versions.
func DiffCidr ¶ added in v6.1.3
func DiffCidr(_, old, new string, _ *schema.ResourceData) bool
DiffCidr terraform suppress differences between ip and cidr
func DiffExpiryDate ¶ added in v6.3.3
func DiffExpiryDate(_, old, new string, _ *schema.ResourceData) bool
DiffExpiryDate terraform suppress differences between layout and default +0000 UTC time format
func ForceNewForFlowlogChanges ¶ added in v6.4.11
func ForceNewForFlowlogChanges(_ context.Context, d *schema.ResourceDiff, _ interface{}) error
ForceNewForFlowlogChanges - sets ForceNew either on `flowlog` if it is being deleted, or on the field that changes. This is needed because the API does not support PATCH for all flowlog fields except name. The API also does not support DELETE on the flowlog, so the whole resource needs to be re-created.
func ImageSetData ¶ added in v6.1.6
func ImageSetData(d *schema.ResourceData, image *ionoscloud.Image) error
func IpBlockSetData ¶
func IpBlockSetData(d *schema.ResourceData, ipBlock *ionoscloud.IpBlock) error
func K8sClusterProperties ¶ added in v6.4.13
func K8sClusterProperties(ctx context.Context, cluster ionoscloud.KubernetesCluster, client *ionoscloud.APIClient) (map[string]any, error)
K8sClusterProperties returns a map equivalent of dataSourceK8sClusterSchema
func NewClientByType ¶ added in v6.3.2
func NewClientByType(clientOpts ClientOptions, clientType clientType) interface{}
func SetCdromProperties ¶ added in v6.3.1
func SetCdromProperties(image ionoscloud.Image) map[string]interface{}
func SetCubeVolumeProperties ¶ added in v6.3.3
func SetCubeVolumeProperties(volume ionoscloud.Volume) map[string]interface{}
func SetServerProperties ¶ added in v6.3.0
func SetServerProperties(server ionoscloud.Server) map[string]interface{}
func SetVolumeProperties ¶
func SetVolumeProperties(volume ionoscloud.Volume) map[string]interface{}
func VerifyUnavailableIPs ¶ added in v6.1.0
VerifyUnavailableIPs used for DBaaS cluster to check the provided IPs
Types ¶
type ClientOptions ¶ added in v6.3.3
type KubeConfig ¶
type KubeConfig struct { ApiVersion string `yaml:"apiVersion"` Clusters []struct { Name string Cluster struct { CaData string `yaml:"certificate-authority-data"` Server string } } Contexts []struct { Name string Context struct { Cluster string User string } } CurrentContext string `yaml:"current-context"` Kind string Users []struct { Name string User struct { Token string } } }
type LabelsService ¶ added in v6.3.4
type LabelsService struct {
// contains filtered or unexported fields
}
Source Files ¶
- config.go
- data_source_application_loadbalancer.go
- data_source_application_loadbalancer_forwardingrule.go
- data_source_autoscaling_group.go
- data_source_autoscaling_group_servers.go
- data_source_backup_unit.go
- data_source_certificate_manager.go
- data_source_container_registry.go
- data_source_container_registry_locations.go
- data_source_container_registry_token.go
- data_source_cube_server.go
- data_source_datacenter.go
- data_source_dataplatform_cluster.go
- data_source_dataplatform_node_pool.go
- data_source_dataplatform_node_pools.go
- data_source_dataplatform_versions.go
- data_source_dbaas_mariadb_backups.go
- data_source_dbaas_mariadb_cluster.go
- data_source_dbaas_mongo_cluster.go
- data_source_dbaas_mongo_template.go
- data_source_dbaas_mongo_user.go
- data_source_dbaas_pgsql_backups.go
- data_source_dbaas_pgsql_cluster.go
- data_source_dbaas_pgsql_database.go
- data_source_dbaas_pgsql_databases.go
- data_source_dbaas_pgsql_user.go
- data_source_dbaas_pgsql_versions.go
- data_source_dns_record.go
- data_source_dns_zone.go
- data_source_firewall.go
- data_source_group.go
- data_source_image.go
- data_source_ipblock.go
- data_source_ipfailover.go
- data_source_k8s_cluster.go
- data_source_k8s_clusters.go
- data_source_k8s_node_pool.go
- data_source_k8s_node_pool_nodes.go
- data_source_lan.go
- data_source_location.go
- data_source_logging_pipeline.go
- data_source_natgateway.go
- data_source_natgateway_rule.go
- data_source_networkloadbalancer.go
- data_source_networkloadbalancer_forwardingrule.go
- data_source_nic.go
- data_source_private_crossconnect.go
- data_source_resource.go
- data_source_s3_key.go
- data_source_server.go
- data_source_servers.go
- data_source_share.go
- data_source_snapshot.go
- data_source_target_group.go
- data_source_template.go
- data_source_user.go
- data_source_vcpu_server.go
- data_source_volume.go
- labels_service.go
- provider.go
- resource_application_loadbalancer.go
- resource_application_loadbalancer_forwardingrule.go
- resource_autoscaling_group.go
- resource_backup_unit.go
- resource_certificate_manager.go
- resource_container_registry.go
- resource_container_registry_token.go
- resource_datacenter.go
- resource_dataplatform_cluster.go
- resource_dataplatform_nodepool.go
- resource_dbaas_mariadb_cluster.go
- resource_dbaas_mongodb_cluster.go
- resource_dbaas_mongodb_user.go
- resource_dbaas_pgsql_cluster.go
- resource_dbaas_pgsql_database.go
- resource_dbaas_pgsql_user.go
- resource_dns_record.go
- resource_dns_zone.go
- resource_firewall.go
- resource_group.go
- resource_ipblock.go
- resource_ipfailover.go
- resource_k8s_cluster.go
- resource_k8s_node_pool.go
- resource_lan.go
- resource_loadbalancer.go
- resource_logging_pipeline.go
- resource_natgateway.go
- resource_natgateway_rule.go
- resource_networkloadbalancer.go
- resource_networkloadbalancer_forwardingrule.go
- resource_nic.go
- resource_private_crossconnect.go
- resource_s3_key.go
- resource_server.go
- resource_server_boot_device_selection.go
- resource_server_cube.go
- resource_server_vcpu.go
- resource_share.go
- resource_snapshot.go
- resource_target_group.go
- resource_user.go
- resource_volume.go
- testUtil.go
- test_constants.go
- utils.go