Skip to content

Commit

Permalink
pre-commit documentation updates
Browse files Browse the repository at this point in the history
  • Loading branch information
scotttyso committed Jul 27, 2021
1 parent f1cae05 commit 5fd3a96
Show file tree
Hide file tree
Showing 5 changed files with 60 additions and 226 deletions.
26 changes: 13 additions & 13 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -55,27 +55,27 @@

### Execute Plans in Terraform Cloud Workspaces

1. Open the Workspace "{cluster_name}_global_vars" in TFCB and queue a plan manually. This will populate the global variables that will be used by the other TFCB workspaces.
1. Open the Workspace "{organization}" in TFCB and queue a plan manually. This will Create the Organization Poliices and add outputs to be consumed by the next module {organization}_{cluster_name}.

2. You will execute the Runs in the workspaces in this order:

* {cluster_name}_iks - See section below on "Provision IKS Policies and IP Pools with TFCB"
* {organization}_{cluster_name} - See section below on "Provision IKS Cluster and IP Pools with TFCB"

* {cluster_name}_kube - See section below on "Provision a IKS Cluster with TFCB"
* {organization}_{cluster_name}_kube - See section below on "Provision a IKS Cluster with TFCB"

* {cluster_name}_iwo - See section below on "Deploy IWO collector using Helm"
* {organization}_{cluster_name}_iwo - See section below on "Deploy IWO collector using Helm"

* {cluster_name}_app_hello - See section below on "Deploy a sample "Hello IKS" App using Helm"
* {organization}_{cluster_name}_app_hello - See section below on "Deploy a sample "Hello IKS" App using Helm"

### Provision IP Pools, Kubernetes Policies, and an IKS Cluster with TFCB
### Provision Intersight Kubernetes Service Cluster with TFCB

![alt text](https://github.com/prathjan/images/blob/main/prof.png?raw=true)

### Get the Cluster kube_config

Currently due to order of operations in Intersight you must use a seperate task after Cluster creation to download the kube_config. the {cluster_name}_kube Workspace will be used to accomplish this.
Currently due to order of operations in Intersight you must use a seperate task after Cluster creation to download the kube_config. the {organization}_{cluster_name}_kube Workspace will be used to accomplish this.

Once you have confirmed in Intersight that the cluster has been fully provisioned run the plan in the {cluster_name}_kube workspace.
Once you have confirmed in Intersight that the cluster has been fully provisioned run the plan in the {organization}_{cluster_name}_kube workspace.

Download the cluster kube_config from from the workspace and run a couple of kubectl commands to verify an operational cluster:

Expand All @@ -87,13 +87,13 @@ Download the cluster kube_config from from the workspace and run a couple of kub

If you don't have Intersight Workload Optimizer licensing tied to your Intersight Instance you can skip this section.

As a Cloud Admin it is imperative to be able to have insights into the infrastructure. The workspace "{cluster_name}_iwo" provides an example helm chart provisioning process to add the iwo collector pod to the deployed cluster.
As a Cloud Admin it is imperative to be able to have insights into the infrastructure. The workspace "{organization}_{cluster_name}_iwo" provides an example helm chart provisioning process to add the iwo collector pod to the deployed cluster.

Open "{cluster_name}_iwo" and Queue a plan manually.
Open "{organization}_{cluster_name}_iwo" and Queue a plan manually.

Once successful, the collector is installed into your Kubernetes cluster and requires you to claim it as target in Intersight->Target. You will use the following steps to get the Device ID and Code:

Download kube_config for the {cluster_name} from Intersight or your {cluster_name}_kube workspace.
Download kube_config for the {organization}_{cluster_name} from Intersight or your {organization}_{cluster_name}_kube workspace.

Execute:

Expand All @@ -115,9 +115,9 @@ Note: This can take approximately 30 minutes to begin to see the cluster in IWO.

### Deploy the sample "Hello IKS" App using Helm

What use is a cluster without an Application? The workspace "{cluster_name}_app_hello" accounts for this.
What use is a cluster without an Application? The workspace "{organization}_{cluster_name}_app_hello" accounts for this.

Open "{cluster_name}_app_hello" and Queue a plan manually.
Open "{organization}_{cluster_name}_app_hello" and Queue a plan manually.

Once successful, access the app with the loadbalancer IP:

Expand Down
52 changes: 8 additions & 44 deletions modules/iks/README.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# IKS Policies and Cluster Profile Module
# Intersight Kubernetes Service Cluster Profile Module

## Use this module to create Kubernetes policies and an IKS Cluster profile in Intersight

Expand All @@ -15,82 +15,46 @@ Run the plan from the Terraform cloud workspace.

| Name | Version |
|------|---------|
| <a name="provider_intersight"></a> [intersight](#provider\_intersight) | 1.0.11 |
| <a name="provider_terraform"></a> [terraform](#provider\_terraform) | n/a |

## Modules

| Name | Source | Version |
|------|--------|---------|
| <a name="module_control_plane_node_group"></a> [control\_plane\_node\_group](#module\_control\_plane\_node\_group) | terraform-cisco-modules/imm/intersight//modules/k8s_node_group_profile | n/a |
| <a name="module_control_plane_vm_infra_provider"></a> [control\_plane\_vm\_infra\_provider](#module\_control\_plane\_vm\_infra\_provider) | terraform-cisco-modules/imm/intersight//modules/k8s_vm_infra_provider | n/a |
| <a name="module_control_plane_vm_infra_provider"></a> [control\_plane\_vm\_infra\_provider](#module\_control\_plane\_vm\_infra\_provider) | terraform-cisco-modules/imm/intersight//modules/k8s_node_vm_infra_provider | n/a |
| <a name="module_iks_cluster"></a> [iks\_cluster](#module\_iks\_cluster) | terraform-cisco-modules/imm/intersight//modules/k8s_cluster | n/a |
| <a name="module_ip_pools"></a> [ip\_pools](#module\_ip\_pools) | terraform-cisco-modules/imm/intersight//modules/pools_ip | n/a |
| <a name="module_k8s_addon_policies"></a> [k8s\_addon\_policies](#module\_k8s\_addon\_policies) | terraform-cisco-modules/imm/intersight//modules/policies_k8s_addons | n/a |
| <a name="module_k8s_network_cidr"></a> [k8s\_network\_cidr](#module\_k8s\_network\_cidr) | terraform-cisco-modules/imm/intersight//modules/policies_k8s_network_cidr | n/a |
| <a name="module_k8s_nodeos_config"></a> [k8s\_nodeos\_config](#module\_k8s\_nodeos\_config) | terraform-cisco-modules/imm/intersight//modules/policies_k8s_nodeos_config | n/a |
| <a name="module_k8s_runtime_policies"></a> [k8s\_runtime\_policies](#module\_k8s\_runtime\_policies) | terraform-cisco-modules/imm/intersight//modules/policies_k8s_runtime | n/a |
| <a name="module_k8s_trusted_registries"></a> [k8s\_trusted\_registries](#module\_k8s\_trusted\_registries) | terraform-cisco-modules/imm/intersight//modules/k8s_trusted_registries | n/a |
| <a name="module_k8s_version_policies"></a> [k8s\_version\_policies](#module\_k8s\_version\_policies) | terraform-cisco-modules/imm/intersight//modules/policies_k8s_version | n/a |
| <a name="module_k8s_vm_infra_config"></a> [k8s\_vm\_infra\_config](#module\_k8s\_vm\_infra\_config) | terraform-cisco-modules/imm/intersight//modules/policies_k8s_vm_infra | n/a |
| <a name="module_k8s_vm_instance_type"></a> [k8s\_vm\_instance\_type](#module\_k8s\_vm\_instance\_type) | terraform-cisco-modules/imm/intersight//modules/policies_k8s_vm_instance_type | n/a |
| <a name="module_worker_node_group"></a> [worker\_node\_group](#module\_worker\_node\_group) | terraform-cisco-modules/imm/intersight//modules/k8s_node_group_profile | n/a |
| <a name="module_worker_vm_infra_provider"></a> [worker\_vm\_infra\_provider](#module\_worker\_vm\_infra\_provider) | terraform-cisco-modules/imm/intersight//modules/k8s_vm_infra_provider | n/a |
| <a name="module_worker_vm_infra_provider"></a> [worker\_vm\_infra\_provider](#module\_worker\_vm\_infra\_provider) | terraform-cisco-modules/imm/intersight//modules/k8s_node_vm_infra_provider | n/a |

## Resources

| Name | Type |
|------|------|
| [intersight_organization_organization.org_moid](https://registry.terraform.io/providers/CiscoDevNet/intersight/1.0.11/docs/data-sources/organization_organization) | data source |
| [intersight_organization_organization.organization_moid](https://registry.terraform.io/providers/CiscoDevNet/intersight/1.0.11/docs/data-sources/organization_organization) | data source |
| [terraform_remote_state.organization](https://registry.terraform.io/providers/hashicorp/terraform/latest/docs/data-sources/remote_state) | data source |

## Inputs

| Name | Description | Type | Default | Required |
|------|-------------|------|---------|:--------:|
| <a name="input_apikey"></a> [apikey](#input\_apikey) | Intersight API Key. | `string` | n/a | yes |
| <a name="input_endpoint"></a> [endpoint](#input\_endpoint) | Intersight URL. | `string` | `"https://intersight.com"` | no |
| <a name="input_iks_cluster"></a> [iks\_cluster](#input\_iks\_cluster) | Please Refer to the k8s\_version variable information in the tfe module. In the IKS module the variable is accepted as a string from terraform cloud in the terraform.auto.tfvars and extracted using locals. | `string` | n/a | yes |
| <a name="input_ip_pools"></a> [ip\_pools](#input\_ip\_pools) | Please Refer to the ip\_pools variable information in the tfe module. In the IKS module the variable is accepted as a string from terraform cloud in the terraform.auto.tfvars and extracted using locals. | `string` | n/a | yes |
| <a name="input_k8s_addon_policies"></a> [k8s\_addon\_policies](#input\_k8s\_addon\_policies) | Please Refer to the k8s\_addons variable information in the tfe module. In the IKS module the variable is accepted as a string from terraform cloud in the terraform.auto.tfvars and extracted using locals. | `string` | n/a | yes |
| <a name="input_k8s_network_cidr"></a> [k8s\_network\_cidr](#input\_k8s\_network\_cidr) | Please Refer to the k8s\_network\_cidr variable information in the tfe module. In the IKS module the variable is accepted as a string from terraform cloud in the terraform.auto.tfvars and extracted using locals. | `string` | n/a | yes |
| <a name="input_k8s_nodeos_config"></a> [k8s\_nodeos\_config](#input\_k8s\_nodeos\_config) | Please Refer to the k8s\_nodeos\_config variable information in the tfe module. In the IKS module the variable is accepted as a string from terraform cloud in the terraform.auto.tfvars and extracted using locals. | `string` | n/a | yes |
| <a name="input_k8s_runtime_create"></a> [k8s\_runtime\_create](#input\_k8s\_runtime\_create) | Flag to specify if the Kubernetes Runtime Policy should be created or not. | `bool` | `false` | no |
| <a name="input_k8s_runtime_http_password"></a> [k8s\_runtime\_http\_password](#input\_k8s\_runtime\_http\_password) | Password for the HTTP Proxy Server, If required. | `string` | `""` | no |
| <a name="input_k8s_runtime_https_password"></a> [k8s\_runtime\_https\_password](#input\_k8s\_runtime\_https\_password) | Password for the HTTPS Proxy Server, If required. | `string` | `""` | no |
| <a name="input_k8s_runtime_policies"></a> [k8s\_runtime\_policies](#input\_k8s\_runtime\_policies) | Please Refer to the k8s\_runtime\_policies variable information in the tfe module. In the IKS module the variable is accepted as a string from terraform cloud in the terraform.auto.tfvars and extracted using locals. | `string` | n/a | yes |
| <a name="input_k8s_trusted_create"></a> [k8s\_trusted\_create](#input\_k8s\_trusted\_create) | Flag to specify if the Kubernetes Runtime Policy should be created or not. | `bool` | `false` | no |
| <a name="input_k8s_trusted_registries"></a> [k8s\_trusted\_registries](#input\_k8s\_trusted\_registries) | Please Refer to the k8s\_trusted\_registries variable information in the tfe module. In the IKS module the variable is accepted as a string from terraform cloud in the terraform.auto.tfvars and extracted using locals. | `string` | n/a | yes |
| <a name="input_k8s_version_policies"></a> [k8s\_version\_policies](#input\_k8s\_version\_policies) | Please Refer to the k8s\_version\_policies variable information in the tfe module. In the IKS module the variable is accepted as a string from terraform cloud in the terraform.auto.tfvars and extracted using locals. | `string` | n/a | yes |
| <a name="input_k8s_vm_infra_config"></a> [k8s\_vm\_infra\_config](#input\_k8s\_vm\_infra\_config) | Please Refer to the k8s\_vm\_infra\_config variable information in the tfe module. In the IKS module the variable is accepted as a string from terraform cloud in the terraform.auto.tfvars and extracted using locals. | `string` | n/a | yes |
| <a name="input_k8s_vm_infra_password"></a> [k8s\_vm\_infra\_password](#input\_k8s\_vm\_infra\_password) | vSphere Password. Note: this is the password of the Credentials used to register the vSphere Target. | `string` | n/a | yes |
| <a name="input_k8s_vm_instance_type"></a> [k8s\_vm\_instance\_type](#input\_k8s\_vm\_instance\_type) | Please Refer to the k8s\_vm\_instance\_type variable information in the tfe module. In the IKS module the variable is accepted as a string from terraform cloud in the terraform.auto.tfvars and extracted using locals. | `string` | n/a | yes |
| <a name="input_organization"></a> [organization](#input\_organization) | Intersight Organization. | `string` | `"default"` | no |
| <a name="input_iks_cluster"></a> [iks\_cluster](#input\_iks\_cluster) | Please Refer to the iks\_cluster variable information in the tfe module. In the iks module the variable is accepted as a string from terraform cloud in the terraform.auto.tfvars and extracted using locals. | `string` | n/a | yes |
| <a name="input_organization"></a> [organization](#input\_organization) | Intersight Organization Name/Workspace. | `string` | `"default"` | no |
| <a name="input_secretkey"></a> [secretkey](#input\_secretkey) | Intersight Secret Key. | `string` | n/a | yes |
| <a name="input_ssh_key_1"></a> [ssh\_key\_1](#input\_ssh\_key\_1) | Intersight Kubernetes Service Cluster SSH Public Key 1. | `string` | `""` | no |
| <a name="input_ssh_key_2"></a> [ssh\_key\_2](#input\_ssh\_key\_2) | Intersight Kubernetes Service Cluster SSH Public Key 2. These are place holders for Tenants that use different keys for different clusters. | `string` | `""` | no |
| <a name="input_ssh_key_3"></a> [ssh\_key\_3](#input\_ssh\_key\_3) | Intersight Kubernetes Service Cluster SSH Public Key 3. These are place holders for Tenants that use different keys for different clusters. | `string` | `""` | no |
| <a name="input_ssh_key_4"></a> [ssh\_key\_4](#input\_ssh\_key\_4) | Intersight Kubernetes Service Cluster SSH Public Key 4. These are place holders for Tenants that use different keys for different clusters. | `string` | `""` | no |
| <a name="input_ssh_key_5"></a> [ssh\_key\_5](#input\_ssh\_key\_5) | Intersight Kubernetes Service Cluster SSH Public Key 5. These are place holders for Tenants that use different keys for different clusters. | `string` | `""` | no |
| <a name="input_tags"></a> [tags](#input\_tags) | Please Refer to the tags variable information in the tfe module. In the IKS module the variable is accepted as a string from terraform cloud in the terraform.auto.tfvars and extracted using locals. | `string` | n/a | yes |
| <a name="input_tenant_name"></a> [tenant\_name](#input\_tenant\_name) | Name of the Tenant. | `string` | `"default"` | no |
| <a name="input_tfc_organization"></a> [tfc\_organization](#input\_tfc\_organization) | Terraform Cloud Organization Name. | `string` | n/a | yes |

## Outputs

| Name | Description |
|------|-------------|
| <a name="output_endpoint"></a> [endpoint](#output\_endpoint) | Intersight URL. |
| <a name="output_iks_cluster"></a> [iks\_cluster](#output\_iks\_cluster) | moid of the IKS Cluster. |
| <a name="output_ip_pools"></a> [ip\_pools](#output\_ip\_pools) | moid of the IP Pool |
| <a name="output_k8s_addon_policies"></a> [k8s\_addon\_policies](#output\_k8s\_addon\_policies) | moid of the Kubernetes CIDR Policies. |
| <a name="output_k8s_network_cidr"></a> [k8s\_network\_cidr](#output\_k8s\_network\_cidr) | moid of the Kubernetes CIDR Policies. |
| <a name="output_k8s_nodeos_config"></a> [k8s\_nodeos\_config](#output\_k8s\_nodeos\_config) | moid of the Kubernetes Node OS Config Policies. |
| <a name="output_k8s_runtime_policies"></a> [k8s\_runtime\_policies](#output\_k8s\_runtime\_policies) | moid of the Kubernetes Runtime Policies. |
| <a name="output_k8s_trusted_registries"></a> [k8s\_trusted\_registries](#output\_k8s\_trusted\_registries) | moid of the Kubernetes Trusted Registry Policy. |
| <a name="output_k8s_version_policies"></a> [k8s\_version\_policies](#output\_k8s\_version\_policies) | moid of the Kubernetes Version Policies. |
| <a name="output_k8s_vm_infra_config"></a> [k8s\_vm\_infra\_config](#output\_k8s\_vm\_infra\_config) | moid of the Kubernetes VM Infrastructure Configuration Policies. |
| <a name="output_k8s_vm_instance_type"></a> [k8s\_vm\_instance\_type](#output\_k8s\_vm\_instance\_type) | moid of the Large Kubernetes Instance Type Policies. |
| <a name="output_org_moid"></a> [org\_moid](#output\_org\_moid) | moid of the Intersight Organization. |
| <a name="output_organization"></a> [organization](#output\_organization) | Intersight Organization Name. |
| <a name="output_tags"></a> [tags](#output\_tags) | Tags to be Associated with Objects Created in Intersight. |
| <a name="output_tenant_name"></a> [tenant\_name](#output\_tenant\_name) | Name of the Tenant. |
<!-- END OF PRE-COMMIT-TERRAFORM DOCS HOOK -->
Loading

0 comments on commit 5fd3a96

Please sign in to comment.