All pages
Powered by GitBook
1 of 1

Configuration

Azu configuration properties are minimal this is to help you keep everything in a mental model without overloading your brain.

Overview

Azu configuration properties are minimal this is to help you keep everything in a mental model without overloading your brain.

Configuration properties lives within your application's main file.

Configuration Properties

Apps sometimes store config as constants in the code. This is a violation of the twelve-factor, which requires strict separation of config from code. Config varies substantially across deploys, code does not.

We recommend for development use .env files.

  1. .env file

  2. .env.local file

  3. .env.#{CRYSTAL_ENV} file

  4. .env.#{CRYSTAL_ENV}.local file

Important: Azu does NOT load the .env files automatically. It is up to you the developer to use your preferred method to load environment variables.

Example

App Environments

By default Azu ships with the following environments:

  • Build

  • Development

  • Test

  • Integration

  • Acceptance

  • Pipeline

  • Staging

  • Production

The current application environment is determined via the CRYSTAL_ENV variable.

Use the following method to determine or compare environments

Middlewares

Finally, you must know how to start the server.