From 5696d4875b9f2c304102e0c03ae5d4d37bb77e9d Mon Sep 17 00:00:00 2001 From: Dave Herder <27025660+dherder@users.noreply.github.com> Date: Fri, 29 Sep 2023 11:15:44 -0700 Subject: [PATCH] Update Deploy-Fleet-on-Kubernetes.md (#14155) added clarification on running Helm commands in v2 vs v3 --------- Co-authored-by: Rachael Shaw --- docs/Deploy/Deploy-Fleet-on-Kubernetes.md | 26 +++++++++++++++++++---- 1 file changed, 22 insertions(+), 4 deletions(-) diff --git a/docs/Deploy/Deploy-Fleet-on-Kubernetes.md b/docs/Deploy/Deploy-Fleet-on-Kubernetes.md index 2314ac2ce4..5498218280 100644 --- a/docs/Deploy/Deploy-Fleet-on-Kubernetes.md +++ b/docs/Deploy/Deploy-Fleet-on-Kubernetes.md @@ -93,6 +93,8 @@ If you have not used Helm before, you must run the following to initialize your helm init ``` +> Note: The helm init command has been removed in Helm v3. It performed two primary functions. First, it installed Tiller which is no longer needed. Second, it set up directories and repositories where Helm configuration lived. This is now automated in Helm v3; if the directory is not present it will be created. + ### Deploying Fleet with Helm To configure preferences for Fleet for use in Helm, including secret names, MySQL and Redis hostnames, and TLS certificates, download the [values.yaml](https://raw.githubusercontent.com/fleetdm/fleet/main/charts/fleet/values.yaml) and change the settings to match your configuration. @@ -117,16 +119,24 @@ For the sake of this tutorial, we will again use Helm, this time to install MySQ The MySQL that we will use for this tutorial is not replicated and it is not Highly Available. If you're deploying Fleet on a Kubernetes managed by a cloud provider (GCP, Azure, AWS, etc), I suggest using their MySQL product if possible as running HA MySQL in Kubernetes can be difficult. To make this tutorial cloud provider agnostic however, we will use a non-replicated instance of MySQL. -To install MySQL from Helm, run the following command. Note that there are some options that are specified. These options basically just enumerate that: +To install MySQL from Helm, run the following command. Note that there are some options that need to be defined: - There should be a `fleet` database created - The default user's username should be `fleet` +Helm v2 ```sh helm install \ --name fleet-database \ --set mysqlUser=fleet,mysqlDatabase=fleet \ - stable/mysql + oci://registry-1.docker.io/bitnamicharts/mysql +``` + +Helm v3 +```sh +helm install fleet-database \ + --set mysqlUser=fleet,mysqlDatabase=fleet \ + oci://registry-1.docker.io/bitnamicharts/mysql ``` This helm package will create a Kubernetes `Service` which exposes the MySQL server to the rest of the cluster on the following DNS address: @@ -156,11 +166,19 @@ kubectl create -f ./docs/Using-Fleet/configuration-files/kubernetes/fleet-migrat #### Redis +Helm v2 ```sh helm install \ --name fleet-cache \ --set persistence.enabled=false \ - stable/redis + oci://registry-1.docker.io/bitnamicharts/redis +``` + +Helm v3 +```sh +helm install fleet-cache \ + --set persistence.enabled=false \ + oci://registry-1.docker.io/bitnamicharts/redis ``` This helm package will create a Kubernetes `Service` which exposes the Redis server to the rest of the cluster on the following DNS address: @@ -245,4 +263,4 @@ Once you have the public IP address for the load balancer, create an A record in - \ No newline at end of file +