Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

PLT-1110: Added profile variable support during cluster provisioning. #557

Merged
merged 4 commits into from
Dec 26, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions docs/resources/addon_deployment.md
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,7 @@ Required:
Optional:

- `pack` (Block List) For packs of type `spectro`, `helm`, and `manifest`, at least one pack must be specified. (see [below for nested schema](#nestedblock--cluster_profile--pack))
- `variables` (Map of String) A map of cluster profile variables, specified as key-value pairs. For example: `priority = "5"`.

<a id="nestedblock--cluster_profile--pack"></a>
### Nested Schema for `cluster_profile.pack`
Expand Down
1 change: 1 addition & 0 deletions docs/resources/cluster_aks.md
Original file line number Diff line number Diff line change
Expand Up @@ -243,6 +243,7 @@ Required:
Optional:

- `pack` (Block List) For packs of type `spectro`, `helm`, and `manifest`, at least one pack must be specified. (see [below for nested schema](#nestedblock--cluster_profile--pack))
- `variables` (Map of String) A map of cluster profile variables, specified as key-value pairs. For example: `priority = "5"`.

<a id="nestedblock--cluster_profile--pack"></a>
### Nested Schema for `cluster_profile.pack`
Expand Down
1 change: 1 addition & 0 deletions docs/resources/cluster_aws.md
Original file line number Diff line number Diff line change
Expand Up @@ -270,6 +270,7 @@ Required:
Optional:

- `pack` (Block List) For packs of type `spectro`, `helm`, and `manifest`, at least one pack must be specified. (see [below for nested schema](#nestedblock--cluster_profile--pack))
- `variables` (Map of String) A map of cluster profile variables, specified as key-value pairs. For example: `priority = "5"`.

<a id="nestedblock--cluster_profile--pack"></a>
### Nested Schema for `cluster_profile.pack`
Expand Down
1 change: 1 addition & 0 deletions docs/resources/cluster_azure.md
Original file line number Diff line number Diff line change
Expand Up @@ -252,6 +252,7 @@ Required:
Optional:

- `pack` (Block List) For packs of type `spectro`, `helm`, and `manifest`, at least one pack must be specified. (see [below for nested schema](#nestedblock--cluster_profile--pack))
- `variables` (Map of String) A map of cluster profile variables, specified as key-value pairs. For example: `priority = "5"`.

<a id="nestedblock--cluster_profile--pack"></a>
### Nested Schema for `cluster_profile.pack`
Expand Down
1 change: 1 addition & 0 deletions docs/resources/cluster_custom_cloud.md
Original file line number Diff line number Diff line change
Expand Up @@ -235,6 +235,7 @@ Required:
Optional:

- `pack` (Block List) For packs of type `spectro`, `helm`, and `manifest`, at least one pack must be specified. (see [below for nested schema](#nestedblock--cluster_profile--pack))
- `variables` (Map of String) A map of cluster profile variables, specified as key-value pairs. For example: `priority = "5"`.

<a id="nestedblock--cluster_profile--pack"></a>
### Nested Schema for `cluster_profile.pack`
Expand Down
1 change: 1 addition & 0 deletions docs/resources/cluster_edge_native.md
Original file line number Diff line number Diff line change
Expand Up @@ -215,6 +215,7 @@ Required:
Optional:

- `pack` (Block List) For packs of type `spectro`, `helm`, and `manifest`, at least one pack must be specified. (see [below for nested schema](#nestedblock--cluster_profile--pack))
- `variables` (Map of String) A map of cluster profile variables, specified as key-value pairs. For example: `priority = "5"`.

<a id="nestedblock--cluster_profile--pack"></a>
### Nested Schema for `cluster_profile.pack`
Expand Down
1 change: 1 addition & 0 deletions docs/resources/cluster_edge_vsphere.md
Original file line number Diff line number Diff line change
Expand Up @@ -171,6 +171,7 @@ Required:
Optional:

- `pack` (Block List) For packs of type `spectro`, `helm`, and `manifest`, at least one pack must be specified. (see [below for nested schema](#nestedblock--cluster_profile--pack))
- `variables` (Map of String) A map of cluster profile variables, specified as key-value pairs. For example: `priority = "5"`.

<a id="nestedblock--cluster_profile--pack"></a>
### Nested Schema for `cluster_profile.pack`
Expand Down
1 change: 1 addition & 0 deletions docs/resources/cluster_eks.md
Original file line number Diff line number Diff line change
Expand Up @@ -234,6 +234,7 @@ Required:
Optional:

- `pack` (Block List) For packs of type `spectro`, `helm`, and `manifest`, at least one pack must be specified. (see [below for nested schema](#nestedblock--cluster_profile--pack))
- `variables` (Map of String) A map of cluster profile variables, specified as key-value pairs. For example: `priority = "5"`.

<a id="nestedblock--cluster_profile--pack"></a>
### Nested Schema for `cluster_profile.pack`
Expand Down
1 change: 1 addition & 0 deletions docs/resources/cluster_gcp.md
Original file line number Diff line number Diff line change
Expand Up @@ -204,6 +204,7 @@ Required:
Optional:

- `pack` (Block List) For packs of type `spectro`, `helm`, and `manifest`, at least one pack must be specified. (see [below for nested schema](#nestedblock--cluster_profile--pack))
- `variables` (Map of String) A map of cluster profile variables, specified as key-value pairs. For example: `priority = "5"`.

<a id="nestedblock--cluster_profile--pack"></a>
### Nested Schema for `cluster_profile.pack`
Expand Down
1 change: 1 addition & 0 deletions docs/resources/cluster_gke.md
Original file line number Diff line number Diff line change
Expand Up @@ -185,6 +185,7 @@ Required:
Optional:

- `pack` (Block List) For packs of type `spectro`, `helm`, and `manifest`, at least one pack must be specified. (see [below for nested schema](#nestedblock--cluster_profile--pack))
- `variables` (Map of String) A map of cluster profile variables, specified as key-value pairs. For example: `priority = "5"`.

<a id="nestedblock--cluster_profile--pack"></a>
### Nested Schema for `cluster_profile.pack`
Expand Down
1 change: 1 addition & 0 deletions docs/resources/cluster_group.md
Original file line number Diff line number Diff line change
Expand Up @@ -86,6 +86,7 @@ Required:
Optional:

- `pack` (Block List) For packs of type `spectro`, `helm`, and `manifest`, at least one pack must be specified. (see [below for nested schema](#nestedblock--cluster_profile--pack))
- `variables` (Map of String) A map of cluster profile variables, specified as key-value pairs. For example: `priority = "5"`.

<a id="nestedblock--cluster_profile--pack"></a>
### Nested Schema for `cluster_profile.pack`
Expand Down
1 change: 1 addition & 0 deletions docs/resources/cluster_import.md
Original file line number Diff line number Diff line change
Expand Up @@ -86,6 +86,7 @@ Required:
Optional:

- `pack` (Block List) For packs of type `spectro`, `helm`, and `manifest`, at least one pack must be specified. (see [below for nested schema](#nestedblock--cluster_profile--pack))
- `variables` (Map of String) A map of cluster profile variables, specified as key-value pairs. For example: `priority = "5"`.

<a id="nestedblock--cluster_profile--pack"></a>
### Nested Schema for `cluster_profile.pack`
Expand Down
1 change: 1 addition & 0 deletions docs/resources/cluster_maas.md
Original file line number Diff line number Diff line change
Expand Up @@ -251,6 +251,7 @@ Required:
Optional:

- `pack` (Block List) For packs of type `spectro`, `helm`, and `manifest`, at least one pack must be specified. (see [below for nested schema](#nestedblock--cluster_profile--pack))
- `variables` (Map of String) A map of cluster profile variables, specified as key-value pairs. For example: `priority = "5"`.

<a id="nestedblock--cluster_profile--pack"></a>
### Nested Schema for `cluster_profile.pack`
Expand Down
1 change: 1 addition & 0 deletions docs/resources/cluster_openstack.md
Original file line number Diff line number Diff line change
Expand Up @@ -209,6 +209,7 @@ Required:
Optional:

- `pack` (Block List) For packs of type `spectro`, `helm`, and `manifest`, at least one pack must be specified. (see [below for nested schema](#nestedblock--cluster_profile--pack))
- `variables` (Map of String) A map of cluster profile variables, specified as key-value pairs. For example: `priority = "5"`.

<a id="nestedblock--cluster_profile--pack"></a>
### Nested Schema for `cluster_profile.pack`
Expand Down
1 change: 1 addition & 0 deletions docs/resources/cluster_tke.md
Original file line number Diff line number Diff line change
Expand Up @@ -141,6 +141,7 @@ Required:
Optional:

- `pack` (Block List) For packs of type `spectro`, `helm`, and `manifest`, at least one pack must be specified. (see [below for nested schema](#nestedblock--cluster_profile--pack))
- `variables` (Map of String) A map of cluster profile variables, specified as key-value pairs. For example: `priority = "5"`.

<a id="nestedblock--cluster_profile--pack"></a>
### Nested Schema for `cluster_profile.pack`
Expand Down
1 change: 1 addition & 0 deletions docs/resources/cluster_vsphere.md
Original file line number Diff line number Diff line change
Expand Up @@ -175,6 +175,7 @@ Required:
Optional:

- `pack` (Block List) For packs of type `spectro`, `helm`, and `manifest`, at least one pack must be specified. (see [below for nested schema](#nestedblock--cluster_profile--pack))
- `variables` (Map of String) A map of cluster profile variables, specified as key-value pairs. For example: `priority = "5"`.

<a id="nestedblock--cluster_profile--pack"></a>
### Nested Schema for `cluster_profile.pack`
Expand Down
1 change: 1 addition & 0 deletions docs/resources/virtual_cluster.md
Original file line number Diff line number Diff line change
Expand Up @@ -127,6 +127,7 @@ Required:
Optional:

- `pack` (Block List) For packs of type `spectro`, `helm`, and `manifest`, at least one pack must be specified. (see [below for nested schema](#nestedblock--cluster_profile--pack))
- `variables` (Map of String) A map of cluster profile variables, specified as key-value pairs. For example: `priority = "5"`.

<a id="nestedblock--cluster_profile--pack"></a>
### Nested Schema for `cluster_profile.pack`
Expand Down
5 changes: 5 additions & 0 deletions examples/resources/spectrocloud_cluster_aws/resource.tf
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,11 @@ resource "spectrocloud_cluster_aws" "cluster" {
cluster_profile {
id = data.spectrocloud_cluster_profile.profile.id

variables = {
"priority" = "5",
"default_cmd" = "pwd"
}

# To override or specify values for a cluster:

# pack {
Expand Down
25 changes: 13 additions & 12 deletions go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,8 @@ require (
github.com/robfig/cron v1.2.0
github.com/spectrocloud/gomi v1.14.1-0.20240214074114-c19394812368
github.com/spectrocloud/hapi v1.14.1-0.20240214071352-81f589b1d86d
github.com/spectrocloud/palette-sdk-go v0.0.0-20241119151816-43a4f46d482e
github.com/stretchr/testify v1.9.0
github.com/spectrocloud/palette-sdk-go v0.0.0-20241219153631-ca32d3fd7126
github.com/stretchr/testify v1.10.0
gotest.tools v2.2.0+incompatible
k8s.io/api v0.23.5
k8s.io/apimachinery v0.23.5
Expand Down Expand Up @@ -72,7 +72,7 @@ require (
github.com/imdario/mergo v0.3.15 // indirect
github.com/josharian/intern v1.0.0 // indirect
github.com/json-iterator/go v1.1.12 // indirect
github.com/mailru/easyjson v0.7.7 // indirect
github.com/mailru/easyjson v0.9.0 // indirect
github.com/mattn/go-colorable v0.1.13 // indirect
github.com/mattn/go-isatty v0.0.16 // indirect
github.com/mitchellh/cli v1.1.5 // indirect
Expand Down Expand Up @@ -100,17 +100,18 @@ require (
github.com/vmihailenco/msgpack/v5 v5.3.5 // indirect
github.com/vmihailenco/tagparser/v2 v2.0.0 // indirect
github.com/zclconf/go-cty v1.14.1 // indirect
go.mongodb.org/mongo-driver v1.16.0 // indirect
go.opentelemetry.io/otel v1.28.0 // indirect
go.opentelemetry.io/otel/metric v1.28.0 // indirect
go.opentelemetry.io/otel/trace v1.28.0 // indirect
golang.org/x/crypto v0.22.0 // indirect
go.mongodb.org/mongo-driver v1.17.1 // indirect
go.opentelemetry.io/auto/sdk v1.1.0 // indirect
go.opentelemetry.io/otel v1.33.0 // indirect
go.opentelemetry.io/otel/metric v1.33.0 // indirect
go.opentelemetry.io/otel/trace v1.33.0 // indirect
golang.org/x/crypto v0.26.0 // indirect
golang.org/x/exp v0.0.0-20230626212559-97b1e661b5df // indirect
golang.org/x/mod v0.13.0 // indirect
golang.org/x/mod v0.17.0 // indirect
golang.org/x/net v0.21.0 // indirect
golang.org/x/sync v0.7.0 // indirect
golang.org/x/sys v0.22.0 // indirect
golang.org/x/text v0.14.0 // indirect
golang.org/x/sync v0.10.0 // indirect
golang.org/x/sys v0.28.0 // indirect
golang.org/x/text v0.17.0 // indirect
google.golang.org/appengine v1.6.7 // indirect
google.golang.org/genproto/googleapis/rpc v0.0.0-20230525234030-28d5490b6b19 // indirect
google.golang.org/grpc v1.57.1 // indirect
Expand Down
Loading
Loading