Skip to content

CLI Config

Since Didact CLI is a build once, deploy anywhere application, its behaviors are modified through a simple configuration file. This configuration file can be thought of as a set of runtime environment variables for Didact CLI.

cliconfig.json

To provide important environment variables and app settings for Didact CLI, you need a cliconfig.json file. This is similar to an appsettings.json file that you would find in a standard dotnet project.

cliconfig.json template

A cliconfig.json JSON template file is shown below:

json
{
    "Database": {
        "Provider": "<DB_PROVIDER_KEY>",
        "ConnectionString": "<DB_CONNECTION_STRING>"
    },
    "Environment": "<ENVIRONMENT_NAME>",
    "LicenseKey": "<LICENSE_KEY>"
}

cliconfig.json key matrix

The config keys are shown below in a matrix.

INFO

For simplicity, when referencing these keys through Didact CLI commands, use the exact JSON key reference here such as Database.Provider. It makes the CLI commands slightly ugly, but it avoids unproductive aliasing work on my part for the moment.

JSON and CLI key nameKey value typeKey value description
Database.ProviderstringThe database provider key for your database provider of choice.
Database.ConnectionStringstringThe connection string for the database.
EnvironmentstringThe name of the default environment that you want to use.
LicenseKeystringAn API key from Didact Console that unlocks enhanced features.

Proudly powered by VitePress