From 2efa04d6187e2a4fb49c37a360da5c329629adf1 Mon Sep 17 00:00:00 2001 From: Joe Martin Date: Fri, 31 May 2024 09:50:18 -0700 Subject: [PATCH] Some tweaking and rewording --- kubernetes/full-create-and-install.sh | 32 +++++++++++++-------------- 1 file changed, 15 insertions(+), 17 deletions(-) diff --git a/kubernetes/full-create-and-install.sh b/kubernetes/full-create-and-install.sh index 8572656..a2ab13a 100755 --- a/kubernetes/full-create-and-install.sh +++ b/kubernetes/full-create-and-install.sh @@ -1,7 +1,8 @@ #!/bin/bash -# This script sets up a GKE cluster with specific configurations for Aerospike and AVS node pools. -# It handles the creation of the cluster, node pools, labeling, tainting of nodes, and deployment of necessary operators and configurations. +# This script sets up a GKE cluster with configurations for Aerospike and AVS node pools. +# It handles the creation of the GKE cluster, the use of AKO (Aerospike Kubernetes Operator) to deploy an Aerospike cluster, deploys the AVS cluster, +# and the deployment of necessary operators, configurations, node pools, etc. # Additionally, it sets up monitoring using Prometheus and deploys a specific Helm chart for AVS. # Function to print environment variables for verification @@ -22,11 +23,10 @@ print_env() { # Set environment variables for the GKE cluster setup export PROJECT_ID="$(gcloud config get-value project)" -export CLUSTER_NAME="${PROJECT_ID}-" +export CLUSTER_NAME="${PROJECT_ID}-cluster" export NODE_POOL_NAME_AEROSPIKE="aerospike-pool" export NODE_POOL_NAME_AVS="avs-pool" export ZONE="us-central1-c" -#export HELM_CHART="aerospike/aerospike-avs" export HELM_CHART="/home/joem/src/helm-charts/aerospike-vector-search" export FEATURES_CONF="./features.conf" export AEROSPIKE_CR="./manifests/ssd_storage_cluster_cr.yaml" @@ -101,10 +101,10 @@ echo "Deploying Aerospike cluster..." kubectl apply -f "$AEROSPIKE_CR" ############################################## -# AVS name space +# AVS namespace ############################################## -echo "Adding avs node pool..." +echo "Adding AVS node pool..." if ! gcloud container node-pools create "$NODE_POOL_NAME_AVS" \ --cluster "$CLUSTER_NAME" \ --project "$PROJECT_ID" \ @@ -113,13 +113,13 @@ if ! gcloud container node-pools create "$NODE_POOL_NAME_AVS" \ --disk-type "pd-standard" \ --disk-size "100" \ --machine-type "e2-highmem-4"; then - echo "Failed to create avs node pool" + echo "Failed to create AVS node pool" exit 1 else - echo "avs node pool added successfully." + echo "AVS node pool added successfully." fi -echo "Labeling avs nodes..." +echo "Labeling AVS nodes..." kubectl get nodes -l cloud.google.com/gke-nodepool="$NODE_POOL_NAME_AVS" -o name | \ xargs -I {} kubectl label {} aerospike.com/node-pool=avs --overwrite @@ -127,7 +127,7 @@ echo "Setup complete. Cluster and node pools are configured." kubectl create namespace avs -echo "Setting secrets for avs cluster..." +echo "Setting secrets for AVS cluster..." kubectl --namespace avs create secret generic aerospike-secret --from-file=features.conf="$FEATURES_CONF" kubectl --namespace avs create secret generic auth-secret --from-literal=password='admin123' @@ -149,11 +149,9 @@ kubectl apply -f manifests/monitoring echo "Setup complete." echo "To include your Grafana dashboards, use 'import-dashboards.sh '" -echo "To view grafana dashboards from your machine use kubectl port-forward -n monitoring svc/monitoring-stack-grafana 3000:80" -echo "To expose grafana ports publically 'kubectl apply -f helpers/EXPOSE-GRAFANA.yaml'" -echo "To find the exposed port with 'kubectl get svc -n monitoring' " - - -echo To run the quote search sample app on your new cluster you can use -echo helm install sematic-search-app aerospike/quote-semantic-search --namespace avs --values manifests/sematic-search-values.yaml --wait +echo "To view Grafana dashboards from your machine use 'kubectl port-forward -n monitoring svc/monitoring-stack-grafana 3000:80'" +echo "To expose Grafana ports publicly, use 'kubectl apply -f helpers/EXPOSE-GRAFANA.yaml'" +echo "To find the exposed port, use 'kubectl get svc -n monitoring'" +echo "To run the quote search sample app on your new cluster, use:" +echo "helm install semantic-search-app aerospike/quote-semantic-search --namespace avs --values manifests/semantic-search-values.yaml --wait"