Skip to content

.env files

Damian Loch edited this page Jul 11, 2024 · 23 revisions

Description

This wiki serves as a place to store the most recent .env files so that any updates to them are clearly shared amongst developers. Should you implement changes that modify any .env files, please update this wiki to reflect those changes.

In order to deploy Bridge, 3 .env files are required.

The first .env file is the deployment .env and should be located in the same directory as the docker-compose.yaml file. There are 2 paths which should be changed based on local paths on your device the MODEL_REPOSITORY_PATH and OLLAMA_PATH. Both of these variables should point to empty directory on your device. Note that for Windows users, double backslashes are used instead of single forward slashes for paths. Additionally, to connect to the model repository stored on Azure, set MODEL_REPOSITORY_PATH=as://tritonmodels/modelrepository. The third .env file should be located in frontends/bridge-front

CHANGE THE LOCAL GOOGLE CREDENTIALS PATH AS WELL

Here is what it looks like:

Deployment .env file:

# *** ELASTIC ***
# Password for the 'elastic' user (at least 6 characters)
ELASTIC_PASSWORD=thisisarandompassword
# Password for the 'kibana_system' user (at least 6 characters)
KIBANA_PASSWORD=thisisarandompassword
# Version of Elastic products
STACK_VERSION=8.13.0
# Set the cluster name
CLUSTER_NAME=bridge-cluster
# Set to 'basic' or 'trial' to automatically start the 30-day trial
LICENSE=basic
# Port to expose Elasticsearch HTTP API to the host
ES_PORT=9200
# Port to expose Kibana to the host
KIBANA_PORT=5601
# Increase or decrease based on the available host memory (in bytes)
ES_MEM_LIMIT=1073741824
KB_MEM_LIMIT=1073741824
LS_MEM_LIMIT=1073741824
ENCRYPTION_KEY=c34d38b3a14956121ff2170e5030b471551370178f43e5626eec58b04a30fae2
# *** OLLAMA ***
LLM_MODEL=gpt-4o
# *** TRITON ***
# TODO: Swith to cloud configuration file
# Path to model repository
# Please make sure to add a volume into the docker-compose if you need to use a local path
#MODEL_REPOSITORY_PATH=as://tritonmodels/modelrepository
MODEL_REPOSITORY_PATH=C:\\Users\\dloch\\repo_path
MODEL_CONTAINER_NAME=modelrepository
# Azure Storage Auth
AZURE_CONNECTION_STRING="DefaultEndpointsProtocol=https;AccountName=tritonmodels;AccountKey=3gzzyBA65d3mLW3+PTPxdWNEZWKIGVdXifgGfqFMjASzY5I/WhStOLuq/IV6+bS9ZiR6EyAglAzu+ASt58Y+XA==;EndpointSuffix=core.windows.net"
AZURE_STORAGE_KEY="3gzzyBA65d3mLW3+PTPxdWNEZWKIGVdXifgGfqFMjASzY5I/WhStOLuq/IV6+bS9ZiR6EyAglAzu+ASt58Y+XA=="
AZURE_STORAGE_ACCOUNT_NAME=tritonmodels
OLLAMA_PATH=C:\\Users\\dloch\\ollama_data

# *** GOOGLE CONNECTOR ***
LOCAL_GOOGLE_CREDENTIALS_PATH=C:\Users\nidhi\Documents\Arvo\ #The location where your client file is stored
# Download it from here https://github.com/user-attachments/files/15806905/client_secret_900197506284-pcahsol5524co5rn5bkivpcpd47496pb.apps.googleusercontent.com.json

The second .env file is the backend .env file, located in the backend directory. The client secret file must be downloaded from the link provided and the path edited as seen in the .env file.

Here is what it looks like:

Backend .env file:

LLM_URL="https://api.openai.com/v1"
#openai API key:
OPENAI_KEY=sk-proj-egdSI1R1uh4QrRbwjlgxT3BlbkFJWDayEfih1eqJri8ekq7R

CLIENT_SECRET_FILE=/Users/kevin/Downloads/client_secret_314321330211-32eu8fe8sot2qobjgaefq2pgtf2e2bq0.apps.googleusercontent.com.json
(https://github.com/GroupLabs/bridge/files/15489682/client_secret_314321330211-32eu8fe8sot2qobjgaefq2pgtf2e2bq0.apps.googleusercontent.com.json)


#Office365 Connectors
CLIENT_ID=7a161cb9-b4a0-4eaa-86db-46be079c427d
CLIENT_SECRET=Z.-8Q~NZb3MbBW8QNa8luHMrjBbw3MrWXogn7b.m
AUTHORITY=https://login.microsoftonline.com/common
REDIRECT_URI=http://localhost:8000/api/office_callback

#Clerk
CLERK_API_KEY=pk_test_bmF0dXJhbC1jaGlwbXVuay0zNC5jbGVyay5hY2NvdW50cy5kZXYk
CLERK_SECRET_KEY=sk_test_sJqae4sMzJXtFkLaHPS7tVIfhYY9IkbL4kURs9qrw8

# Google Connector
OAUTHLIB_RELAX_TOKEN_SCOPE=1

# Salesforce 
SALESFORCE_CLIENT_ID = "3MVG9JJwBBbcN47K7BLbHoSSgaQFAKI9aEawWgpUL2.8m1b2Gc4TbWny4QBHaRP4VSK2ILt5PVPUVOw4vNicF"
SALESFORCE_CLIENT_SECRET = "B84C52384E4ED13F0215B7565E3D33BBD6E0BDD6B852411B239D6898515D36C5"

Here is Frontend .env with the necessary API keys.

Frontend .env file:

OPENAI_API_KEY=sk-proj-egdSI1R1uh4QrRbwjlgxT3BlbkFJWDayEfih1eqJri8ekq7R
TAVILY_API_KEY=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
#UPSTASH_REDIS_REST_URL=https://outgoing-oyster-36751.upstash.io
#UPSTASH_REDIS_REST_TOKEN=AY-PAAIncDEzOWQ4ZmFmODQ3MGM0NDkwYjgxMGQ3N2E3MmE4YjRjZnAxMzY3NTE
UPSTASH_REDIS_REST_URL=https://electric-dolphin-55842.upstash.io/
UPSTASH_REDIS_REST_TOKEN=AdoiAAIncDExNmM0OTQxZDBjYjg0MmQzYWJhNmI3YTJhM2YwYWExMnAxNTU4NDI
EXA_API_KEY=ef19ffca-2997-4eee-b1cd-270ff476d98a
NEXT_PUBLIC_CLERK_PUBLISHABLE_KEY=pk_test_b3JnYW5pYy1nb3JpbGxhLTg2LmNsZXJrLmFjY291bnRzLmRldiQ
CLERK_SECRET_KEY=sk_test_12R1jHjsNOdY8xNEbRfRAKwx1oIPstWtXRGCpAZbn2
#NEXT_PUBLIC_CLERK_SIGNIN_URL=https://organic-gorilla-86.accounts.dev/sign-in
NEXT_PUBLIC_CLERK_SIGN_IN_URL=/sign-in
NEXT_PUBLIC_CLERK_SIGN_UP_URL=/sign-up

Last modified: July 11th 2024

Clone this wiki locally