Spectro Cloud module is a container for all Palette resources that are used together. You can use modules to create lightweight abstractions, using yaml files translated into Terraform.
This repository serves as a demonstration for utilizing the SpectroCloud Terraform Provider to create resources using YAML as a source. SpectroCloud does not actively maintain or provide modules support for all active Spectrocloud Terraform Provider releases/features.
This repository can be forked and customized to meet your specific requirements.
Create yaml files such as: cluster.yaml
, profile.yaml
, main.tf
and others describing the cloud resources and module configuration. More examples could be found here.
- EKS
- AKS
- VMware
- Edge
- cloud accounts for supported cloud types
- alerts
- cluster profiles
- addon deployments
- appliances
- backup storage locations
- registries
- projects
- teams
- macros
- application profiles
1. Users can provision multiple resources from different modules and define and set as many parameters as required with unique names (duplicate names are not recommended).
module "SpectroAcc" { accounts = { for k in fileset("config/account", "account-*.yaml") : trimsuffix(k, ".yaml") => yamldecode(templatefile("config/account/${k}", local.accounts_params)) } } module "SpectroOrg" { profiles = { for k in fileset("config/profile", "profile-*.yaml") : trimsuffix(k, ".yaml") => yamldecode(templatefile("config/profile/${k}", local.profile_params)) } } module "SpectroProject" { clusters = { for k in fileset("config/cluster", "cluster-*.yaml") : trimsuffix(k, ".yaml") => yamldecode(templatefile("config/cluster/${k}", local.project_params)) }
1. Provision cloud accounts:
terraform apply -target module.SpectroAcc.spectrocloud_cloudaccount_aws.account 2. Provision profiles:
terraform apply -target module.SpectroOrg.spectrocloud_cluster_profile.profile_resource 3. Provision clusters:
terraform apply -target module.SpectroProject.spectrocloud_cluster_eks.this 4. Provision addon deployments:
terraform apply -target module.SpectroProject.spectrocloud_addon_deployment.this
1. terraform destroy -target module.SpectroProject.spectrocloud_addon_deployment.this 2. terraform destroy -target module.SpectroProject.spectrocloud_cluster_eks.this 3. terraform destroy -target module.SpectroOrg.spectrocloud_cluster_profile.profile_resource 4. terraform destroy -target module.SpectroAcc.spectrocloud_cloudaccount_aws.account
Name | Version |
---|---|
spectrocloud | ~> 0.11.0 |
Name | Version |
---|---|
spectrocloud | ~> 0.11.0 |
No modules.
Name | Description | Type | Default | Required |
---|---|---|---|---|
accounts | n/a | map(any) |
{} |
no |
alerts | n/a | any |
{} |
no |
appliances | n/a | map(any) |
{} |
no |
application_deployments | n/a | any |
{} |
no |
application_profiles | n/a | any |
{} |
no |
bsls | n/a | map(any) |
{} |
no |
cluster_groups | n/a | any |
{} |
no |
cluster_profile_imports | n/a | list(string) |
[] |
no |
cluster_profile_imports_context | n/a | string |
"project" |
no |
clusters | n/a | map |
{} |
no |
macros | n/a | map(any) |
{} |
no |
profiles | n/a | map |
{} |
no |
projects | n/a | map(any) |
{} |
no |
registries | n/a | map(any) |
{} |
no |
teams | n/a | map(any) |
{} |
no |
virtual_clusters | n/a | any |
{} |
no |
Name | Description |
---|---|
debug | n/a |
debug_addon_pack_manifests | n/a |
debug_aws_accounts | n/a |
debug_cluster_infra_profiles_map | n/a |
debug_cluster_profile_pack_map | not addon specific |
debug_cluster_system_profiles_map | n/a |
debug_libvirt_system | n/a |
debug_system_pack_manifests | n/a |