I went through the exercise of trying to follow this user journey:
An engineer responsible for UTM services of a USS wants to deploy an InterUSS DSS instance as a component of their USS.
This Issue captures my notes and challenges while doing this that I think we can improve on when using terraform to deploy GKE infrastructure.
Visit repo home
Find and click "Deploying a DSS instance"
TODO(1 - [docs] Update terraform infrastructure deployment documentation #1298 ): Current link target is a redirect to new page ; link directly instead
Read that deployment consists of three phases and Infrastructure is the first
Try to find instructions for Infrastructure
TODO(2 - [docs] Update terraform infrastructure deployment documentation #1298 ): "Infrastructure" link currently targets blank page; remove link or add links to subsection options in that page
TODO(3): Pooling documentation is CRDB-specific; update to allow for Yugabyte
Click on "Google (GKE) " since I'll be deploying there
Fulfill prerequisites
Download terraform 1.13.5 binary
TODO(4 - [docs] Update terraform infrastructure deployment documentation #1298 ): Add command to verify prerequisite is satisfied
Navigate to "Prerequisites " in 2
TODO(5 - [docs] Update terraform infrastructure deployment documentation #1298 ): Link to specific Prerequisites section in that page rather than the top
TODO(6 - Enable multi-level lists in generated documentation #1297 ): Indent substeps rather than having a single, large, flat list
TODO(7 - [docs] Update terraform infrastructure deployment documentation #1298 ): Identify which prerequisites are actually necessary (e.g., cockroach is not necessary for a Yugabyte deployment)
Verify gcloud, kubectl, tk availability
Click on "Google Cloud Engine " in 3a
TODO(8 - Enable multi-level lists in generated documentation #1297 ): Clean up structure of steps and "Google Cloud Engine" subsection
TODO(9 - [docs] Update terraform infrastructure deployment documentation #1298 ): Define what $GOOGLE_PROJECT_NAME/"the DSS project" is (we haven't instructed the user to create or have a Google Cloud project)
TODO(10 - [docs] Update terraform infrastructure deployment documentation #1298 ): Put gcloud config list project in code style
TODO(11 - [docs] Update terraform infrastructure deployment documentation #1298 ): Write out actual commands to enable APIs (gcloud services enable xxx)
TODO(12): Add check for whether user already has credentials to call Google Cloud Platform APIs
Proceed to "Deployment of the Kubernetes cluster "
TODO(13 - [docs] Improve getting started guides #1340 ): fix /deploy to be clearer that it's relative to the repo root
TODO(14 - [docs] Improve getting started guides #1340 ): clarify that terraform-google-dss-dev is an example rather than a prescription
TODO(15 - [docs] Improve getting started guides #1340 ): define where to find main.tf, output.tf, and variables.tf
TODO(16 - [docs] Improve getting started guides #1340 ): define where to find terraform.dev.example.tfvars
Populate variables
TODO(17 - Enable multi-level lists in generated documentation #1297 ): Fix indent (current list is a single flat indent level; main.tf, output.tf, etc should be indented under step 4)
TODO(18 - [docs] Improve readability of TFVARS documentation #1341 ): Figure out how to make https://github.com/interuss/dss/blob/master/deploy/infrastructure/modules/terraform-google-dss/TFVARS.gen.md more readable (Type column is too wide and Description requires scrolling to see)
TODO(19 - [docs] Improve readability of TFVARS documentation #1341 ): See if we can ensure the rows in TFVARS.gen.md appear in the same order as the variables in terraform.dev.example.tfvars (or alphabetical)
TODO(20): Update google_kubernetes_storage_class documentation to include Yugabyte
TODO(21): Update image_pull_secret to refer to image rather than VAR_DOCKER_IMAGE_NAME
TODO(22): Define what VAR_NAMESPACE is in image_pull_secret documentation
TODO(23): Clarify (if accurate) in image_pull_secret that VAR_DOCKER_IMAGE_PULL_SECRET is the value that should be used for image_pull_secret
TODO(24): Clarify what should be done with CockroachDB/Yugabyte variables when using the other db technology (delete? make blank? leave as-is?)
Execute terraform commands
TODO(terraform indicates Bad Request upon terraform apply #1295 )
I went through the exercise of trying to follow this user journey:
This Issue captures my notes and challenges while doing this that I think we can improve on when using terraform to deploy GKE infrastructure.
cockroachis not necessary for a Yugabyte deployment)gcloud,kubectl,tkavailability$GOOGLE_PROJECT_NAME/"the DSS project" is (we haven't instructed the user to create or have a Google Cloud project)gcloud config list projectin code stylegcloud services enable xxx)/deployto be clearer that it's relative to the repo rootterraform-google-dss-devis an example rather than a prescriptiongoogle_kubernetes_storage_classdocumentation to include Yugabyteimagerather thanVAR_DOCKER_IMAGE_NAMEimage_pull_secretdocumentationimage_pull_secretthatVAR_DOCKER_IMAGE_PULL_SECRETis the value that should be used forimage_pull_secretterraform apply#1295)