Skip to content

Commit

Permalink
complete the bash script
Browse files Browse the repository at this point in the history
  • Loading branch information
glucaci committed Aug 1, 2023
1 parent f14dcf8 commit 5ef4794
Showing 1 changed file with 24 additions and 2 deletions.
26 changes: 24 additions & 2 deletions scripts/azure/deploy-aks.sh
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,27 @@ read -p "Enter the Azure region (default: East US): " REGION
read -p "Enter the Azure resource group name (default: rag-stack-resources): " RESOURCE_GROUP_NAME
read -p "Model to deploy: llama2-7b or falcon7b (default: falcon7b): " MODEL

# Set the Terraform variables
defaultRagServerImageName="jfan001/ragstack-server:latest"
read -p "Docker image name for the RAG server (default: ${defaultRagServerImageName}): " RAG_SERVER_IMAGE_NAME

if [ ! -z "$RAG_SERVER_IMAGE_NAME" ] && [ "$RAG_SERVER_IMAGE_NAME" != "$defaultRagServerImageName" ]
then
read -p "Please enter the URL for your Docker registry: " RAG_SERVER_IMAGE_LOGIN_SERVER
read -p "Please enter the username for your Docker registry at ${RAG_SERVER_IMAGE_LOGIN_SERVER}: " RAG_SERVER_IMAGE_USERNAME
read -s -p "Please enter the password for your Docker registry at ${RAG_SERVER_IMAGE_LOGIN_SERVER}: " RAG_SERVER_IMAGE_PASSWORD
echo

export TF_VAR_rag_server_image_login_server=$RAG_SERVER_IMAGE_LOGIN_SERVER
export TF_VAR_rag_server_image_username=$RAG_SERVER_IMAGE_USERNAME
export TF_VAR_rag_server_image_password=$RAG_SERVER_IMAGE_PASSWORD
export TF_VAR_rag_server_image_name=$RAG_SERVER_IMAGE_NAME
fi

read -p "Enter your Superbase URL: " SUPERBASE_URL
read -p "Enter your Superbase API key: " SUPERBASE_API_KEY

export TF_VAR_superbase_url=$SUPERBASE_URL
export TF_VAR_superbase_api_key=$SUPERBASE_API_KEY
export TF_VAR_subscription_id=$SUBSCRIPTION_ID
export TF_VAR_region=$REGION
export TF_VAR_resource_group_name=$RESOURCE_GROUP_NAME
Expand All @@ -29,4 +49,6 @@ terraform init
terraform validate

# Apply the deployment
terraform apply
terraform apply

cat "./README.md"

0 comments on commit 5ef4794

Please sign in to comment.