Generating .env file
During local testing, we often need to set environment variables. One way to do this is to create a .env
file in the root directory of the project. This file contains key-value pairs of environment variables. For example, a .env
file might look like this:
Hereunder a quick bash script to generate a .env
file from a list of Azure KeyVault secrets, same logic can be applied to other secret managers.