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

Main review mods 2023 12 06 #55

Open
wants to merge 151 commits into
base: main-review-2023-11-17
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from 147 commits
Commits
Show all changes
151 commits
Select commit Hold shift + click to select a range
afe0783
branch:HPCC-27615-original-folder-structure. Constructed the original…
Sep 21, 2023
5a51f03
branch:HPCC-27615-fixes-deploy-without-external-storage. Now can depl…
Sep 21, 2023
35b1a43
branch:HPCC-27615-my-local-has-flat-structure
Sep 21, 2023
f31f1c7
branch:HPCC-27615-easy-deploy. Get is a merge of HPCC-27615 latest an…
Sep 22, 2023
c11ef09
branch: HPCC-27615-easy-deploy. This is a merge of HPCC-27615 and bra…
Sep 22, 2023
977e107
branch:new-variable-enable_thor. Now one must set 'enable_thor=true' …
Sep 26, 2023
1b54ae7
branch:fix-roxie-so-port-18002-is-used
Sep 27, 2023
eba6f63
branch:add-htpasswd-support
Sep 28, 2023
58268fa
branch:add-ecl-code-security. Plus, , setup 'storage_data_lz'
Oct 4, 2023
fbafd5d
branch:add-ecl-code-security
Oct 4, 2023
32b918b
Merge pull request #1 from tlhumphrey2/add-ecl-code-security
Oct 5, 2023
226139f
branch:add-terraform-to-deploy-everything
Oct 6, 2023
982e692
Merge pull request #2 from tlhumphrey2/add-terraform-to-deploy-everyt…
Oct 6, 2023
347ceef
branch:add-terraform-to-deploy-everything
Oct 9, 2023
1e0e18f
Merge pull request #3 from tlhumphrey2/add-terraform-to-deploy-everyt…
Oct 9, 2023
e5f5853
branch:aks-is-now-using-easy-deploy-variables
Oct 12, 2023
9f93f16
Merge pull request #4 from tlhumphrey2/aks-is-now-using-easy-deploy-v…
Oct 12, 2023
7fb2c89
branch:aks-is-now-using-easy-deploy-variables
Oct 12, 2023
cde9f4f
Merge pull request #5 from tlhumphrey2/aks-is-now-using-easy-deploy-v…
Oct 12, 2023
0f56039
branch:aks-is-now-using-easy-deploy-variables. Changed scripts/deploy…
Oct 13, 2023
1bf7dc9
Merge pull request #6 from tlhumphrey2/aks-is-now-using-easy-deploy-v…
Oct 13, 2023
e14e9eb
branch:aks-is-now-using-easy-deploy-variables
Oct 17, 2023
3de0cc1
Merge pull request #7 from tlhumphrey2/aks-is-now-using-easy-deploy-v…
Oct 17, 2023
dbe5cef
branch:aks-is-now-using-easy-deploy-variables
Oct 18, 2023
ff58b6d
Merge pull request #8 from tlhumphrey2/aks-is-now-using-easy-deploy-v…
Oct 18, 2023
2203f42
branch:few-changes-20231020
Oct 20, 2023
71434db
Merge pull request #9 from tlhumphrey2/few-changes-20231020
Oct 20, 2023
c54dad8
branch:HPCC-27615-easy-deploy-bryan1
Oct 28, 2023
f077f15
branch:HPCC-27615-easy-deploy-bryan1-w-oss
Oct 28, 2023
1868452
branch:HPCC-27615-easy-deploy-bryan1-w-oss-zones
Oct 28, 2023
1523b64
branch:HPCC-27615-easy-deploy-bryan1-w-oss-zones. Now can optionally …
Oct 30, 2023
8e0e2f1
branch:HPCC-27615-easy-deploy-bryan1-w-oss-zones. Now can optionally …
Oct 30, 2023
d2ee650
branch: HPCC-27615-easy-deploy-bryan1-w-oss-zones
Oct 30, 2023
873a9f7
branch:HPCC-27615-easy-deploy-bryan1-w-oss-zones. merged with github …
Oct 30, 2023
50f7050
branch:HPCC-27615-easy-deploy-bryan2-root-sto-applied-initials-added.…
Oct 31, 2023
108641a
branch:HPCC-27615-easy-deploy-bryan2-root-sto-applied-initials-added.…
Oct 31, 2023
19e114a
branch:HPCC-27615-easy-deploy-bryan2-root-sto-applied-initials-added2
Nov 1, 2023
5e3a1ec
branch:HPCC-27615-easy-deploy-bryan3-roxiepool-optional
Nov 1, 2023
7065e89
branch:HPCC-27615-easy-deploy-bryan4-placing-auto.tfvars-files-aks-st…
Nov 2, 2023
ad678e4
branch:HPCC-27615-easy-deploy-bryan4-placing-auto.tfvars-files-aks-st…
Nov 2, 2023
aca0ced
branch:HPCC-27615-easy-deploy-bryan4-placing-auto.tfvars-files-aks-st…
Nov 2, 2023
1c346ee
branch:HPCC-27615-easy-deploy-bryan4-placing-auto.tfvars-files-aks-st…
Nov 2, 2023
e796355
branch:HPCC-27615-easy-deploy-bryan5-miscellaneous-changes
Nov 4, 2023
3588eec
branch:HPCC-27615-easy-deploy-bryan5-miscellaneous-changes. Added doc…
Nov 5, 2023
8ec2aab
branch:HPCC-27615-easy-deploy-bryan5-miscellaneous-changes. Updated d…
Nov 5, 2023
498d908
branch:HPCC-27615-easy-deploy-bryan6-restrict-hpcc-access
Nov 6, 2023
81afffd
branch:HPCC-27615-easy-deploy-bryan6-restrict-hpcc-access. Updated us…
Nov 6, 2023
902ec17
branch:HPCC-27615-easy-deploy-bryan6-restrict-hpcc-access. Updating U…
Nov 6, 2023
682612e
branch:HPCC-27615-easy-deploy-bryan6-restrict-hpcc-access. Updated Us…
Nov 6, 2023
2417b9a
branch:HPCC-27615-easy-deploy-bryan7-developers-documentation
Nov 7, 2023
d8aa06c
branch:HPCC-27615-easy-deploy-bryan7-developers-documentation
Nov 7, 2023
bf1a64d
branch:HPCC-27615-easy-deploy-bryan7-developers-documentation
Nov 7, 2023
41be7fa
branch:HPCC-27615-easy-deploy-bryan7-developers-documentation
Nov 7, 2023
02fe05b
branch:HPCC-27615-easy-deploy-bryan7-developers-documentation. Update…
Nov 7, 2023
5bc6502
branch:HPCC-27615-easy-deploy-bryan7-developers-documentation. Update…
Nov 7, 2023
a8a8170
branch:HPCC-27615-easy-deploy-bryan7-developers-documentation. Update…
Nov 7, 2023
882a390
branch:HPCC-27615-easy-deploy-bryan7-developers-documentation. Update…
Nov 7, 2023
345453e
branch:HPCC-27615-easy-deploy-bryan7-developers-documentation. Update…
Nov 7, 2023
986595a
branch:HPCC-27615-easy-deploy-bryan8-cleanup-and-make-clearer
Nov 9, 2023
746eb3e
Merge pull request #36 from hpccsystems-solutions-lab/HPCC-27615-easy…
tlhumphrey2 Nov 9, 2023
fc879fe
branch:HPCC-27615-easy-deploy-bryan8-pods-assigned-nodepools
Nov 9, 2023
6ffcf2d
Merge pull request #37 from hpccsystems-solutions-lab/HPCC-27615-easy…
tlhumphrey2 Nov 9, 2023
9f522e2
branch:HPCC-27615-easy-deploy-bryan8-pods-assigned-nodepools. hpcc.tf…
Nov 10, 2023
409e1a5
Merge pull request #38 from hpccsystems-solutions-lab/HPCC-27615-easy…
tlhumphrey2 Nov 10, 2023
ba53432
branch:no-ephemeral-storage-when-external-used
Nov 10, 2023
dc46a6f
Merge pull request #39 from hpccsystems-solutions-lab/no-ephemeral-st…
tlhumphrey2 Nov 10, 2023
cf68e81
branch:no-ephemeral-storage-when-external-used. Fixed paths in script…
Nov 10, 2023
d7ea956
Merge pull request #40 from hpccsystems-solutions-lab/no-ephemeral-st…
tlhumphrey2 Nov 10, 2023
31396de
branch:HPCC-27615-easy-deploy-bryan7-developers-documentation. Update…
Nov 12, 2023
d42c883
Merge pull request #41 from hpccsystems-solutions-lab/HPCC-27615-easy…
tlhumphrey2 Nov 12, 2023
d17572e
branch:HPCC-27615-easy-deploy-bryan9-variable-eclwatch-a-record
Nov 16, 2023
b05a798
Merge pull request #42 from hpccsystems-solutions-lab/HPCC-27615-easy…
tlhumphrey2 Nov 16, 2023
fcc5365
Update hpcc.tf
tlhumphrey2 Nov 16, 2023
a76e524
branch:HPCC-27615-easy-deploy-bryan10-added-hpcc_version
Nov 16, 2023
c175fdb
Merge pull request #43 from hpccsystems-solutions-lab/HPCC-27615-easy…
tlhumphrey2 Nov 16, 2023
1dce33d
Tims' Modifications
dcamper Nov 17, 2023
b44fbcb
branch:HPCC-27615-easy-deploy-bryan10-added-hpcc_version_and_misc. Ad…
Nov 20, 2023
4d284cb
Merge branch 'main' into HPCC-27615-easy-deploy-bryan10-added-hpcc_ve…
tlhumphrey2 Nov 20, 2023
d89b49e
Merge pull request #45 from hpccsystems-solutions-lab/HPCC-27615-easy…
tlhumphrey2 Nov 20, 2023
8747f16
Update destroy
tlhumphrey2 Nov 20, 2023
822acd9
branch:main-review-mods-2023-11-17. The easy fixes
Nov 21, 2023
73f5982
main-review-mods-2023-11-17. Resolved conflicts in scripts/destroy
Nov 21, 2023
339bf98
Merge branch 'main-review-mods-2023-11-17-tlh-changes' into main-revi…
Nov 21, 2023
4d5526d
branch:main-review-mods-2023-11-17-activate-aks_node_size
Nov 21, 2023
5d71764
Merge pull request #46 from hpccsystems-solutions-lab/main-review-mod…
tlhumphrey2 Nov 21, 2023
3aab1f8
branch:main-review-mods-2023-11-17-activate-aks_node_size
Nov 21, 2023
1518d47
Merge pull request #48 from hpccsystems-solutions-lab/main-review-mod…
tlhumphrey2 Nov 21, 2023
2a6805b
branch:main-review-mods-2023-11-17-activate-aks_node_size. aks_node_s…
Nov 22, 2023
a97cb81
Merge pull request #50 from hpccsystems-solutions-lab/main-review-mod…
tlhumphrey2 Nov 22, 2023
6809ae2
branch:main-review-mods-2023-11-17-deploy-hpcc-depends-on-storage
Nov 22, 2023
a646d62
Merge pull request #52 from hpccsystems-solutions-lab/main-review-mod…
tlhumphrey2 Nov 22, 2023
2e5e4f4
branch:main-review-mods-2023-11-17-aks_node-sizes-now-object
Nov 24, 2023
f8fa470
Merge pull request #54 from hpccsystems-solutions-lab/main-review-mod…
tlhumphrey2 Nov 24, 2023
290d023
Remove input variables not used
Dec 5, 2023
801e279
Added column 'updatable' to table of options in README.md
Dec 5, 2023
075d3aa
Removed automation.tf from aks
Dec 5, 2023
fb61631
Increased values of 'managerResources'. NOTE: Dan's 'managerResources…
Dec 5, 2023
c5d78de
Increased values of 'workerResources' to match Dan's
Dec 5, 2023
99d7fcf
Increased cpu of hthor resources to 2. This is higher than what Dan has.
Dec 5, 2023
416b4e4
Eliminated metadata variables not used
Dec 5, 2023
0274223
Removed metadata from aks, hpcc, and vnet (not in storage). Now it is…
Dec 5, 2023
bfd5142
Removed metadata from aks, hpcc, storage, and vnet (not in storage). …
Dec 5, 2023
5617f98
Removed metadata from aks, hpcc, storage, and vnet. Now it is copied …
Dec 5, 2023
6471329
Added new variable, 'aks_capacity' which defines the minimum and maxi…
Dec 6, 2023
ab72960
In lite-variables.tf, I changed the descriptions of 'aks_node_sizes' …
Dec 6, 2023
96bbe2c
In all bash scripts, replaced with
Dec 6, 2023
4d88cc9
Removed referenced branch from all source statements, since the branc…
Dec 6, 2023
91266e9
In lite-variables.tf, line 54 added '\' before each " in description.
Dec 7, 2023
f45720c
In hpcc/outputs.tf, prefixed eclwatch url with 'https://'. In lite-va…
Dec 7, 2023
3405610
In README.md, documented outpuss of hpcc, aks, vnet. There are no out…
Dec 7, 2023
6e6b6c3
Change default node size for spray pool from 2xlarge to large.
Dec 8, 2023
6ece380
Reduced the size of nodes in each node pool.
Dec 8, 2023
eae050f
Fixed value of output 'advisor_recommendations' for both aks/outputs.…
Dec 8, 2023
11554af
Calculates max capacity of thorpool. Set thor cpu and ram.
Dec 11, 2023
5c33a80
Calculates max capacity of thorpool. Set thor cpu and ram. Added to r…
Dec 12, 2023
8dd9ebf
In both hpcc/hpcc.tf and aks/aks.tf, changed source statements so val…
Dec 12, 2023
a00e254
In both hpcc/hpcc.tf and aks/aks.tf, removed prefix 'git@' from sourc…
Dec 12, 2023
9f48ece
Changed variable 'aks_node_sizes' to individual string variables: rox…
Dec 12, 2023
f4847f5
Changed 'source' in aks/aks.tf. Now it points to github repo
Dec 12, 2023
01f09ed
To redone lite-locals.tf, added workerResources cpu and memory.
Dec 13, 2023
b30f1a5
Removed commented-out code from hpcc/main.tf
Dec 13, 2023
b83083c
Removed variable 'hpcc_namespace'
Dec 13, 2023
185c760
Removed 18010 from output of eclwatch URL. Also, changed opinionated …
Dec 13, 2023
b772483
Capitalized Kubernetes everywhere in README.md
Dec 13, 2023
3eb4e6e
Deleted paragraph 'This repo is a fork of the excellent work performe…
Dec 13, 2023
76386ea
Make sure all these are capitalized in README.md when used as product…
Dec 13, 2023
4f37c43
Throughout README.md changed 'terraform' to 'terraform code'
Dec 13, 2023
85b2bef
All fixes for Dan's comments about hpcc-tf-for-developers.md are in t…
Dec 13, 2023
e6ff10c
In lite-locals.tf, deleted all terraform code that was commented-out.
Dec 13, 2023
38ef877
All fixes for all Dan's review in 1:15pm email today.
Dec 13, 2023
6e366a7
In hpcc-tf-for-developers.md, capitalizes all Azure
Dec 13, 2023
e74c3b6
Dan's review fixes in email dated 12/14/2023 7:38am
Dec 14, 2023
44cedc4
Removed azuread_group.subscription_owner from aks/aks.tf and aks/data…
Dec 15, 2023
97f7eef
Make 1 or 4 nodepools optional. Added aks_4nodepools
Dec 18, 2023
4ba65e2
Removed all error messages in 'thorpool_max_capacity' calculations an…
Dec 19, 2023
a8cef3e
Removed all occurrences of region restriction.
Dec 19, 2023
d899526
In lite-variables.tf, changed 8002 to 18002
Dec 19, 2023
2255093
In lite.auto.tfvars.example, changed 8002 to 18002
Dec 19, 2023
a5e3dc5
Removed all error messages in 'thorpool_max_capacity' calculations an…
Dec 19, 2023
abbb3bf
To metadata.tf of storage, added 'additional_tags'. Plus, removed 'de…
Dec 20, 2023
9cf1765
'workerResources' memory. Added 'G'. Caused thor container error.
Dec 27, 2023
f58b8b7
Added scripts/extract-aks-tfvars to properly extra 'aks_' variables f…
Jan 3, 2024
9cdfc88
In lite-variables.tf, no longer says REQUIRED for aks_enable_roxie.
Jan 3, 2024
81eca56
Changed workerMemory.query to same value as workerResources.memory.
Jan 3, 2024
ed598d8
Created 'aks_nodepools_max_capacity'. max_capacity of all hpcc nodepo…
Jan 4, 2024
05f46ff
Corrected 'aks_nodepools_max_capacity' code of lite-locals.tf and lit…
Jan 5, 2024
09cad2b
In README.md, minimum vCPU requirements given. In aks/locals.tf, min_…
Jan 5, 2024
4d1b78f
Added in README.md: 1) info about the directory, and what is in it, …
Jan 8, 2024
e4a8cc4
In scripts/needed-auto-tfvars-files/aks/aks.auto.tfvars.example, chan…
Jan 10, 2024
431fad0
In lite-locals.tf, increased 'helm_chart_timeout' from 300 to 600. Wh…
Jan 10, 2024
3c7c641
In README.md, said that 'jq' and 'kubelogin' are required (i.e. they …
Jan 10, 2024
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
19 changes: 10 additions & 9 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -2,34 +2,35 @@
**/.terraform/*

# .tfstate files
*.tfstate
*.tfstate.*
**/*.tfstate
**/*.tfstate.*

# Crash log files
crash.log
**/crash.log

# Ignore any .tfvars files that are generated automatically for each Terraform run. Most
# .tfvars files are managed as part of configuration and so should be included in
# version control.
#
# example.tfvars
*.tfvars
*.json
*/*.tfvars
**/*.json

# Ignore data files
**/data

# Ignore override files as they are usually used to override resources locally and so
# are not checked in
override.tf
override.tf.json
*_override.tf
*_override.tf.json
**/override.tf
**/override.tf.json
**/*_override.tf
**/*_override.tf.json

# Include override files you do wish to add to version control using negated pattern
#
# !example_override.tf
.terraform.*.hcl
**/.terraform.*.hcl

# Include tfplan files to ignore the plan output of command: terraform plan -out=tfplan
# example: *tfplan*
173 changes: 155 additions & 18 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,18 +1,155 @@
# Deploy HPCC Systems Platform with Terraform

This set of Terraform examples deploys all the available features that come with the HPCC Systems OSS Terraform modules.

## Order of deployment
| Order | Name | Required |
| ----- | --------- | :------: |
| 1 | `VNet` | yes |
| 2 | `AKS` | yes |
| 3 | `Storage` | no |
| 4 | `Logging` | no |
| 5 | `AKS` | no |
| 6 | `HPCC` | yes |

## Modules
| Name | Source | Used in |
| :---------------------------------: | :----: | :-----: |
| `terraform-azurerm-virtual-network` | | `VNet` |
# Deploy HPCC Systems on Azure under Kubernetes
dcamper marked this conversation as resolved.
Show resolved Hide resolved

NOTE: Documentation of this Terraform for the developer, or others who are interested, can be found [here](documentation/hpcc-tf-for-developers.md).

This is a slightly-opinionated Terraform module for deploying an HPCC Systems cluster on Azure's Kubernetes service (aks). The goal is to provide a simple method for deploying a cluster from scratch, with only the most important options to consider.

The HPCC Systems cluster created by this module uses ephemeral storage, which is the default. This means the storage will be deleted when the cluster is deleted) But, you can also have Persistent Storage. See the section titled [Persistent Storage](#persistent-storage), below.

## Requirements

* <font color="red">**terraform**</font> This is a Terraform module, so you need to have terraform installed on your system. Instructions for downloading and installing terraform can be found at [https://www.terraform.io/downloads.html](https://www.terraform.io/downloads.html). Do make sure you install a 64-bit version of terraform, as that is needed to accommodate some of the large random numbers used for IDs in the Terraform modules.

* <font color="red">**helm**</font> Helm is used to deploy the HPCC Systems processes under Kubernetes. Instructions for downloading and installing Helm are at [https://helm.sh/docs/intro/install](https://helm.sh/docs/intro/install/).

* <font color="red">**kubectl**</font> The Kubernetes client (kubectl) is also required so you can inspect and manage the Azure Kubernetes cluster. Instructions for download and installing that can be found at [https://kubernetes.io/releases/download/](https://kubernetes.io/releases/download/). Make sure you have version 1.22.0 or later.

* <font color="red">**Azure CLI**</font> To work with Azure, you will need to install the Azure Command Line tools. Instructions can be found at [https://docs.microsoft.com/en-us/cli/azure/install-azure-cli](https://docs.microsoft.com/en-us/cli/azure/install-azure-cli). Even if you think you won't be working with Azure, this module does leverage the command line tools to manipulate network security groups within Kubernetes clusters. TL;DR: Make sure you have the command line tools installed.

* To successfully create everything you will need to have Azure's `Contributor` role plus access to `Microsoft.Authorization/*/Write` and `Microsoft.Authorization/*/Delete` permissions on your subscription. You may have to create a custom role for this. Of course, Azure's `Owner` role includes everything so if you're the subscription's owner then you're good to go.
tlhumphrey2 marked this conversation as resolved.
Show resolved Hide resolved
* You need a minimum of 28 vCPUs available on `azure` and `aks_serv_node_size` must be at least `xlarge`. The following `az` command will tell you the maximum number of vCPUs you can use. And, the 2nd `az` command, below, gives you the number of vCPUs you have already used region `eastus` (replace `eastus` with the name of the region you are using). The first `az` command result minus the second `az` command result gives you the number of vCPUs available for you to use.
* `az vm list-usage --location "eastus" -o table|grep "Total Regional vCPUs"|sed "s/ */\t/g"|cut -f5`
* `az vm list-usage --location "eastus" -o table|grep "Total Regional vCPUs"|sed "s/ */\t/g"|cut -f4`
* If you run the terraform code on an azure VM, then the azure VM must have EncryptionAtHost enabled. You can do this by: 1) Stopping your azure VM; 2) click on `Disk` in the Overview of the azure VM; 3) click on the tab, `Additional Settings`; 4) selecting `yes` radio button under `Encryption at host`.

## Installing/Using This Module

1. If necessary, login to Azure.
* From the command line, this is usually accomplished with the `az login` command.
1. Clone this repo to your local system and change current directory.
* `git clone https://github.com/hpccsystems-solutions-lab/terraform-azurerm-hpcc-lite.git`
* `cd terraform-azurerm-hpcc-lite`
1. Issue `terraform init` to initialize the Terraform modules.
1. Decide how you want to supply option values to the module during invocation. There are three possibilities:
1. Invoke the `terraform apply` command and enter values for each option as terraform prompts for it, then enter `yes` at the final prompt to begin building the cluster.
1. **Recommended:** Create a `lite.auto.tfvars` file containing the values for each option, invoke `terraform apply`, then enter `yes` at the final prompt to begin building the cluster. The easiest way to create `lite.auto.tfvars` is to copy the example file, `lite.auto.tfvars.example`, and then edit the copy:
* `cp -v lite.auto.tfvars.example lite.auto.tfvars`
1. Use -var arguments on the command line when executing the terraform tool to set each of the values found in the .tfvars file. This method is useful if you are driving the creation of the cluster from a script.
1. After the Kubernetes cluster is deployed, your local `kubectl` tool can be used to interact with it. At some point during the deployment `kubectl` will acquire the login credentials for the cluster and it will be the current context (so any `kubectl` commands you enter will be directed to that cluster by default).

At the end of a successful deployment these items are output for aks, hpcc, and vnet:
* aks
* Advisor recommendations or 'none', `advisor_recommendations`.
* Location of the aks credentials, `aks_login`.
* Name of the Azure Kubernetes Service, `cluster_name`.
* Resource group where the cluster is deployed, `cluster_resource_group_name`.
* hpcc
* The URL used to access ECL Watch, `eclwatch_url`.
* The deployment azure resource group, `deployment_resource_group`.
* Whether there is external storage or not, `external_storage_config_exists`.
* vnet
* Advisor recommendations or 'none', `advisor_recommendations`.
* ID of private subnet, `private_subnet_id`.
* ID of public subnet, `public_subnet_id`.
* ID of route table, `route_table_id`.
* Route table name, `route_table_name`.
* Virtual network resource group name, `resource_group_name`.
* Virtual network name, `vnet_name`.

## Available Options

Options have data types. The ones used in this module are:
* string
* Typical string enclosed by quotes
* Example
* `"value"`
* number
* Integer number; do not quote
* Example
* `1234`
* boolean
* true or false (not quoted)
* map of string
* List of key/value pairs, delimited by commas
* Both key and value should be a quoted string
* Entire map is enclosed by braces
* Example with two key/value pairs
* `{"key1" = "value1", "key2" = "value2"}`
* Empty value is `{}`
* list of string
* List of values, delimited by commas
* A value is a quoted string
* Entire list is enclosed in brackets
* Example with two values
* `["value1", "value2"]`
* Empty value is `[]`

The following options should be set in your `lite.auto.tfvars` file (or entered interactively, if you choose to not create a file). Only a few of them have default values. The rest are required. The 'Updateable' column indicates whether, for any given option, it is possible to successfully apply the update against an already-running HPCC k8s cluster.

|Option|Type|Description|Updatable|
dcamper marked this conversation as resolved.
Show resolved Hide resolved
|:-----|:---|:----------|:--------|
| `a_record_name` | string | Name of the A record, of following dns zone, where the ecl watch ip is placed This A record will be created and therefore should not exist in the following dns zone. Example entry: "my-product". This should be something project specific rather than something generic. | Y |
| `admin_username` | string | Username of the administrator of this HPCC Systems cluster. Example entry: "jdoe" | N |
| `aks_admin_email` | string | Email address of the administrator of this HPCC Systems cluster. Example entry: "[email protected]" | Y |
| `aks_admin_ip_cidr_map` | map of string | Map of name => CIDR IP addresses that can administrate this AKS. Format is '{"name"="cidr" [, "name"="cidr"]*}'. The 'name' portion must be unique. To add no CIDR addresses, use '{}'. The corporate network and your current IP address will be added automatically, and these addresses will have access to the HPCC cluster as a user. | Y |
| `aks_admin_name` | string | Name of the administrator of this HPCC Systems cluster. Example entry: "Jane Doe" | Y |
| `aks_azure_region` | string | The Azure region abbreviation in which to create these resources. Example entry: "eastus" | N |
| `aks_dns_zone_name` | string | Name of an existing dns zone. Example entry: "hpcczone.us-hpccsystems-dev.azure.lnrsg.io" | N |
| `aks_dns_zone_resource_group_name` | string | Name of the resource group of the above dns zone. Example entry: "app-dns-prod-eastus2" | N |
| `aks_enable_roxie` | boolean | Enable ROXIE? This will also expose port 8002 on the cluster. Example entry: false | Y |
| `aks_logging_monitoring_enabled` | boolean | This variable enable you to ask for logging and monitoring of the Kubernetes and hpcc cluster (true means enable logging and monitoring, false means don't. | N |
| `aks_4nodepools ` | boolean | Determines whether 1 or 4 nodepools are use -- 4 used if true otherwise 2 used. (default is false). | N |
| `aks_nodepools_max_capacity` | string | The maximum number of nodes of every hpcc nodepool.| N |
| `aks_roxie_node_size ` | string | The VM size for each roxie node in the HPCC Systems. Example format `aks_roxie_node-size`="xlarge".| N |
| `aks_serv_node_size ` | string | The VM size for each serv node in the HPCC Systems. Example format `aks_serv_node-size`="2xlarge".| N |
| `aks_spray_node_size ` | string | The VM size for each spray node in the HPCC Systems. Example format `aks_spray_node-size`="2xlarge".| N |
| `aks_thor_node_size ` | string | The VM size for each thor node in the HPCC Systems. Example format `aks_thor_node-size`="2xlarge".| N |
| `aks_capacity ` | map of number | The min and max number of nodes of each node pool in the HPCC Systems. Example format is '{ roxie_min = 1, roxie_max = 3, serv_min = 1, serv_max = 3, spray_min = 1, spray_max = 3, thor_min = 1, thor_max = 3}'. | N |
| `authn_htpasswd_filename` | string | If you would like to use htpasswd to authenticate users to the cluster, enter the filename of the htpasswd file. This file should be uploaded to the Azure 'dllsshare' file share in order for the HPCC processes to find it. A corollary is that persistent storage is enabled. An empty string indicates that htpasswd is not to be used for authentication. Example entry: "htpasswd.txt" | Y |
| `enable_code_security` | boolean | Enable code security? If true, only signed ECL code will be allowed to create embedded language functions, use PIPE(), etc. Example entry: false | Y |
| `enable_thor` | boolean | If you want a thor cluster then 'enable_thor' must be set to true Otherwise it is set to false | Y |
| `external_storage_desired` | boolean | If you want external storage instead of ephemeral storage then set this variable to true otherwise set it to false. | Y |
| `extra_tags` | map of string | Map of name => value tags that can will be associated with the cluster. Format is '{"name"="value" [, "name"="value"]*}'. The 'name' portion must be unique. To add no tags, use '{}'. | Y |
| `hpcc_user_ip_cidr_list` | list of string | List of explicit CIDR addresses that can access this HPCC Systems cluster. To allow public access, set value to ["0.0.0.0/0"] or []. | Y |
| `hpcc_version` | string | The version of HPCC Systems to install. Only versions in nn.nn.nn format are supported. | Y |
| `my_azure_id` | string | Your azure account object id. Find this on azure portal, by going to 'users' then search for your name and click on it. The account object id is called 'Object ID'. There is a link next to it that lets you copy it. | N |
| `storage_data_gb` | number | The amount of storage reserved for data in gigabytes. Must be 1 or more. If a storage account is defined (see below) then this value is ignored. | Y |
| `storage_lz_gb` | number | The amount of storage reserved for the landing zone in gigabytes. Must be 1 or more. If a storage account is defined (see below) then this value is ignored. | Y |
| `thor_max_jobs` | number | The maximum number of simultaneous Thor jobs allowed. Must be 1 or more. | Y |
| `thor_num_workers` | number | The number of Thor workers to allocate. Must be 1 or more. | Y |

## Persistent Storage

To get persistent storage, i.e. storage that is not deleted when the HPCC cluster is deleted, set the variable, `external_storage_desired`, to true.

## Useful Things

* Useful `az cli` commands:
* `az account list --output table`
* Shows your current subscriptions, and determine which is the default
* `az account set --subscription "My_Subscription"`
* Sets the default subscription
* Useful `kubectl` commands once the cluster is deployed:
* `kubectl get pods`
* Shows Kubernetes pods for the current cluster.
* `kubectl get services`
* Show the current services running on the pods on the current cluster.
* `kubectl config get-contexts`
* Show the saved kubectl contexts. A context contains login and reference information for a remote Kubernetes cluster. A kubectl command typically relays information about the current context.
* `kubectl config use-context <ContextName>`
* Make \<ContextName\> context the current context for future kubectl commands.
* `kubectl config unset contexts.<ContextName>`
* Delete context named \<ContextName\>.
* Note that when you delete the current context, kubectl does not select another context as the current context. Instead, no context will be current. You must use `kubectl config use-context <ContextName>` to make another context current.
* Note that `terraform destroy` does not delete the kubectl context. You need to use `kubectl config unset contexts.<ContextName>` to get rid of the context from your local system.
* If a deployment fails and you want to start over, you have two options:
* Immediately issue a `terraform destroy` command and let terraform clean up.
* Clean up the resources by hand:
* Delete the Azure resource group manually, such as through the Azure Portal.
* Note that there are two resource groups, if the deployment got far enough. Examples:
* `app-thhpccplatform-sandbox-eastus-68255`
* `mc_tf-zrms-default-aks-1`
* The first one contains the Kubernetes service that created the second one (services that support Kubernetes). So, if you delete only the first resource group, the second resource group will be deleted automatically.
* Delete all terraform state files using `rm *.tfstate*`
* Then, of course, fix whatever caused the deployment to fail.
* If you want to completely reset terraform, issue `rm -rf .terraform* *.tfstate*` and then `terraform init`.
127 changes: 0 additions & 127 deletions aks/aks.auto.tfvars.example

This file was deleted.

Loading