Deploying into a new environment#
Deploying Sasquatch into a new environment requires multiple ArgoCD syncs with some manual information gathering and updating in between.
Enable Sasquatch in Phalanx#
- Cut a Phalanx development branch. 
- Ensure the - strimziand- strimzi-access-operatorPhalanx applications are enabled and synced in the new environment by adding them to the- environments/values-environment.yamlfile, and adding a blank- values-environment.yamlfile to their- applications/directories. These docs can help you enable them from your development branch.
- Enable the - sasquatchapp in the environment. For the- applications/sasquatch/values-environment.yamlfile, copy one from an existing environment that has the same enabled services that you want in the new environment. Change all of the environment references to the new environment, and change or add anything else you need for the new environment.
- Comment out any - loadBalancerIPentries in the- applications/sasquatch/values-environment.yamlfile. We’ll fill these in later.
- In the new environment’s ArgoCD, point the - sasquatchapp at your Phalanx development branch, and sync it.
This first sync will not be successful.
The cert-manager Certificate resource will be stuck in a progressing state until we update some values and provision some DNS.
Gather IP addresses and update Phalanx config#
Note
The public IP address gathering and modification described here only applies to environments deployed on GCP. This process will be different for other types of environments.
- Get the broker ids, which are the node ids of the the kafka brokers. In this example, the broker ids are - 0,- 1, and- 2:- ❯ kubectl get kafkanodepool -n sasquatch NAME DESIRED REPLICAS ROLES NODEIDS controller 3 ["controller"] [3,4,5] kafka 3 ["broker"] [0,1,2] 
- A GCP public IP address will be provisioned for each of these broker nodes. Another IP address will be provisioned for the external kafka bootstrap servers endpoint. You can see all of the provisioned ip addresses in your GCP project here: - https://console.cloud.google.com/networking/addresses/list?authuser=1&hl=en&project=project name:  
- One by one, click on the - Forwarding rulelinks in each row until you find the ones annotated with- "kubernetes.io/service-name":"sasquatch/sasquatch-kafka-{broker node id"}for each broker node. Note the ip address and node number.  
- Find and note the IP address that is annotated with - {"kubernetes.io/service-name":"sasquatch/sasquatch-kafka-external-bootstrap"}:  
- Promote all of these IP addresses to GCP Static IP Addresses by choosing the option in the three-vertical-dots menu for each IP address (you may have to scroll horrizontally). This makes sure that we won’t lose these IP addresses and have to update DNS later:   
- Update the - applications/sasquatch/values-environment.yaml- strimzi-kafka.kafkaconfig with- loadBalancerIPand- hostentries that correspond with the node ids that you found. Here is an example from- idfint. Note that the broker node ids are in the- brokerentries, and that the- hostentries have numbers in them that match the those ids.- strimzi-kafka: kafka: externalListener: tls: enabled: true bootstrap: loadBalancerIP: "35.188.187.82" host: sasquatch-int-kafka-bootstrap.lsst.cloud brokers: - broker: 0 loadBalancerIP: "34.171.69.125" host: sasquatch-int-kafka-0.lsst.cloud - broker: 1 loadBalancerIP: "34.72.50.204" host: sasquatch-int-kafka-1.lsst.cloud - broker: 2 loadBalancerIP: "34.173.225.150" host: sasquatch-int-kafka-2.lsst.cloud 
- Push these changes to your Phalanx branch and sync - sasquatchin ArgoCD.
Provision DNS for TLS certificate#
- Provision - CNAMErecords (probably in AWS Route53) for LetsEncrypt verification for each of the- hostentries in the- strimzi-kafka.kafkavalues. Continuing with the- idfintexample:- _acme-challenge.sasquatch-int-kafka-0.lsst.cloud (_acme-challenge.tls.lsst.cloud) _acme-challenge.sasquatch-int-kafka-1.lsst.cloud (_acme-challenge.tls.lsst.cloud) _acme-challenge.sasquatch-int-kafka-2.lsst.cloud (_acme-challenge.tls.lsst.cloud) _acme-challenge.sasquatch-int-kafka-bootstrap.lsst.cloud (_acme-challenge.tls.lsst.cloud) 
- Provision - Arecords for each of the- hostentries with their matching IP address values:- sasquatch-int-kafka-0.lsst.cloud (34.171.69.125) sasquatch-int-kafka-1.lsst.cloud (34.72.50.204) sasquatch-int-kafka-2.lsst.cloud (34.173.225.150) sasquatch-int-kafka-bootstrap.lsst.cloud (35.188.187.82) 
- Wait for the - CertificateKubernetes resource to provision in ArgoCD! This might take several minutes
Configure Gafaelfawr OIDC authentication#
Sasquatch assumes that Chronograf will use OIDC authentication. Follow these instructions to set it up.
Warning
This requires a Gafaelfawr restart. It could also affect all of the apps in an environment if done incorrectly. If your new environment is a production environment, you should probably wait for a maintenance window to do this step!
Merge your Phalanx branch!#
If all is well, of course.