Dotenv variable file

Undraw My Documents

About

The dotenv variable file is a variable file where you can add secret variables that should not be in your source version control system.

Name and location

The dotenv file name has the following name structure:

.env[.name]

where:

If the name is:

  • not present, the env file is always taken
  • present, the env file is taken only for the corresponding environment

The searched location is:

  • otherwise the working directory (where you execute the tabli command line)

Git

This file is generally added into your .gitignore file. This way, it's never committed into your repository version control system and stays local on your computer.

Example:

.env

Example

Below are variables used to connect to the planete scale database.

PLANETSCALE_URL=jdbc:mysql://xxxxx.us-east-4.psdb.cloud/test?sslMode=VERIFY_IDENTITY
PLANETSCALE_USER=theSecretUser
PLANETSCALE_PWD=theSecretPassword

You can then use them as template variables in a connection vault.

Task Runner