Environment Variables
Introduction
Environment variables are a way to store configuration settings and sensitive information outside of your codebase. This is particularly useful for managing different settings for development, testing, and production environments.
We use Infisical to manage our environment variables. Infisical is an open-source tool that helps you securely manage and share environment variables across your team.
Getting Started
To get started with environment variables in your project, follow these steps:
-
Sign up for an Infisical account at https://infisical.com with your work email. This will allow you to securely manage and share environment variables with your team.
-
Request access to the Borku Africa environment variables from your team lead or project manager. An email will be sent to you.
-
Once you have access, you can view and manage the environment variables in the Infisical dashboard.
-
Install the Infisical CLI by running the following command in your terminal:
npm install -g @infisical/cli -
Authenticate the CLI with your Infisical account by running:
infisical login -
In the project directory, initialize Infisical by running:
infisical initSelect the project you want to work on when prompted.
-
To pull the environment variables from Infisical, run:
infisical export > .envThis will create a
.envfile in your project directory with all the environment variables.
Now you can use these environment variables in your project.