Skip to content

Commit a9ef2e6

Browse files
authored
Merge branch 'tf-palette-4.7.b' into dependabot/go_modules/github.com/hashicorp/terraform-plugin-sdk/v2-2.37.0
2 parents 59fe8c7 + e3ca84a commit a9ef2e6

File tree

102 files changed

+2388
-742
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

102 files changed

+2388
-742
lines changed

docs/index.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -174,7 +174,7 @@ For questions or issues with the provider, open up an issue in the provider GitH
174174

175175
- `api_key` (String, Sensitive) The Spectro Cloud API key. Can also be set with the `SPECTROCLOUD_APIKEY` environment variable.
176176
- `host` (String) The Spectro Cloud API host url. Can also be set with the `SPECTROCLOUD_HOST` environment variable. Defaults to https://api.spectrocloud.com
177-
- `ignore_insecure_tls_error` (Boolean) Ignore insecure TLS errors for Spectro Cloud API endpoints. Defaults to false.
177+
- `ignore_insecure_tls_error` (Boolean) Ignore insecure TLS errors for Spectro Cloud API endpoints. ⚠️ WARNING: Setting this to true disables SSL certificate verification and makes connections vulnerable to man-in-the-middle attacks. Only use this in development/testing environments or when connecting to self-signed certificates in trusted networks. Defaults to false.
178178
- `project_name` (String) The Palette project the provider will target. If no value is provided, the `Default` Palette project is used. The default value is `Default`.
179179
- `retry_attempts` (Number) Number of retry attempts. Can also be set with the `SPECTROCLOUD_RETRY_ATTEMPTS` environment variable. Defaults to 10.
180180
- `trace` (Boolean) Enable HTTP request tracing. Can also be set with the `SPECTROCLOUD_TRACE` environment variable. To enable Terraform debug logging, set `TF_LOG=DEBUG`. Visit the Terraform documentation to learn more about Terraform [debugging](https://developer.hashicorp.com/terraform/plugin/log/managing).

docs/resources/appliance.md

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,21 @@ resource "spectrocloud_appliance" "appliance" {
2121
}
2222
```
2323

24+
## Import
25+
26+
Appliances can be imported using the appliance UID. This is a project-level resource.
27+
28+
```bash
29+
terraform import spectrocloud_appliance.example <appliance_uid>
30+
```
31+
32+
Where `<appliance_uid>` is the appliance UID.
33+
34+
The import will automatically populate all configuration fields from the Spectro Cloud API, including the UID, tags, and tunnel configuration settings. The `wait` field will be set to `false` by default for imported appliances. After import, you can run `terraform plan` to see the current configuration and make any necessary adjustments.
35+
36+
**Note**: Since this is a project-level resource, ensure your provider is configured with appropriate project-level credentials and access.
37+
38+
2439
<!-- schema generated by tfplugindocs -->
2540
## Schema
2641

docs/resources/application.md

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -32,6 +32,16 @@ resource "spectrocloud_application" "application" {
3232
3333
```
3434

35+
## Import
36+
37+
Applications can be imported using their UID. The import will automatically detect the cluster context.
38+
39+
```bash
40+
terraform import spectrocloud_application.example 63444eb70807dc2c14a8ad59
41+
```
42+
43+
Note: During import, the application's configuration will be automatically populated from the Spectro Cloud API, including the correct cluster context.
44+
3545

3646
<!-- schema generated by tfplugindocs -->
3747
## Schema

docs/resources/application_profile.md

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -349,6 +349,21 @@ resource "spectrocloud_application_profile" "app_profile_all_tiers" {
349349
350350
```
351351

352+
```
353+
## Import
354+
355+
# terraform import spectrocloud_application_profile.app_profile_all_tiers "profile_uid_here"
356+
#
357+
# Where:
358+
# - profile_uid_here is the unique identifier of the application profile
359+
#
360+
# To import using import block:
361+
# import {
362+
# to = spectrocloud_application_profile.app_profile_all_tiers
363+
# id = "profile_uid_here"
364+
# }
365+
```
366+
352367
<!-- schema generated by tfplugindocs -->
353368
## Schema
354369

docs/resources/backup_storage_location.md

Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -44,6 +44,33 @@ resource "spectrocloud_backup_storage_location" "bsl2" {
4444
}
4545
```
4646

47+
## Import
48+
49+
Backup Storage Locations can be imported using either a simple ID format or with explicit context specification. This resource supports both project and tenant contexts.
50+
51+
### Simple Import (defaults to project context)
52+
53+
```bash
54+
terraform import spectrocloud_backup_storage_location.example <bsl_id>:project
55+
```
56+
57+
### Context-specific Import
58+
59+
```bash
60+
terraform import spectrocloud_backup_storage_location.example <bsl_id>:project
61+
terraform import spectrocloud_backup_storage_location.example <bsl_id>:tenant
62+
```
63+
64+
Where:
65+
- `<bsl_id>` is the Backup Storage Location ID
66+
- `project` or `tenant` specifies the context where the backup storage location exists
67+
68+
**Import behavior:**
69+
- If no context is specified, it defaults to `project` context
70+
- If the resource is not found in the specified context, the import will automatically try the other context
71+
- The import will automatically populate all configuration fields from the Spectro Cloud API, including the correct context, storage provider, and all provider-specific settings
72+
73+
After import, you can run `terraform plan` to see the current configuration and make any necessary adjustments.
4774

4875

4976
<!-- schema generated by tfplugindocs -->

docs/resources/cloudaccount_azure.md

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,12 +34,13 @@ resource "spectrocloud_cloudaccount_azure" "azure-1" {
3434
### Optional
3535

3636
- `cloud` (String) The Azure partition in which the cloud account is located.
37-
Can be 'AzurePublicCloud' for standard Azure regions or 'AzureUSGovernmentCloud' for Azure GovCloud (US) regions.
37+
Can be 'AzurePublicCloud' for standard Azure regions or 'AzureUSGovernmentCloud' for Azure GovCloud (US) regions or 'AzureUSSecretCloud' for Azure Secret Cloud regions.
3838
Default is 'AzurePublicCloud'.
3939
- `context` (String) The context of the Azure configuration. Defaults to `project`. If the `project` context is specified, the project name will sourced from the provider configuration parameter [`project_name`](https://registry.terraform.io/providers/spectrocloud/spectrocloud/latest/docs#schema).
4040
- `disable_properties_request` (Boolean) Disable properties request. This is a boolean value that indicates whether to disable properties request or not. If not specified, the default value is `false`.
4141
- `private_cloud_gateway_id` (String) ID of the private cloud gateway. This is the ID of the private cloud gateway that is used to connect to the private cluster endpoint.
4242
- `tenant_name` (String) The name of the tenant. This is the name of the tenant that is used to connect to the Azure cloud.
43+
- `tls_cert` (String) TLS certificate for authentication. This field is only allowed when cloud is set to 'AzureUSSecretCloud'.
4344

4445
### Read-Only
4546

docs/resources/cluster_group.md

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -40,6 +40,25 @@ resource "spectrocloud_cluster_group" "cg" {
4040
4141
```
4242

43+
## Import
44+
45+
In Terraform v1.5.0 and later, use an [`import` block](https://developer.hashicorp.com/terraform/language/import)
46+
to import the resource spectrocloud_cluster_group by using its `id` with the Palette `context` separated by a colon. For example:
47+
48+
```terraform
49+
import {
50+
to = spectrocloud_cluster_group.example
51+
id = "example_id:context"
52+
}
53+
```
54+
55+
Using `terraform import`, import the cluster group using the `id` colon separated with `context`. For example:
56+
57+
```console
58+
terraform import spectrocloud_cluster_group.example example_id:project
59+
```
60+
61+
Refer to the [Import section](/docs#import) to learn more.
4362

4463
<!-- schema generated by tfplugindocs -->
4564
## Schema

docs/resources/cluster_maas.md

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -169,6 +169,10 @@ Required:
169169

170170
- `domain` (String) Domain name in which the cluster to be provisioned.
171171

172+
Optional:
173+
174+
- `enable_lxd_vm` (Boolean) Whether to enable LXD VM. Default is `false`.
175+
172176

173177
<a id="nestedblock--machine_pool"></a>
174178
### Nested Schema for `machine_pool`
@@ -179,6 +183,7 @@ Required:
179183
- `count` (Number) Number of nodes in the machine pool.
180184
- `instance_type` (Block List, Min: 1, Max: 1) (see [below for nested schema](#nestedblock--machine_pool--instance_type))
181185
- `name` (String) Name of the machine pool.
186+
- `network` (Block List, Min: 1, Max: 1) (see [below for nested schema](#nestedblock--machine_pool--network))
182187
- `placement` (Block List, Min: 1, Max: 1) (see [below for nested schema](#nestedblock--machine_pool--placement))
183188

184189
Optional:
@@ -193,6 +198,7 @@ Optional:
193198
- `node_tags` (Set of String) Node tags to dynamically place nodes in a pool by using MAAS automatic tags. Specify the tag values that you want to apply to all nodes in the node pool.
194199
- `taints` (Block List) (see [below for nested schema](#nestedblock--machine_pool--taints))
195200
- `update_strategy` (String) Update strategy for the machine pool. Valid values are `RollingUpdateScaleOut` and `RollingUpdateScaleIn`.
201+
- `use_lxd_vm` (Boolean) Whether to use LXD VM. Default is `false`.
196202

197203
<a id="nestedblock--machine_pool--instance_type"></a>
198204
### Nested Schema for `machine_pool.instance_type`
@@ -203,6 +209,19 @@ Required:
203209
- `min_memory_mb` (Number) Minimum memory in MB required for the machine pool node.
204210

205211

212+
<a id="nestedblock--machine_pool--network"></a>
213+
### Nested Schema for `machine_pool.network`
214+
215+
Required:
216+
217+
- `network_name` (String) The name of the network in which VMs are created/located.
218+
219+
Optional:
220+
221+
- `parent_pool_uid` (String) The UID of the parent pool which allocates IPs for this IPPool.
222+
- `static_ip` (Boolean) Whether to use static IP. Default is `false`.
223+
224+
206225
<a id="nestedblock--machine_pool--placement"></a>
207226
### Nested Schema for `machine_pool.placement`
208227

docs/resources/macro.md

Lines changed: 0 additions & 52 deletions
This file was deleted.

docs/resources/privatecloudgateway_dns_map.md

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,23 @@ An example of creating an DNS Map for a Private Cloud Gateway using a search dom
2727
}
2828
```
2929

30+
## Import
31+
32+
Private Cloud Gateway DNS maps can be imported using the composite ID format: `pcg_id:dns_map_id`. This is a tenant-level resource.
33+
34+
```bash
35+
terraform import spectrocloud_privatecloudgateway_dns_map.example <pcg_id>:<dns_map_id>
36+
```
37+
38+
Where:
39+
- `<pcg_id>` is the Private Cloud Gateway ID
40+
- `<dns_map_id>` is the DNS map ID
41+
42+
The import will automatically populate all configuration fields from the Spectro Cloud API, including the associated Private Cloud Gateway ID, search domain name, data center, and network. After import, you can run `terraform plan` to see the current configuration and make any necessary adjustments.
43+
44+
**Note**: Since this is a tenant-level resource, ensure your provider is configured with appropriate tenant-level credentials and access.
45+
46+
3047
<!-- schema generated by tfplugindocs -->
3148
## Schema
3249

0 commit comments

Comments
 (0)