Skip to content

Environment Variables

Emily Bowe edited this page Jun 2, 2021 · 1 revision

You need setup environment variables before running the application in development mode npm run dev or building static pages npm run build.

Included in the repo is a terminal script that can be used to create the .env file. To do this, use the following steps:

  1. Clone the repository to a local directory and navigate to the root folder of this directory.
  2. Type ./create-env-file.sh into the terminal. If you run into any issues such as "permission denied", type chmod u+x ./create-env-file.sh, then run ./create-env-file.sh again.
  3. Step 2 should have created a .env file within the local directory pre-filled with the variable names you will need. You will need to supply the values for these variables by accessing the relevant USL Firebase instance and Mapbox account (Equity AR). Talk to Daniel Sauter if you have any issues with access.
FIREBASE_DEV_KEY="..."
FIREBASE_DEV_AUTHDOMAIN="..."
FIREBASE_DEV_URL="..."
FIREBASE_DEV_ID="..."
FIREBASE_DEV_STORAGE="..."
FIREBASE_DEV_SENDER_ID="..."
FIREBASE_DEV_APP_ID="..."

MB_ACCESS_TOKEN="..."

Definitions:

  • FIREBASE_DEV_KEY= Firebase API Key
  • FIREBASE_DEV_AUTHDOMAIN= Firebase Auth Domain
  • FIREBASE_DEV_URL = Firebase Realtime Database URL
  • FIREBASE_DEV_ID = Firebase Project ID
  • FIREBASE_DEV_STORAGE = Firebase Storage Bucket
  • FIREBASE_DEV_SENDER_ID = Firebase Messaging Sender ID
  • FIREBASE_DEV_APP_ID = Firebase App ID
  • MB_ACCESS_TOKEN = Mapbox API key. It can be found on the account settings page. It likely begins with pk....