Implement new stackit_network resource and datasource (#366)
* Copy file from DNS zone resource * Implement resource * Implement datasource * Add examples * Implement acceptance test; Some fixes * Add docs * Fix linter * Fixes after review
This commit is contained in:
parent
940b15e4b8
commit
76b8e5692d
14 changed files with 1216 additions and 4 deletions
|
|
@ -39,6 +39,7 @@ var (
|
|||
|
||||
ArgusCustomEndpoint = os.Getenv("TF_ACC_ARGUS_CUSTOM_ENDPOINT")
|
||||
DnsCustomEndpoint = os.Getenv("TF_ACC_DNS_CUSTOM_ENDPOINT")
|
||||
IaaSCustomEndpoint = os.Getenv("TF_ACC_IAAS_CUSTOM_ENDPOINT")
|
||||
LoadBalancerCustomEndpoint = os.Getenv("TF_ACC_LOADBALANCER_CUSTOM_ENDPOINT")
|
||||
LogMeCustomEndpoint = os.Getenv("TF_ACC_LOGME_CUSTOM_ENDPOINT")
|
||||
MariaDBCustomEndpoint = os.Getenv("TF_ACC_MARIADB_CUSTOM_ENDPOINT")
|
||||
|
|
@ -89,6 +90,21 @@ func DnsProviderConfig() string {
|
|||
)
|
||||
}
|
||||
|
||||
func IaaSProviderConfig() string {
|
||||
if IaaSCustomEndpoint == "" {
|
||||
return `
|
||||
provider "stackit" {
|
||||
region = "eu01"
|
||||
}`
|
||||
}
|
||||
return fmt.Sprintf(`
|
||||
provider "stackit" {
|
||||
iaas_custom_endpoint = "%s"
|
||||
}`,
|
||||
IaaSCustomEndpoint,
|
||||
)
|
||||
}
|
||||
|
||||
func LoadBalancerProviderConfig() string {
|
||||
if LoadBalancerCustomEndpoint == "" {
|
||||
return `
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue