# CI/CD with Configu
Source: https://docs.configu.com/guides/ci-cd
Advanced integration strategies for deploying Configu in your CI/CD pipelines, tailored for experienced engineers aiming to optimize deployment workflows.
export const Construction = () =>
This section is under construction and will be ready soon. Thanks for your patience! 🚧
;
# Managing HashiCorp Vault using Configu CLI
Source: https://docs.configu.com/guides/hashicorp-vault
Today's developer teams are tasked with having to manage Config Ops on the *platform* as well,
and HashiCorp Vault is a great opportunity to show how Configu lets you only worry about your config
[schemas](/introduction/concepts#configschema), with Configu providing the rest of what's needed, including talking
to Vault's API to get and validate your new config values in place. Check out the tutorial below

To complete the tutorial, you'll need a HashiCorp Vault Server and Credentials (easiest is having it installed as a [docker](https://github.com/hashicorp/docker-vault)), [Git](https://git-scm.com/book/en/v2/Getting-Started-Installing-Git), [Configu's CLI](/interfaces/cli/setup),
and a simple 'hello world' app to deploy which we've provided in this repo.
In most cases, your application already has a configuration file, in this example, we will examine Python code that consumes a PostgreSQL connection URL and a `.env` file:
```python
os.environ['DB_URL'] = 'psql://{user}:{password}@{host}:{port}/{name}'.format(
user=os.environ['DB_USER'],
password=os.environ['DB_PASSWORD'],
host=os.environ['DB_HOST'],
port=os.environ['DB_PORT'],
name=os.environ['DB_NAME']
)
```
```bash .env.development
DB_USER=user
DB_PASSWORD=123
DB_HOST=127.0.0.1
DB_PORT=5433
DB_NAME=database
```
## Step 1 - Create schema declaration
Instead of maintaining a `.env` file for each environment or Vault for production and possibly for other sensitive environments,
create a `.cfgu` schema declaration for this service, so that each change will only have to be changed once (only the key in the schema) and then the values will be initialized by the same interface.
Our schema will look like this:
```json my-app.cfgu.json
{
"keys": {
"DB_USER": {
"test": "expect($.value).to.be.a('string')",
"default": "user"
},
"DB_PASSWORD": {
"test": "expect($.value).to.be.a('string')",
"default": "123"
},
"DB_HOST": {
"test": "validator.isIP($.value, 4)",
"required": "true",
"default": "127.0.0.1"
},
"DB_PORT": {
"test": "validator.isPort($.storedValue)",
"required": "true",
"default": "5433"
},
"DB_NAME": {
"test": "expect($.value).to.be.a('string')",
"default": "database"
},
"DB_URL": {
"test": "expect($.value).to.be.a('string')",
"const": "psql://{{DB_USER}}:{{DB_PASSWORD}}@{{DB_HOST}}:{{DB_PORT}}/{{DB_NAME}}",
"description": "Generates a full PostgreSQL URL connection"
}
}
}
```
Although saving configurations in the source control is considered to be bad practice, the Cfgu format is designed to be part of the code as it doesn't include any sensitive values.
Doing that increases developers' velocity and helps them avoid leaving the terminal/IDE for other config management platforms.
## Step 2 - Use defaults for local development
Running a local environment was never easier, choose your preferred way to inject your environment variables:
* Run Configu seamlessly with your app
```bash
configu eval --schema "./my-app.cfgu.json" --defaults | configu export --run "py my-app.py"
```
* Inject the variables into your shell
```bash
configu eval --schema "./my-app.cfgu.json" --defaults | configu export --source
```
* Download and use `.env` file or any other format you want
```bash
configu eval --schema "./my-app.cfgu.json" --defaults | configu export --format "Dotenv" > .env.development
```
## Step 3 - Manage configs in HashiCorp Vault using Configu Orchestrator
Using a single set of commands we can control any store from local files on git to secret managers.
In the following example, we will manage our configs over our HashiCorp Vault secret manage.
### Authenticate HashiCorp Vault
Configu's CLI uses the standard env vars HashiCorp uses, if you have the Vault CLI configured and working, there's no special action to take.
If not please configure your environment with the required variables (See variables [here](https://github.com/hashicorp/vault/blob/api/v1.0.4/api/client.go#L28)).
### Upsert values
```bash
configu upsert --store "hashicorp-vault" --schema "./my-app.cfgu.json" --set "prod" \
--kv "DB_USER=user" --kv "DB_PASSWORD=123" --kv "DB_HOST=localhots" \
--kv "DB_PORT=5433" --kv "DB_NAME=database"
```
### Export values
Similar to the way we previously used the Cfgu defaults we can evaluate and export from any store we need.
```bash
configu eval --store "hashicorp-vault" --schema "./my-app.cfgu.json" --set "prod" \
| configu export --run "py my-app.py"
```
You're done! This was a simple operation, but that's the best way to show someone the power and the simplicity of Configu Orchestrator and how you can use it to manage your configuration automatically and safely using all your current stores.
# Hello World
Source: https://docs.configu.com/guides/hello-world
Learn how to quickly get started with `Configu`. We'll use the `Configu CLI` and the `Configu ConfigStore` (Configu Platform) to declare, initialize, and export a simple set of configuration data.
### 1. Install Configu CLI
```shell Linux
curl https://files.configu.com/cli/install.sh | sh
```
```shell MacOS
curl https://files.configu.com/cli/install.sh | sh
```
```powershell Windows
irm https://files.configu.com/cli/install.ps1 | iex
```
### 2. Declare your first ConfigSchema
```shell
configu init --hello-world
```
### 3. Connect to Configu ConfigStore
```shell
configu login
```
The [Configu `ConfigStore`](https://app.configu.com/) is a convenient way to get started with Configu, especially for users who are new to the tool. It is a configuration management platform that is easy to use and requires minimal setup, with a free starter plan option.
To get started with [Configu Platform](https://app.configu.com/), you'll need to [register and create a new organization](https://app.configu.com/).
It's important to note that [Configu Platform](https://app.configu.com/) is just one of many options for storing and
managing configuration data with Configu. If you have specific requirements or preferences, you may wish to explore
other [ConfigStore options](/integrations/overview#configstore), such as using a database, a secret manager, a feature
flag system, or your own custom implementation.
### 4. Upsert Configs to ConfigSet
```shell
configu upsert \
--store 'configu' --set 'development' --schema './start.cfgu.json' \
--kv "GREETING=hey" --kv "SUBJECT=" \
&& configu upsert \
--store 'configu' --set 'development/qa' --schema './start.cfgu.json' \
-kv "GREETING=hola" \
&& configu upsert \
--store 'configu' --set 'production' --schema './start.cfgu.json' \
-kv "GREETING=welcome"
```
### 5. Export the configuration data
```shell
configu eval \
--store 'configu' --set 'development/qa' --schema './start.cfgu.json' \
| configu export \
--format "Dotenv" \
> ".env"
```
As a result, you will get a `.env` file with the configurations declared in the "get-started" ConfigSchema and their values from the "test" ConfigSet.
```.env
GREETING=welcome
SUBJECT=
MESSAGE=welcome, !
```
That's it! You now have a simple set of configuration data stored in the [Configu Cloud](https://app.configu.com/), ready to be used in your application.
To learn more about Configu and how to use it, you can continue to explore the documentation and join the Configu
[Discord channel](https://discord.com/invite/cjSBxnB9z8), where you can ask questions and get help from the Configu
team and other community members.
# Integrate Configu
Source: https://docs.configu.com/guides/integrate-configu
Step-by-step guide for engineers to incorporate Configu into small-scale applications, enhancing configuration management from the get-go.
export const Construction = () =>
This section is under construction and will be ready soon. Thanks for your patience! 🚧
;
# Create a Discord Webhook
Source: https://docs.configu.com/guides/platform/discord-webhook
Learn how to send Activity Log events to a Discord channel.
## Prerequisites
* Access permissions to create a WebHook for your Discord channel.
* Configu Cloud organization with admin permissions
## Create a Discord WebHook
For this integration to work, you'll need a [Discord Webhook](https://support.discord.com/hc/en-us/articles/228383668-Intro-to-Webhooks).
Browse to that URL and follow the steps.
Get your Webhook URL which looks something like this: `https://discord.com/api/webhooks/XXXXXXXXXX/YYYYYYYYYY`.


## Create a Configu Webhook
1. Browse to the Webhooks page (/integrations/webhooks) in your Confgu Cloud organization.
2. Create a new webhook using the Slack Payload URL you obtained in the previous step.
3. Customize your payload to include a `context` property with some message, and then click Create.
[Explore the Full Webhooks documentation](/integrations/store/configu/webhooks).

Example result:

# Trigger Github Actions using a Configu Webhook
Source: https://docs.configu.com/guides/platform/github-actions-webhook
Learn how to trigger a [GitHub workflow](https://docs.github.com/en/actions/using-workflows/triggering-a-workflow) from a webhook invocation.
## Prerequisites
* Access permissions to create a WebHook for Github Actions.
* Configu Cloud organization with admin permissions (if you donn't have an account, get one free [here](https://app.configu.com))
## Create a Configu Webhook
1. Define your target workflow payload URL: `https://api.github.com/repos/{owner}/{repo}/actions/workflows/{action-id}/dispatches`, example:

2. Customize your header to include an `Authorization` header with your GitHub personal access token. Example:

3. Customize your payload to contain the data you need, for this example:

you will need to send the following payload data:

* `ref` is the branch that contains the workflow definition
* `inputs` is the data that the workflow will use that is sent from the webhook
# Create a Slack Webhook
Source: https://docs.configu.com/guides/platform/slack-webhook
Learn how to send Activity Log events to a Slack channel.
## Prerequisites
* Access permissions to create an Incoming WebHook for your Slack workspace.
* Configu Cloud organization with admin permissions
## Create a Slack Incoming WebHook
For this integration to work, you'll need a Slack [Incoming WebHook](https://api.slack.com/messaging/webhooks).
Browse to that URL and follow the steps.
Get your target payload URL which looks something like this: `https://hooks.slack.com/services/T00000000/B00000000/XXXXXXXXXXXXXXXXXXXXXXXX`.
The standard way is by enabling incoming webhooks on a custom app you installed on your Slack workspace and creating a webhook as such:

## Create a Configu Webhook
1. Browse to the Webhooks page (/integrations/webhooks) in your Confgu Cloud organization.
2. Create a new webhook using the Slack Payload URL you obtained in the previous step.
3. Customize your payload to include a `text` property with some message, and then click Create.
[Explore the Full Webhooks documentation](/integrations/store/configu/webhooks).

Example result:

# React Native with Configu
Source: https://docs.configu.com/guides/react-native
Learn how to use React Native with `Configu`. We'll use the `Configu CLI` and the `Configu ConfigStore` (Configu Platform) to declare, initialize, and export a simple set of configuration data which you can use in your React Native app.
## 1. The problem
When developing a React Native app, you typically need to manage configurations for various environments, like development, testing, and production. You may also need to adjust configurations for different app features or components, which can be time-consuming and error-prone if done manually. Configu helps streamline environment-based configuration in a React Native app, reducing the potential for manual errors. This guide will demonstrate how to use Configu to manage configurations for your React Native app.
Let's begin by creating a [simple Expo project](https://docs.expo.dev/get-started/create-a-project/) and introduce environment variables to our React Native app by following the ["Environment variables in Expo"](https://docs.expo.dev/guides/environment-variables/) guide.
You should now have the following `.env` file:
```.env
EXPO_PUBLIC_API_URL=https://staging.example.com
EXPO_PUBLIC_API_KEY=abc123
```
And the following component that uses it:
```jsx
import { Button } from 'react-native';
function Post() {
const apiUrl = process.env.EXPO_PUBLIC_API_URL;
async function onPress() {
await fetch(apiUrl, { ... })
}
return ;
}
```
Let's enrich the `.env` file with more environment variables:
```.env
EXPO_PUBLIC_API_URL=https://staging.api.example.com
EXPO_PUBLIC_API_KEY=abc123
EXPO_PUBLIC_POST_BUTTON_ENABLED=true
EXPO_PUBLIC_POST_BUTTON_COLOR=blue
```
* `EXPO_PUBLIC_POST_BUTTON_ENABLED`: A feature flag that determines whether the post button is enabled.
* `EXPO_PUBLIC_POST_BUTTON_COLOR`: The color of the post button.
And use them in our component:
```jsx
import { Button } from 'react-native';
export function Post() {
const apiUrl = process.env.EXPO_PUBLIC_API_URL ?? 'https://example.com/api';
if (process.env.EXPO_PUBLIC_POST_BUTTON_ENABLED !== 'true') return null;
async function onPress() {
await fetch(apiUrl, { ... });
}
return ;
}
```
You will need to perform a full reload (for example, shake gesture and then Reload in Expo Go or your development
build) to see the updated values.
Now whenever we want to change the environment variables based on the environment we need we have to manually change the `.env` file. This is not a good practice and can lead to errors. This is where Configu comes in, you can store all your configurations in one place and use the Configu CLI to export the configurations to your `.env` file based on the environment you are working on. In the next steps we will show you how to do this.
## 2. Install Configu CLI
```shell Linux
curl https://files.configu.com/cli/install.sh | sh
```
```shell MacOS
curl https://files.configu.com/cli/install.sh | sh
```
```powershell Windows
irm https://files.configu.com/cli/install.ps1 | iex
```
## 3. Create schema declaration
Run the following command which will create a ConfigSchema using the `.env` file you created earlier and set the values as defaults.
```shell
configu init --import .env --defaults --name expo
```
Now you should have a `expo.cfgu.json` file in your project directory with the following content:
```json
{
"EXPO_PUBLIC_API_URL": {
"default": "https://staging.api.example.com"
},
"EXPO_PUBLIC_API_KEY": {
"default": "abc123"
},
"EXPO_PUBLIC_POST_BUTTON_ENABLED": {
"default": "true"
},
"EXPO_PUBLIC_POST_BUTTON_COLOR": {
"default": "blue"
}
}
```
## 4. Connect to Configu ConfigStore
You may now choose one of the many ConfigStore integrations that are available as your source of configurations for your React Native app. In this guide, we will use the [Configu ConfigStore](/integrations/store/configu) our chosen ConfigStore.
```shell
configu login
```
The [Configu `ConfigStore`](https://app.configu.com/) is a convenient way to get started with Configu, especially for users who are new to the tool. It is a configuration management platform that is easy to use and requires minimal setup, with a free starter plan option.
To get started with [Configu Platform](https://app.configu.com/), you'll need to [register and create a new organization](https://app.configu.com/).
## 5. Upsert values
Now that you have connected to the ConfigStore, you can upsert the configuration values for the different environments using the Configu CLI.
You can upsert fallback configurations for each environment by upserting to the root set and adding environment specific configurations by upserting to the environment as such:
```shell
configu upsert \
--store 'configu' --set '' --schema './expo.cfgu.json' \
-c "EXPO_PUBLIC_POST_BUTTON_ENABLED=false" -c "EXPO_PUBLIC_API_KEY=abc123" -c "EXPO_PUBLIC_POST_BUTTON_COLOR=blue" \
&& configu upsert \
--store 'configu' --set 'development' --schema './expo.cfgu.json' \
-c "EXPO_PUBLIC_API_URL=https://dev.api.example.com" -c "EXPO_PUBLIC_POST_BUTTON_COLOR=red" -c "EXPO_PUBLIC_POST_BUTTON_ENABLED=true" \
&& configu upsert \
--store 'configu' --set 'staging' --schema './expo.cfgu.json' \
-c "EXPO_PUBLIC_API_URL=https://staging.api.example.com" -c "EXPO_PUBLIC_POST_BUTTON_ENABLED=true" \
&& configu upsert \
--store 'configu' --set 'production' --schema './expo.cfgu.json' \
-c "EXPO_PUBLIC_API_URL=https://api.example.com" -c "EXPO_PUBLIC_API_KEY=prod123" "EXPO_PUBLIC_POST_BUTTON_COLOR=green"
```
## 6. Export and use values from Configu in your React Native app
```shell
configu eval \
--store 'configu' --set 'development' --schema './expo.cfgu.json' \
| configu export \
--format "Dotenv" \
> ".env"
```
As a result, you will get a `.env` file with the configurations declared in the "expo" ConfigSchema and their values from the "development" ConfigSet.
```.env
EXPO_PUBLIC_API_URL=https://dev.api.example.com
EXPO_PUBLIC_API_KEY=abc123
EXPO_PUBLIC_POST_BUTTON_ENABLED=true
EXPO_PUBLIC_POST_BUTTON_COLOR=red
```
Evaluating and exporting from the "staging" and "production" ConfigSets will result in `.env` files with the configurations for those environments.
Staging:
```.env
EXPO_PUBLIC_API_URL=https://staging.api.example.com
EXPO_PUBLIC_API_KEY=abc123
EXPO_PUBLIC_POST_BUTTON_ENABLED=true
EXPO_PUBLIC_POST_BUTTON_COLOR=blue
```
Production:
```.env
EXPO_PUBLIC_API_URL=https://api.example.com
EXPO_PUBLIC_API_KEY=prod123
EXPO_PUBLIC_POST_BUTTON_ENABLED=false
EXPO_PUBLIC_POST_BUTTON_COLOR=green
```
That's it! You can reload your app and see the changes in the `.env` file reflected in your React Native app. If you use a framework other than Expo, you can refer to the documentation of that framework to learn how to use environment variables.
To learn more about Configu and how to use it, you can continue to explore the documentation and join the Configu
[Discord channel](https://discord.com/invite/cjSBxnB9z8), where you can ask questions and get help from the Configu
team and other community members.
# V1 Migration Guide
Source: https://docs.configu.com/guides/v1-migration
This guide is intended to help with migration to v1.
## Breaking Changes
### `Cfgu` format changes
V1 introduces several breaking changes to `.cfgu` files. Below is a list of the breaking changes and how to update your `.cfgu` files.
#### `Cfgu` property changes
* The `type` property has been removed and replaced with the [new `test` property](#new-cfgu-property-test). [View migration examples below](#new-cfgu-property-test).
* The `options` property has been renamed to `enum` to better reflect its purpose.
* The `depends` property has been removed. If you need to replicate it, you can use the [new `test` property](#new-cfgu-property-test).
* The `labels` property has been renamed to `label`.
* The `template` property has been removed. If you need to replicate it, you can use the [new `const` property](#new-cfgu-property-const). [View migration examples below](#new-cfgu-property-const).
#### `.cfgu` file structure change
The file structure of `.cfgu` files has significantly changed to provide a more robust structure.
To update a `.cfgu` file to the new structure, the `Cfgu` declarations need to be moved under the `keys` property.
We will provide an example of how to migrate this example `.cfgu` file:
```yaml example.cfgu.yaml
$schema: https://files.configu.com/schema/.cfgu.json
NODE_ENV:
description: Defines the environment in which the application runs
type: String
options:
- development
- production
- test
default: development
LOG_LEVEL:
description: Defines the level of logs to be recorded
type: String
options:
- error
- warn
- info
- verbose
- debug
- silly
default: info
SERVICE_ENDPOINT:
description: Defines the endpoint for the service
type: URL
required: true
AWS_REGION:
description: Defines the AWS region for the service
type: AWSRegion
default: us-east-1
```
```json example.cfgu.json
{
"$schema": "https://files.configu.com/schema/.cfgu.json",
"NODE_ENV": {
"description": "Defines the environment in which the application runs",
"type": "String",
"options": ["development", "production", "test"],
"default": "development"
},
"LOG_LEVEL": {
"description": "Defines the level of logs to be recorded",
"type": "String",
"options": ["error", "warn", "info", "verbose", "debug", "silly"],
"default": "info"
},
"SERVICE_ENDPOINT": {
"description": "Defines the endpoint for the service",
"type": "URL",
"required": true
},
"AWS_REGION": {
"description": "Defines the AWS region for the service",
"type": "AWSRegion",
"default": "us-east-1"
}
}
```
After migration:
```yaml example.cfgu.yaml
$schema: https://files.configu.com/schema/.cfgu.json
keys:
NODE_ENV:
description: Defines the environment in which the application runs
test: expect($.value).to.be.a('string')
enum:
- development
- production
- test
default: development
LOG_LEVEL:
description: Defines the level of logs to be recorded
test: expect($.value).to.be.a('string')
enum:
- error
- warn
- info
- verbose
- debug
- silly
default: info
SERVICE_ENDPOINT:
description: Defines the endpoint for the service
test: validator.isURL($.value)
required: true
AWS_REGION:
description: Defines the AWS region for the service
enum:
- af-south-1
- ap-east-1
- ap-northeast-1
- ap-northeast-2
- ap-northeast-3
- ap-south-1
- ap-southeast-1
- ap-southeast-2
- ca-central-1
- cn-north-1
- cn-northwest-1
- eu-central-1
- eu-north-1
- eu-south-1
- eu-west-1
- eu-west-2
- eu-west-3
- me-south-1
- sa-east-1
- us-east-1
- us-east-2
- us-gov-east-1
- us-gov-west-1
- us-west-1
- us-west-2
default: us-east-1
```
```json example.cfgu.json
{
"$schema": "https://files.configu.com/schema/.cfgu.json",
"keys": {
"NODE_ENV": {
"description": "Defines the environment in which the application runs",
"test": "expect($.value).to.be.a('string')",
"enum": ["development", "production", "test"],
"default": "development"
},
"LOG_LEVEL": {
"description": "Defines the level of logs to be recorded",
"test": "expect($.value).to.be.a('string')",
"enum": ["error", "warn", "info", "verbose", "debug", "silly"],
"default": "info"
},
"SERVICE_ENDPOINT": {
"description": "Defines the endpoint for the service",
"test": "validator.isURL($.value)",
"required": true
},
"AWS_REGION": {
"description": "Defines the AWS region for the service",
"enum": [
"af-south-1",
"ap-east-1",
"ap-northeast-1",
"ap-northeast-2",
"ap-northeast-3",
"ap-south-1",
"ap-southeast-1",
"ap-southeast-2",
"ca-central-1",
"cn-north-1",
"cn-northwest-1",
"eu-central-1",
"eu-north-1",
"eu-south-1",
"eu-west-1",
"eu-west-2",
"eu-west-3",
"me-south-1",
"sa-east-1",
"us-east-1",
"us-east-2",
"us-gov-east-1",
"us-gov-west-1",
"us-west-1",
"us-west-2"
],
"default": "us-east-1"
}
}
}
```
### CLI changes
#### upsert command config assignment flag changes
The `--config, -c` flag has been renamed to `--kv` to avoid clashes with the new [`--config` global flag](#cli-global-config-flag). Replace all occurrences of `--config` with `--kv` to align with this updated naming convention.
A new method for declaring key-value pairs has also been introduced using the `-k`/`--key` and `-v`/`--value` flags. These flags must be used in sequence, with each key matched to the corresponding value provided immediately after. Keys without matching values will result in the deletion of their corresponding values.
For example, the following command:
```bash
configu upsert --store 'my-store' --set '' --schema start.cfgu.yaml \
-k GREETING \
-k SUBJECT \
-v configu
```
Will:
* Delete the value of `GREETING`.
* Set the value of `SUBJECT` to `configu`.
These changes aim to improve clarity and prevent naming conflicts while providing flexibility for key-value management.
#### Upsert command import flag removal
The `--import` flag has been removed from the CLI upsert command.
#### Export command filtering flags changes
The following flags have been removed in favor of the new [`--filter`](/interfaces/cli/ref#configu-export) flag along with how they can be replaced with `--filter`:
* `--pick-label`
```bash
--filter '$.labels.includes("my-label") === true'
```
* `--omit-label`
```bash
--filter '$.labels.includes("my-label") === false'
```
* `--pick-key`
```bash
--filter '$.key === "my-key"'
```
* `--omit-key`
```bash
--filter '$.key !== "my-key"'
```
* `--pick-hidden`
```bash
--filter '$.cfgu.hidden === true'
```
* `--omit-hidden`
```bash
--filter '!$.cfgu.hidden !== true'
```
* `--pick-empty`
```bash
--filter '$.origin === "empty"'
```
* `--omit-empty`
```bash
--filter '$.origin !== "empty"'
```
#### Export command template input flag removal
The `--template-input` flag has been removed. You can instead adjust the input as needed via the `ConfigExpression` utilities and mutate the `$.configs` (provided as an object) context input to whatever you need.
### `.configu` file changes
The `cache` property has been renamed to `backup` to more accurately reflect its purpose. Replace all occurrences of `cache` with `backup` to reflect the new naming convention.
### Introduction of type coercion
V1 introduces type coercion to Configu. During evaluation, Configu will attempt to coerce values from ConfigStores to their expected type. This feature is intended to make Configu more flexible and easier to use.
Type coercion affects:
* All instances of config values in `ConfigExpressions` are coerced to the expected type (`string`, `number`, `boolean`, `object`, `array`). You can access the value as it's stored via `storedValue`.
* The Configu CLI Eval command returns the coerced value in the output.
* The Configu CLI Export command receives the coerced value as input from Eval command which affects:
* The `--format` flag which will now receive the coerced value as input and appropriately formats it.
* All instances of `ConfigExpressions` usages by `--filter`, `--template`, `--map`, `--reduce`, `--sort` flags which will now receive the coerced value as input.
* The Configu Proxy export route which will now coerce values to the expected type.
## Upgrading Configu CLI
To use the latest Configu CLI, you can use the following command:
```shell Linux
curl https://files.configu.com/cli/install.sh | sh
```
```shell MacOS
curl https://files.configu.com/cli/install.sh | sh
```
```powershell Windows
irm https://files.configu.com/cli/install.ps1 | iex
```
## Upgrading Configu Proxy
Install the latest `configu/proxy` docker image.
## New Features
V1 introduces several new features to Configu. Below is a list of the new features and how to use them.
### `ConfigExpressions`
V1 introduces a new feature called `ConfigExpressions`. `ConfigExpressions` allow you to write dynamic values with certain features like string interpolation, arithmetic operations, and more. All features that support `ConfigExpressions` have their own injected context that can withing the `ConfigExpressions` for evaluation.
The `ConfigExpressions` contexts include the following libraries:
* [lodash](https://lodash.com) for various utility functions. Use `_` within the `ConfigExpression` to access lodash functions.
* [validator.js](https://github.com/validatorjs/validator.js) for string validations. Use `validator` within the `ConfigExpression` to access validator.js functions.
* The [JSONSchema utility class](https://github.com/configu/configu/tree/main/packages/sdk/src/expressions/JSONSchema.ts) for JSON schema validations. Use `JSONSchema` or `jsonschema` within the `ConfigExpression` to access the utility class.
* [Zod](https://zod.dev/) for schema validations with static type inference. Use `z` within the `ConfigExpression` to access Zod functions.
* [Chai](https://github.com/chaijs/chai) for assertions functions. Use `assert`, `expect`, and `should` respectively within the `ConfigExpression` to access Chai functions.
The following features support `ConfigExpressions`:
* [The new `test` `Cfgu` property](/interfaces/.cfgu#properties)
* [The new `const` `Cfgu` property](/interfaces/.cfgu#properties)
* [The `.configu` file](/interfaces/.configu#environment-variables)
* [The CLI export `filter` flag](/interfaces/cli/ref#configu-export)
* [The CLI export `template` flag](/interfaces/cli/ref#configu-export)
Example usages of `ConfigExpressions`:
`test` `Cfgu` property:
```yaml
keys:
MY_STRING:
test: expect($.value).to.be.a('string')
```
The CLI export `filter` flag:
```bash
configu eval --store my-store --set '' --schema ./tmp/schemas2/start.cfgu.yaml | configu export --filter '$.origin === "empty"' --filter '$.labels.includes("my-label") === true'
```
The CLI export `template` flag, example template `.env` file:
```.env
SUBJECT={{SUBJECT}}
GREETING={{toUpper(GREETING)}}
```
### New `Cfgu` property `test`
The `test` property is a new property that allows you to write `ConfigExpressions` to validate the value of a key. It replaces the `type` property which was removed due to its limited functionality.
Here are a few examples of how `test` can be used in place of `type`
String type validation via Chai assertion:
```yaml
keys:
MY_KEY:
test: expect($.value).to.be.a('string')
```
Boolean type validation via validator.js
```yaml
keys:
MY_KEY:
test: validator.isBoolean($.storedValue)
```
Example of using `test` in place of `depends`:
```yaml
keys:
ENABLE_FEATURE:
test: validator.isBoolean($.storedValue)
MY_KEY:
test:
- "$.configs.ENABLE_FEATURE.value ? expect($.value).to.be.a('string') : true"
```
### New `Cfgu` property `const`
The `const` property is a new property that allows you to write `ConfigExpressions` to set a constant value for a key.
Example usage of `const` instead of `template`:
```yaml
keys:
PORT:
default: 1234
HOST:
default: localhost
CONNECTION_STRING:
const: '`${$.configs.HOST.value}:${$.configs.PORT.value}`'
test: 'validator.isURL($.value, {require_host: true, require_port: true})'
```
### Default `ConfigStore`
You can now designate a `ConfigStore` as the default by adding the `default` property to its configuration and setting it to `true`. This default will be used whenever a `ConfigStore` is omitted as an input in actions performed using Configu's high-level interfaces.
If your `.configu` file contains only a single `ConfigStore`, it will be automatically detected and treated as the default.
Example definition of a default `ConfigStore` in a `.configu` file:
```yaml
stores:
json-store:
type: json-file
configuration:
path: path/to/file1.json
default-json-store:
type: json-file
default: true
configuration:
path: path/to/file2.json
```
### CLI global `--config` flag
The `--config` flag is a new global flag that allows you to specify a path to `.configu` file to use for all commands. This flag is useful when you want to use a specific `.configu` file that you want to use for all commands.
### CLI `.configu` auto-detection
The CLI now automatically recursively searches for `.configu` files from the current working directory upwards to the home directory and uses the first one found for all commands when the `--config` flag is not provided.
### CLI eval command defaults flag
The new `--defaults` flag can now be used to evaluate default value from a ConfigSchema and skip querying a ConfigStore.
## Other changes
### `@configu/node` and `@configu/browser` removal
Any and all uses of these packages are no longer supported. We encourage all users of these packages to utilize [`@configu/cli`](/interfaces/cli/overview) or [`@configu/proxy`](/interfaces/proxy/overview) depending on your requirements. All ConfigStore implementations have been moved to `@configu/integrations`.
### `@configu/lib` removal
Superseded by `@configu/common` which is a package that provides shared functionality for the higher-level interfaces.
### `@configu/ts` removal
Superseded by `@configu/sdk`.
### Introduction of `@configu/integrations`
A new package that contains all ConfigStore implementations and libraries that extend the `ConfigExpressions` functionality which are decoupled from the core `@configu/sdk` package. This package is intended to be used by higher-level configu interfaces such as the CLI and proxy.
# Overview
Source: https://docs.configu.com/integrations/overview
Learn how to integrate Configu into your project.
export const IntegrationCard = ({data: {label, icon, docs, description = ''}}) => } href={`/${docs}`}>
{description}
;
export const integrations = {
configu: {
enabled: true,
label: 'Configu Platform',
icon: 'https://raw.githubusercontent.com/configu/configu/main/docs/images/icon/icon.svg',
docs: 'integrations/store/configu/overview',
pages: ['integrations/store/configu/config-explorer', 'integrations/store/configu/config-editor', 'integrations/store/configu/config-history', 'integrations/store/configu/config-compare', 'integrations/store/configu/approval-queue', 'integrations/store/configu/audit-logs', 'integrations/store/configu/webhooks', 'integrations/store/configu/integrations', 'integrations/store/configu/authorization', 'integrations/store/configu/members', 'integrations/store/configu/tokens', 'integrations/store/configu/settings', 'integrations/store/configu/billing'],
group: ['ConfigStore', 'Configu'],
store: {
base: 'Configu',
type: 'configu',
code: '/packages/ts/src/stores/Configu.ts'
},
links: {
website: 'https://configu.com',
auth: ''
}
},
'json-file': {
label: 'JSON File',
icon: 'https://api.iconify.design/logos:json.svg?width=24&height=24',
docs: 'integrations/store/file/json-file',
group: ['ConfigStore', 'File'],
store: {
base: 'File',
type: 'json-file',
code: '/packages/node/src/stores/JsonFile.ts'
},
links: {
website: 'https://www.json.org/json-en.html'
}
},
'csv-file': {
label: 'CSV File',
icon: 'https://api.iconify.design/gala:file-csv.svg?width=24&height=24',
docs: 'integrations/store/file/csv-file',
group: ['ConfigStore', 'File'],
store: {
base: 'File',
type: 'csv-file',
code: '/packages/node/src/stores/CsvFile.ts'
},
links: {
website: 'https://en.wikipedia.org/wiki/Comma-separated_values'
}
},
'xml-file': {
label: 'XML File',
icon: 'https://api.iconify.design/vscode-icons:file-type-xml.svg?width=24&height=24',
docs: 'integrations/store/file/xml-file',
group: ['ConfigStore', 'File'],
store: {
base: 'File',
type: 'xml-file',
code: '/packages/node/src/stores/XmlFile.ts'
},
links: {
website: 'https://en.wikipedia.org/wiki/XML'
}
},
'ini-file': {
label: 'INI File',
icon: 'https://api.iconify.design/vscode-icons:file-type-ini.svg?width=24&height=24',
docs: 'integrations/store/file/ini-file',
group: ['ConfigStore', 'File'],
store: {
base: 'File',
type: 'ini-file',
code: '/packages/node/src/stores/IniFile.ts'
},
links: {
website: 'https://en.wikipedia.org/wiki/INI_file'
}
},
'toml-file': {
label: 'TOML File',
icon: 'https://api.iconify.design/logos:toml.svg?width=24&height=24',
docs: 'integrations/store/file/toml-file',
group: ['ConfigStore', 'File'],
store: {
base: 'File',
type: 'toml-file',
code: '/packages/node/src/stores/TomlFile.ts'
},
links: {
website: 'https://toml.io'
}
},
sqlite: {
label: 'SQLite',
icon: 'https://api.iconify.design/devicon:sqlite.svg?width=24&height=24',
docs: 'integrations/store/db/sqlite',
group: ['ConfigStore', 'Database'],
store: {
base: 'ORM',
type: 'sqlite',
code: '/packages/node/src/stores/SQLite.ts'
},
links: {
website: 'https://www.sqlite.org'
}
},
mysql: {
label: 'MySQL',
icon: 'https://api.iconify.design/logos:mysql-icon.svg?width=24&height=24',
docs: 'integrations/store/db/mysql',
group: ['ConfigStore', 'Database'],
store: {
base: 'ORM',
type: 'mysql',
code: '/packages/node/src/stores/MySQL.ts'
},
links: {
website: 'https://www.mysql.com'
}
},
mariadb: {
label: 'MariaDB',
icon: 'https://api.iconify.design/logos:mariadb-icon.svg?width=24&height=24',
docs: 'integrations/store/db/mariadb',
group: ['ConfigStore', 'Database'],
store: {
base: 'ORM',
type: 'mariadb',
code: '/packages/node/src/stores/MariaDB.ts'
},
links: {
website: 'https://mariadb.org'
}
},
postgresql: {
label: 'PostgreSQL',
icon: 'https://api.iconify.design/logos:postgresql.svg?width=24&height=24',
docs: 'integrations/store/db/postgresql',
group: ['ConfigStore', 'Database'],
store: {
base: 'ORM',
type: 'postgresql',
code: '/packages/node/src/stores/PostgresSQL.ts'
},
links: {
website: 'https://www.postgresql.org'
}
},
cockroachdb: {
label: 'CockroachDB',
icon: 'https://api.iconify.design/simple-icons:cockroachlabs.svg?width=24&height=24',
docs: 'integrations/store/db/cockroachdb',
group: ['ConfigStore', 'Database'],
store: {
base: 'ORM',
type: 'cockroachdb',
code: '/packages/node/src/stores/CockroachDB.ts'
},
links: {
website: 'https://www.cockroachlabs.com'
}
},
mssql: {
label: 'Microsoft SQL Server',
icon: 'https://api.iconify.design/devicon:microsoftsqlserver.svg?width=24&height=24',
docs: 'integrations/store/db/mssql',
group: ['ConfigStore', 'Database'],
store: {
base: 'ORM',
type: 'mssql',
code: '/packages/node/src/stores/MSSQL.ts'
},
links: {
website: 'https://www.microsoft.com/en-us/sql-server'
}
},
'hashicorp-vault': {
label: 'HashiCorp Vault',
icon: 'https://api.iconify.design/logos:vault-icon.svg?width=24&height=24',
docs: 'integrations/store/secret/hashicorp-vault',
group: ['ConfigStore', 'Secret'],
store: {
base: 'KeyValue',
type: 'hashicorp-vault',
code: '/packages/node/src/stores/HashiCorpVault.ts'
},
links: {
website: 'https://www.vaultproject.io'
}
},
'aws-secrets-manager': {
label: 'AWS Secrets Manager',
icon: 'https://api.iconify.design/logos:aws-secrets-manager.svg?width=24&height=24',
docs: 'integrations/store/secret/aws-secrets-manager',
group: ['ConfigStore', 'Secret'],
store: {
base: 'KeyValue',
type: 'aws-secrets-manager',
code: '/packages/node/src/stores/AWSSecretsManager.ts'
},
links: {
website: 'https://aws.amazon.com/secrets-manager'
}
},
'azure-key-vault': {
label: 'Azure Key Vault',
icon: 'https://symbols.getvecta.com/stencil_28/41_key-vault.2876abee6f.svg',
docs: 'integrations/store/secret/azure-key-vault',
group: ['ConfigStore', 'Secret'],
store: {
base: 'KeyValue',
type: 'azure-key-vault',
code: '/packages/node/src/stores/AzureKeyVault.ts'
},
links: {
website: 'https://azure.microsoft.com/en-us/services/key-vault'
}
},
'gcp-secret-manager': {
label: 'GCP Secret Manager',
icon: 'https://www.svgrepo.com/download/375492/secret-manager.svg',
docs: 'integrations/store/secret/gcp-secret-manager',
group: ['ConfigStore', 'Secret'],
store: {
base: 'KeyValue',
type: 'gcp-secret-manager',
code: '/packages/node/src/stores/GCPSecretManager.ts'
},
links: {
website: 'https://cloud.google.com/secret-manager'
}
},
'kubernetes-secret': {
label: 'Kubernetes Secret',
icon: 'https://api.iconify.design/logos:kubernetes.svg?width=24&height=24',
docs: 'integrations/store/secret/kubernetes-secret',
group: ['ConfigStore', 'Secret'],
store: {
base: 'KeyValue',
type: 'kubernetes-secret',
code: '/packages/node/src/stores/KubernetesSecret.ts'
},
links: {
website: 'https://kubernetes.io/docs/concepts/configuration/secret'
}
},
launchdarkly: {
label: 'LaunchDarkly',
icon: 'https://api.iconify.design/logos:launchdarkly-icon.svg?width=24&height=24',
docs: 'integrations/store/ff/launchdarkly',
group: ['ConfigStore', 'Feature Flag'],
store: {
base: 'OpenFeature',
type: 'launchdarkly',
code: '/packages/node/src/stores/LaunchDarkly.ts'
},
links: {
website: 'https://launchdarkly.com'
}
},
'cloudbees-feature-management': {
label: 'CloudBees Feature Management',
icon: 'https://api.iconify.design/simple-icons:cloudbees.svg?width=24&height=24',
docs: 'integrations/store/ff/cloudbees-feature-management',
group: ['ConfigStore', 'Feature Flag'],
store: {
base: 'OpenFeature',
type: 'cloudbees-feature-management',
code: '/packages/node/src/stores/CloudBeesFeatureManagement.ts'
},
links: {
website: 'https://www.cloudbees.com/products/feature-management'
}
},
split: {
label: 'Split',
icon: 'https://splitsoftware.gallerycdn.vsassets.io/extensions/splitsoftware/splitio/1.0.1/1686315163828/Microsoft.VisualStudio.Services.Icons.Default',
docs: 'integrations/store/ff/split',
group: ['ConfigStore', 'Feature Flag'],
store: {
base: 'OpenFeature',
type: 'split',
code: '/packages/node/src/stores/Split.ts'
},
links: {
website: 'https://www.split.io'
}
},
'in-memory': {
label: 'In-Memory',
icon: 'https://api.iconify.design/ic:memory.svg?width=24&height=24',
docs: 'integrations/store/other/in-memory',
group: ['ConfigStore', 'Other'],
store: {
type: 'in-memory',
code: '/packages/ts/src/stores/InMemory.ts'
},
links: {
website: 'https://en.wikipedia.org/wiki/In-memory_database'
}
},
'aws-parameter-store': {
label: 'AWS Systems Manager Parameter Store',
icon: 'https://api.iconify.design/logos:aws-systems-manager.svg?width=24&height=24',
docs: 'integrations/store/other/aws-parameter-store',
group: ['ConfigStore', 'Other'],
store: {
base: 'KeyValue',
type: 'aws-parameter-store',
code: '/packages/node/src/stores/AWSParameterStore.ts'
},
links: {
website: 'https://aws.amazon.com/systems-manager/features/#Parameter_Store'
}
},
localforage: {
label: 'LocalForage',
icon: 'https://api.iconify.design/iconoir:db.svg?width=24&height=24',
docs: 'integrations/store/other/localforage',
group: ['ConfigStore', 'Other'],
store: {
base: 'KeyValue',
type: 'localforage',
code: '/packages/browser/src/stores/LocalForage.ts'
},
links: {
website: 'https://localforage.github.io/localForage'
}
},
docker: {
label: 'Docker',
icon: 'https://api.iconify.design/logos:docker-icon.svg?width=24&height=24',
docs: 'integrations/container/docker',
group: ['Container'],
links: {
website: 'https://www.docker.com'
}
},
'docker-compose': {
label: 'Docker Compose',
icon: 'https://api.iconify.design/logos:docker-icon.svg?width=24&height=24',
docs: 'integrations/container/docker-compose',
group: ['Container'],
links: {
website: 'https://docs.docker.com/compose'
}
},
kubernetes: {
label: 'Kubernetes',
icon: 'https://api.iconify.design/logos:kubernetes.svg?width=24&height=24',
docs: 'integrations/container/kubernetes',
group: ['Container'],
links: {
website: 'https://kubernetes.io'
}
},
'aws-ecs': {
label: 'AWS ECS',
icon: 'https://api.iconify.design/logos:aws-ecs.svg?width=24&height=24',
docs: 'integrations/container/aws-ecs',
group: ['Container'],
links: {
website: 'https://aws.amazon.com/ecs'
}
},
jenkins: {
label: 'Jenkins',
icon: 'https://api.iconify.design/logos:jenkins.svg?width=24&height=24',
docs: 'integrations/cicd/jenkins',
group: ['CI/CD'],
links: {
website: 'https://www.jenkins.io'
}
},
'github-actions': {
label: 'GitHub Actions',
icon: 'https://api.iconify.design/logos:github-actions.svg?width=24&height=24',
docs: 'integrations/cicd/github-actions',
group: ['CI/CD'],
links: {
website: 'https://github.com/features/actions'
}
},
circleci: {
label: 'CircleCI',
icon: 'https://api.iconify.design/logos:circleci.svg?width=24&height=24',
docs: 'integrations/cicd/circleci',
group: ['CI/CD'],
links: {
website: 'https://circleci.com'
}
},
'gitlab-cicd': {
label: 'GitLab CI/CD',
icon: 'https://api.iconify.design/logos:gitlab.svg?width=24&height=24',
docs: 'integrations/cicd/gitlab-cicd',
group: ['CI/CD'],
links: {
website: 'https://docs.gitlab.com/ee/ci'
}
},
terraform: {
label: 'Terraform',
icon: 'https://api.iconify.design/logos:terraform-icon.svg?width=24&height=24',
docs: 'integrations/iac/terraform',
group: ['Infrastructure-as-Code'],
links: {
website: 'https://www.terraform.io'
}
},
helm: {
label: 'Helm',
icon: 'https://api.iconify.design/logos:helm.svg?width=24&height=24',
docs: 'integrations/iac/helm',
group: ['Infrastructure-as-Code'],
links: {
website: 'https://helm.sh'
}
},
'aws-cdk': {
label: 'AWS CDK',
icon: 'https://api.iconify.design/logos:aws-cloudformation.svg?width=24&height=24',
docs: 'integrations/iac/aws-cdk',
group: ['Infrastructure-as-Code'],
links: {
website: 'https://aws.amazon.com/cdk'
}
},
pulumi: {
label: 'Pulumi',
icon: 'https://api.iconify.design/logos:pulumi-icon.svg?width=24&height=24',
docs: 'integrations/iac/pulumi',
group: ['Infrastructure-as-Code'],
links: {
website: 'https://www.pulumi.com'
}
},
vite: {
label: 'Vite',
icon: 'https://api.iconify.design/logos:vitejs.svg?width=24&height=24',
docs: 'integrations/framework/web/vite',
group: ['Framework', 'Web'],
framework: {},
links: {
website: 'https://vitejs.dev',
env: 'https://vitejs.dev/guide/env-and-mode.html'
}
},
nextjs: {
label: 'Next.js',
icon: 'https://api.iconify.design/logos:nextjs-icon.svg?width=24&height=24',
docs: 'integrations/framework/web/nextjs',
group: ['Framework', 'Web'],
framework: {},
links: {
website: 'https://nextjs.org',
env: 'https://nextjs.org/docs/pages/building-your-application/configuring/environment-variables'
}
},
remix: {
label: 'Remix',
icon: 'https://api.iconify.design/logos:remix-icon.svg?width=24&height=24',
docs: 'integrations/framework/web/remix',
group: ['Framework', 'Web'],
framework: {},
links: {
website: 'https://remix.run',
env: 'https://remix.run/docs/en/main/guides/envvars'
}
},
gatsby: {
label: 'Gatsby',
icon: 'https://api.iconify.design/logos:gatsby.svg?width=24&height=24',
docs: 'integrations/framework/web/gatsby',
group: ['Framework', 'Web'],
framework: {},
links: {
website: 'https://www.gatsbyjs.com',
env: 'https://www.gatsbyjs.com/docs/how-to/local-development/environment-variables'
}
},
astro: {
label: 'Astro',
icon: 'https://api.iconify.design/logos:astro-icon.svg?width=24&height=24',
docs: 'integrations/framework/web/astro',
group: ['Framework', 'Web'],
framework: {},
links: {
website: 'https://astro.build',
env: 'https://docs.astro.build/en/guides/environment-variables/'
}
},
nuxt: {
label: 'Nuxt',
icon: 'https://api.iconify.design/logos:nuxt-icon.svg?width=24&height=24',
docs: 'integrations/framework/web/nuxt',
group: ['Framework', 'Web'],
framework: {},
links: {
website: 'https://nuxtjs.org',
env: 'https://nuxt.com/docs/guide/going-further/runtime-config#environment-variables'
}
},
sveltekit: {
label: 'SvelteKit',
icon: 'https://api.iconify.design/logos:svelte-icon.svg?width=24&height=24',
docs: 'integrations/framework/web/sveltekit',
group: ['Framework', 'Web'],
framework: {},
links: {
website: 'https://kit.svelte.dev',
env: 'https://kit.svelte.dev/docs/adapter-node#environment-variables'
}
},
express: {
label: 'Express',
icon: 'https://api.iconify.design/simple-icons:express.svg?width=24&height=24',
docs: 'integrations/framework/backend/express',
group: ['Framework', 'Backend', 'Node.js'],
framework: {
lang: 'Node.js'
},
links: {
website: 'https://expressjs.com'
}
},
nestjs: {
label: 'NestJS',
icon: 'https://api.iconify.design/logos:nestjs.svg?width=24&height=24',
docs: 'integrations/framework/backend/nestjs',
group: ['Framework', 'Backend', 'Node.js'],
framework: {
lang: 'Node.js'
},
links: {
website: 'https://nestjs.com',
env: 'https://docs.nestjs.com/techniques/configuration'
}
},
fastify: {
label: 'Fastify',
icon: 'https://api.iconify.design/logos:fastify-icon.svg?width=24&height=24',
docs: 'integrations/framework/backend/fastify',
group: ['Framework', 'Backend', 'Node.js'],
framework: {
lang: 'Node.js'
},
links: {
website: 'https://www.fastify.io'
}
},
fastapi: {
label: 'FastAPI',
icon: 'https://api.iconify.design/logos:fastapi-icon.svg?width=24&height=24',
docs: 'integrations/framework/backend/fastapi',
group: ['Framework', 'Backend', 'Python'],
framework: {
lang: 'Python'
},
links: {
website: 'https://fastapi.tiangolo.com',
env: 'https://fastapi.tiangolo.com/advanced/settings'
}
},
django: {
label: 'Django',
icon: 'https://api.iconify.design/logos:django-icon.svg?width=24&height=24',
docs: 'integrations/framework/backend/django',
group: ['Framework', 'Backend', 'Python'],
framework: {
lang: 'Python'
},
links: {
website: 'https://www.djangoproject.com',
env: ''
}
},
flask: {
label: 'Flask',
icon: 'https://api.iconify.design/simple-icons:flask.svg?width=24&height=24',
docs: 'integrations/framework/backend/flask',
group: ['Framework', 'Backend', 'Python'],
framework: {
lang: 'Python'
},
links: {
website: 'https://flask.palletsprojects.com',
env: 'https://flask.palletsprojects.com/en/latest/config/'
}
},
laravel: {
label: 'Laravel',
icon: 'https://api.iconify.design/logos:laravel.svg?width=24&height=24',
docs: 'integrations/framework/backend/laravel',
group: ['Framework', 'Backend', 'PHP'],
framework: {
lang: 'PHP'
},
links: {
website: 'https://laravel.com',
env: 'https://laravel.com/docs/8.x/configuration'
}
},
symfony: {
label: 'Symfony',
icon: 'https://api.iconify.design/logos:symfony.svg?width=24&height=24',
docs: 'integrations/framework/backend/symfony',
group: ['Framework', 'Backend', 'PHP'],
framework: {
lang: 'PHP'
},
links: {
website: 'https://symfony.com',
env: 'https://symfony.com/doc/current/configuration.html'
}
},
rails: {
label: 'Rails',
icon: 'https://api.iconify.design/logos:rails.svg?width=24&height=24',
docs: 'integrations/framework/backend/rails',
group: ['Framework', 'Backend', 'Other'],
framework: {
lang: 'Ruby'
},
links: {
website: 'https://rubyonrails.org',
env: 'https://guides.rubyonrails.org/configuring.html'
}
},
spring: {
label: 'Spring',
icon: 'https://api.iconify.design/logos:spring-icon.svg?width=24&height=24',
docs: 'integrations/framework/backend/spring',
group: ['Framework', 'Backend', 'Other'],
framework: {
lang: 'Java'
},
links: {
website: 'https://spring.io',
env: 'https://docs.spring.io/spring-boot/docs/current/reference/html/features.html#features.external-config'
}
},
aspnet: {
label: 'ASP.NET',
icon: 'https://api.iconify.design/logos:dotnet.svg?width=24&height=24',
docs: 'integrations/framework/backend/aspnet',
group: ['Framework', 'Backend', 'Other'],
framework: {
lang: 'C#'
},
links: {
website: 'https://dotnet.microsoft.com/apps/aspnet'
}
},
wordpress: {
label: 'WordPress',
icon: 'https://api.iconify.design/logos:wordpress-icon.svg?width=24&height=24',
docs: 'integrations/framework/backend/wordpress',
group: ['Framework', 'Backend', 'CMS'],
framework: {
sub: 'CMS'
},
links: {
website: 'https://wordpress.org'
}
},
strapi: {
label: 'Strapi',
icon: 'https://api.iconify.design/logos:strapi-icon.svg?width=24&height=24',
docs: 'integrations/framework/backend/strapi',
group: ['Framework', 'Backend', 'CMS'],
framework: {
sub: 'CMS'
},
links: {
website: 'https://strapi.io'
}
},
expo: {
label: 'Expo',
icon: 'https://api.iconify.design/logos:expo-icon.svg?width=24&height=24',
docs: 'integrations/framework/app/expo',
group: ['Framework', 'App', 'Mobile'],
framework: {
sub: 'Mobile'
},
links: {
website: 'https://expo.dev',
env: 'https://docs.expo.dev/workflow/configuration'
}
},
'react-native': {
label: 'React Native',
icon: 'https://api.iconify.design/logos:react.svg?width=24&height=24',
docs: 'integrations/framework/app/react-native',
group: ['Framework', 'App', 'Mobile'],
framework: {
sub: 'Mobile'
},
links: {
website: 'https://reactnative.dev',
env: ''
}
},
flutter: {
label: 'Flutter',
icon: 'https://api.iconify.design/logos:flutter.svg?width=24&height=24',
docs: 'integrations/framework/app/flutter',
group: ['Framework', 'App', 'Mobile'],
framework: {
sub: 'Mobile'
},
links: {
website: 'https://flutter.dev',
env: ''
}
},
electron: {
label: 'Electron',
icon: 'https://api.iconify.design/logos:electron.svg?width=24&height=24',
docs: 'integrations/framework/app/electron',
group: ['Framework', 'App', 'Desktop'],
framework: {
sub: 'Desktop'
},
links: {
website: 'https://www.electronjs.org',
env: 'https://www.electronjs.org/docs/api/environment-variables'
}
}
};
export const Construction = () =>
This section is under construction and will be ready soon. Thanks for your patience! 🚧
;
## ConfigStore
[ConfigStores](/introduction/concepts#configstore) are pivotal in managing your configurations effectively. Choose from a variety of storage solutions to fit your project's needs.
In case you don't find a `ConfigStore` that meets your requirements, Configu allows you to easily create your own by
[implementing a simple abstract class](https://github.com/configu/configu/blob/main/packages/sdk/src/ConfigStore.ts)
with `get` and `set` methods. This flexibility empowers you to extend Configu and tailor it to your specific
configuration management needs. Please also consider contributing your custom `ConfigStore` back to the community by
submitting a pull request to the [Configu GitHub repository](https://github.com/configu/configu).
### Configu
Enjoy the full power of Configu with our hosted platform.
Authorization, versioning, auditing, visualizations, and more.
),
}}
/>
{/* todo: add other integration when ready, set - enable: true on index when ready */}
# Approval Queue
Source: https://docs.configu.com/integrations/store/configu/approval-queue
The Configs Request tab displays all the [protected sets](/integrations/store/configu/settings#protected-sets) and indicates any pending change requests made by members of the organization.

Admins of the organization can view the pending requests queue for each protected set and begin a review process to approve or reject each request. As the reviewer approves change requests, the differences between the current and requested values are updated based on their actions but commits only upon reaching the summary stage.

You can return to previous change requests by clicking the `previous` button. This action resets the decision in the
previous request.
The `REQUEST` tab is highlighted with a blue dot indicator when there is at least one pending request.
## Summary stage - Aggregated Diff
At any point after the first request, the reviewer may click `aggregated diff` to reach a summary view to review all the approved changes in bulk while also being shown the accumulation of all the approved requests. This happens automatically upon resolving the final request.

Clicking `upsert` will resolve change requests according to the reviewer's selection and all configs of approved changes are upserted simultaneously. At any later point, the reviewer may return to the approval queue to resolve remaining requests.
Upserts resulting from approval of change requests create `Upsert Config` [audits](/integrations/store/configu/audit-logs). These audits reflect details regarding the original upsert request made by the user who triggered the request along with details regarding the user who approved the request.

# Audit Logs
Source: https://docs.configu.com/integrations/store/configu/audit-logs
Configu's activity logs let you know when changes are made and by whom.
From modifying a configuration to adding a new team member, Configu will generate logs for every action your team members make.
Activity logs record all actions going through the Configu Cloud, including who performed it and when, from which interface, and which CRUD operations were made on configs or sets.
They help you learn:
* Who added or updated a configuration recently
* Which service pulls its latest configurations and when

# Authorization
Source: https://docs.configu.com/integrations/store/configu/authorization
Configu provides role based access control (RBAC) and attribute-based access control (ABAC). Managers (owners and admins) of an organization can assign roles and specific permissions to organization members and tokens according to their requirements.
The usage of roles and attributes depend on the level of granularity needed for access control. Roles are suitable for broad categorization of permissions, streamlining high-level access management for a group of users. Conversely, attributes provide a more tailored, fine-grained approach for specific access control for individual users. Choose roles for simplicity and predefined permissions for groups of users, and attributes for customized, nuanced access control for individual users, or a combination of both based on your organization's need.
RBAC and ABAC are inclusive, meaning that the member/token gets access to resources according to the union of all their respective roles and attributes.
## Default role
The default role applies to all new members. You may change the default role to any one of the predefined or custom roles to match your requirements.


Changing the default role does not change the roles of existing members.Tokens receive a default role of `reader` and are not affected by the default role.
## Predefined roles
Each predefined role is designed as a subset of the following one, providing a logical and hierarchical access control system.
Empower your organization with clear boundaries and well-defined roles that enhance collaboration, maintain security, and optimize productivity.

Predefined roles are immutable and cannot be changed or deleted.
The **Admin** role allows management of members, tokens, roles, webhooks, and organization settings.
## Assign roles
Members and tokens can be assigned a single predefined and any amount of custom roles which give stacking permissions on top of the predefined role permissions. For example:
* User "John Doe" has the "Reader" predefined role and a custom role named "Developer" that has the write permission for the "dev" config set.
* "John Doe" can:
* Read config values of all config sets due to the "Reader" role.
* Write config values to the "dev" config set and all its children due to the "Developer" Role
Keep in mind that predefined roles give global config set permissions. If you want to keep config set permissions fine-grained, you should keep your members with the "Viewer" role and tokens with the "Reader" predefined roles and give them custom roles that give them the specific permissions they need.
To assign roles to your [organization members](/integrations/store/configu/members#manage-member-permissions) or [organization tokens](/integrations/store/configu/tokens#assign-roles-to-a-token), go to their respective pages and edit their roles.
## Creating a custom role
Take control of your organization's access management with our flexible and dynamic custom roles feature.
Every organization is unique, with specific requirements and workflows. That's why we empower you to create custom roles, allowing you to fine-tune access permissions according to your exact need.
1. Go to the **Roles** page under the **Settings** tab.
2. Click the **Create Role** button and provide the role name and role permissions.
3. After adding the role, you will see it listed in the custom roles list.


The **read** permission grants access to read config values of the selected set and its parent sets.
The **write** permission grants access to read and edit config values of the selected set and its child sets.
The **read all** permission grants access to read config values of all sets.
The **write all** permission grants access to read and edit config values of all sets.
Duplicate rules are omitted when creating/updating roles.
Rules can be created for config sets that do not yet exist. This is useful for the following cases:
You want your member or token to have read access to a config set as soon as it's created.
You want to give your member or token the ability to create a config set.
Role names are unique, attempting to use an existing role name including predefined roles will result in an error.
## Updating a custom role


## Deleting a custom role

The deleted role will be unassigned from any member or token that used it.
Custom roles that have been selected as the default role cannot be deleted.
## Assign config attribute
Members can be assigned a config attribute which gives them access to a specific config within a config set.
1. Go to the **Configs** page under the **Explorer** tab.
2. Open a config's action menu and click **Permissions**. Pick one or more members and assign them a desired attribute.
3. After assigning an attribute, the member will be able to access the config with the granted permission.


The **read** permission grants access to read the config value.
The **write** permission grants access to edit the config.
The **manage** permission grants access to edit the config and also assign config attributes to other members.
Tokens cannot be assigned a config attribute.
Only members with the **Admin** and **Owner** role can initially assign attributes.
Attributes are additive, meaning that a member with multiple attributes will have the union of all their permissions.
# Billing
Source: https://docs.configu.com/integrations/store/configu/billing
The billing page allows organization owners to manage their organization's billing plan.
Configu Orchestrator is open-source and free forever. For the Configu Cloud, we offer a generous free Starter plan,
which we expect will be sufficient for many developer teams. On this page, you can view the details of your current
plan and upgrade if needed.
## Subscription Information
Here you can find your subscription information, including the total recurring price, current seat usage, billing interval, and next billing date.

## Current Plan
View your current plan and upgrade it according to your needs.

Click "Upgrade" to select your desired plan. To upgrade to the "Pro" plan, adjust the number of seats, billing interval, and choose the add-ons that match your needs. Click "Upgrade" to proceed. For more details on each plan, visit our [pricing page](https://configu.com/pricing).

After clicking "Upgrade", you will be prompted to provide your billing information, which is used to charge you for the selected plan. See the [billing information](#billing-information) section for more details. Once you provide your billing information and click "Payment", you will be prompted to provide payment information. After a successful charge, your plan will be upgraded.

To modify your plan, navigate to the "Current Plan" section and click "Upgrade." You will be prompted to make your desired changes. After selecting "Update," you will go through a confirmation process where you will see the outcome of your changes. Once confirmed, your plan will be updated immediately.
Please note that any downgrades such as seat removal, changing to a monthly billing interval, or removing add-ons,
will reduce your billing going forward but will not result in a retroactive refund.
If you decide to downgrade to the "Starter" plan, you will retain your current plan until the end of the current billing period. After that, your plan will automatically switch to the "Starter" plan. You can reactivate your subscription at any time before the current billing period ends.
## Billing History
Browse your billing history to track your payments and access invoices.

## Billing Information
View your billing information, including your payment method.

By clicking "Edit", you can update your billing information. Full name, billing email, country, city, region, and postal code are mandatory. If either the company name or Tax ID is provided, both are required.

If you pay via credit card, you can update your card information by clicking "Change Method", which will prompt you to update your card details. If you have any outstanding balances, they will be charged after your payment method has been updated.

# Configs Compare
Source: https://docs.configu.com/integrations/store/configu/config-compare
The Configs Compare feature simplifies the process of comparing configurations between two [sets](/introduction/concepts#configset) in your organization.
By selecting the base set on the left input and choosing another set to compare on the right, you can easily view and analyze the differences.
This feature presents all the keys from both sets, providing a clear and comprehensive overview of the configurations.
In case there are similar keys with varying values between the sets, they are conveniently highlighted. This allows for quick identification and comparison of the variations.

# Configs Editor
Source: https://docs.configu.com/integrations/store/configu/config-editor
The Configs Editor is where you can upsert (create/edit/delete) configs to an existing set or create a new one.
As in the other interfaces (CLI & SDKs), you need to insert the set name (choose an existing one or create a new one) and provide a schema file `.cfgu.json` using any of the methods allowed by the schema source.

Open the selector to view [additional schema options](#available-schema-sources). Once you select a schema, the option you used will be selected the next time you return to the config editor.

Once a set and a schema have been selected, you will be automatically transitioned to the upsert form where you may edit configs.

## Available Schema Sources
### File
You can use any schema file you have on your local machine by dragging and dropping or through the file browser.

### GitHub
Once you've connected your [GitHub App installation](/integrations/store/configu/integrations#github) to your organization, you may select GitHub as a schema source.

Browse available repositories, branches, and schemas to find the schema you want to use. You may view the content of the schema file before selection by using the "View cfgu" action.

Once you find the schema you want to use, click on the row and the content of the cfgu file will be retrieved from GitHub. Recently selected schema files are saved in a "previous files" list available for your convenience. You can select schema files directly from the "previous files" list without selecting a repository.

You will only see repositories that were selected during the GitHub App installation.
By default, the first repository that has a schema file in the default branch is chosen.
By default, when selecting a new repository, the default branch is automatically selected.
If the repositories, branches, and schema files are out of date. Click the "Re-sync" button to fetch the latest data
from GitHub.
If the GitHub app is suspended, the GitHub schema source option will be disabled.
If a selected GitHub schema file is invalid, the row will be disabled. You may update the file in GitHub and click
"Re-sync" to update the list.
### GitLab
Once you've connected your [GitLab App installation](/integrations/store/configu/integrations#gitlab) to your organization, you may select GitLab as a schema source.

Browse available repositories, branches, and schemas to find the schema you want to use similar to the [GitHub schema source](#github).
# Configs Explorer (Dashboard)
Source: https://docs.configu.com/integrations/store/configu/config-explorer
Let's understand how Configu structures and visualizes configurations.
The Configs pages are where you can view and manage your configurations.
The Config Explorer is a dashboard page that shows all the configuration data with a simple visualization.
You organize and view the data in **Sets** (e.g., environments, regions, branches, customers). You can view the details of a configuration in the **Configs** view.
You can also search and filter the data by:
* Set - set name or part of it
* Key - key name or part of it

## Graph View
The Graph view is the default view, and it shows all your [ConfigSets](/introduction/concepts#configset) on a graph, illustrating the relationships between them.

You can right-click any set to open the context menu and perform actions like viewing the configs or configs history, cloning the set, adding a child set, evaluating it, deleting it, focus it, and more.

### Focus Set in Graph View
You can focus on a set by right-clicking on it and selecting the `Focus Set` option.
This action will center the graph starting from the selected set, making it easier to view the set's children.

While focused on a set, you can use the breadcrumbs to navigate back to the root set, parent set, or even a parent's sibling.

## Grid View
The Grid view presents your [Configs](/introduction/concepts#config) in a grid layout. By default, each column represents a ConfigSet, while each row corresponds to a ConfigKey. Within the grid, each cell displays the value of the config within its respective set. Every config cell is interactive, granting access to the config value provided you have the necessary permissions.

Moreover, right-clicking on any cell within the grid reveals a context menu offering relevant actions. For instance, the `All Configs` context menu allows you to reveal all config values, transpose the grid, and revert any modifications made to the view.
Some notable actions include:
* **Pinning**: Pin the selected column or row to the left or top of the grid.
* **Sorting**: Alphabetically or by last update date for columns or rows.
* **History**: View the history of the selected config or set.
* **Create Set**: Creates an empty set.
* **Delete**: Remove the selected config or set.
* **Clone**: Duplicate the selected set.
* **Add Child Set**: Adds a child set.
* **Eval**: Evaluates the selected set.
* **Permissions**: Examine the permissions of the selected set or config.

## Upsert Configs Wizard
The Upsert Configs Wizard is a quick and convenient way to modify configs. You can access the wizard by clicking "Upsert" from the Graph or Grid view.

Select or create a new key, and modify the `Cfgu` according to your needs. Click "Assign values" to proceed.

Select or create a new set and modify the value. You can upsert to multiple sets by clicking "Assign another value" and picking other sets. Click "Upsert Summary" to proceed.

Review the changes from the previous step and confirm the upsert. Click "Upsert Configs" to complete the process.

## Config Set Exporter
The Eval Configs modal is a quick and convenient way to evaluate configs. You can access the modal by clicking "Eval" from the Graph or Grid view or by clicking "Eval Set" from the context menu of a ConfigSet header cell or a ConfigSet node in the Graph view.



Select the set you want to evaluate. If you opened the modal via the "Eval Set" action, the set will be pre-selected. Select your preferred format and toggle whether you want to see empty config values. The formatted evaluation result is displayed in the "Config File" input which you can copy or download by clicking the respective buttons.

Your "Formatting Type" and "Hide empty values" selections are stored and used as defaults for future evaluations.
# Configs History
Source: https://docs.configu.com/integrations/store/configu/config-history
Configu has a robust [logging](/integrations/store/configu/audit-logs) and versioning system.
Similar to how source controls like git work, every action is recorded, viewable and can be reverted if necessary.
The history log is available for three entities:
* Set - allows you to see the history of the entire Set with every change
* Config - allows you to see the history of a specific config (key & set)
* Version Tag - allows you to set a snapshot as a version and then jump between versions

### Revision Tags
Tags are a way to mark a specific snapshot of the organization's configs as a version.
Once a tag is created, you can compare it with the current state of your organization and revert to it.
**Tags can be created, viewed, and reverted only by the organization's admins.**
Tags can only be created and applied to the entire organization, not to a specific set or config.
#### Create a tag
In order to create a tag you'll first need to create a token with the `Admin` role.
See [Tokens](/integrations/store/configu/tokens#assign-roles-to-a-token) for more information about creating tokens and assigning them roles.
Once your token is ready, you can create a tag with the following request to our API:
```shell
curl --request POST \
--url https://api.configu.com/config/tag/revision \
--header 'Content-Type: application/json' \
--header 'Org: YOUR_ORG_ID' \
--header 'Token: YOUR_TOKEN' \
--data '{
"tag": "v1.0.0"
}'
```
Tag can be any alphanumeric string. optionally with the following characters: `. _ / -`Your organization ID can be found under [organization settings](/integrations/store/configu/settings)
Upon success (status 200), your tag will be ready for use.
You can now view it in the history log and revert to it if necessary by opening the action menu and clicking **Show diff**.



Only members with the `Admin` role have permission to access the `show diff` and `revert` actions.
#### Evaluating with a tag
You can use a tag to evaluate your configs with a specific snapshot of any existing tags to ensure your evaluations are deterministic. To do this, use `ConfiguConfigStore` with the `tag` parameter using any existing tag name.
Example usage with the [Node.js SDK](/interfaces/sdk/node/overview):
```js
import { ConfiguConfigStore, ConfigSet, ConfigSchema, EvalCommand, ExportCommand } from '@configu/node';
import schemaContents from './start.cfgu.json';
(async () => {
try {
const store = new ConfiguConfigStore({
credentials: {
org: process.env.CONFIGU_ORG,
token: process.env.CONFIGU_TOKEN,
},
tag: 'v1.0.0',
});
const set = new ConfigSet('test');
const schema = new ConfigSchema('start', schemaContents);
const data = await new EvalCommand({
store,
set,
schema,
}).run();
const configurationData = await new ExportCommand({
pipe: data,
}).run();
} catch (error) {
console.error(error);
}
})();
```
To evaluate using the CLI, make sure to set the `CONFIGU_TAG` environment variable to the tag name you wish to use or provide the `tag` parameter directly [via a `.configu` file](/interfaces/.configu).
* Attempting to evaluate a tag that does not exist will result in an error.
* Evaluating configs without having the `read` permission will return an empty value.
* Evaluations with a tag will be marked with the tag in the [audit log](/integrations/store/configu/audit-logs). -
Evaluations with a tag will trigger webhooks with the tag name in the payload as `tag`.
#### Exploring a tag
You can view the content of a tag by clicking `explore tag`.

This will take you to the explorer tab where you will see the snapshot of the the tag. You can utilize the existing features of the tab to explore the snapshot.

All navigation options are disabled during tag exploration.
All regular config action menu options besides `show value` are disabled during tag exploration.
You can view the value of the configs if you have the appropriate permission.
At any point you can exit the exploration mode by clicking `return to latest tag` in the banner at the top of the page.

### Rollbacks
For every history log entry, you will see a *Revert Changes* button inside the diff window.

# Integrations
Source: https://docs.configu.com/integrations/store/configu/integrations
Only the organization owner and admins can connect an integration to their own organization.
## GitHub
Configu lets you connect your GitHub repositories to your organization. Connecting your repositories enables the following features:
* Share access to ConfigSchema files directly from your repositories with your entire organization and streamline config management via the [Config Editor](/integrations/store/configu/config-editor).
* Validate your ConfigSchema when you open pull requests.
To connect your GitHub repositories:
1. Go to the **Apps** page under the **Integrations** tab
2. Click the **Authorize** button under the GitHub integration section and you will be navigated to GitHub to continue the process
3. Select where you want to install the [Configu GitHub App](https://github.com/apps/configu)
4. Select which repositories you want to connect
5. You will automatically be returned to the **Apps** page with the installation complete
Only the organization owner and admins can connect a GitHub App installation to their own organization.
* Only a single GitHub account or GitHub organization can be connected to a Configu organization. A GitHub account or GitHub organization cannot be connected to more than one organization at a time.
* GitHub App installations may be suspended at any time directly from GitHub. This disables all features within the Configu Cloud that depend on the installation.
* Uninstalling the GitHub app directly from GitHub will automatically disconnect the app from your organization.
## GitLab
Configu lets you connect your GitLab repositories to your organization. Connecting your repositories enables the following features:
* Share access to ConfigSchema files directly from your repositories with your entire organization and streamline config management via the [Config Editor](/integrations/store/configu/config-editor).
To connect your GitLab repositories:
1. Go to the **Apps** page under the **Integrations** tab
2. Click the **Authorize** button under the GitLab integration section and you will be navigated to GitLab to continue the process
3. Authorize the Configu GitLab App
4. You will automatically be returned to the **Apps** page with the installation complete
* **GitLab Account Restriction**: Only a single GitLab account can be connected to a Configu organization.
* **Automatic Integration Disconnection**: If the GitLab app is revoked directly from GitLab, the integration will automatically disconnect in Configu when you attempt to access integration features.
* **Access Scope**: Configu will have read-only access to all repositories your GitLab account is associated with, including private and group repositories, and will display them accordingly.
# Members
Source: https://docs.configu.com/integrations/store/configu/members
## Adding Users
Users can be added to Configu using the following methods:
* Send Invite
* SAML Single Sign-On
New members are assigned the [default role](/integrations/store/configu/authorization#default-role) from the organization settings.
## Send Invite
Users can be manually invited to join an organization from the member's page. The account must be able to receive mail.

## SAML Single Sign-On
Configu supports SAML Single Sign-On for managing organization access and authentication using your Single Sign-On provider.
For more information about SAML support please contact us at [info@configu.com](mailto:info@configu.com).
## Manage member permissions
### Assign roles to a Member
Organization members can be given roles that define what resources they can access. Read more about [role assignment](/integrations/store/configu/authorization#assign-roles) on the authorization page.


### Assign config access to a Member
A member's individual config permissions can be edited and deleted through the config access section. Read more about how to [assign config attributes](/integrations/store/configu/authorization#assign-config-attribute) on the authorization page.

## Removing a Member

# Configu Platform
Source: https://docs.configu.com/integrations/store/configu/overview
Integrates the Configu Orchestrator with [Configu platform](https://configu.com).
The Configu Platform is the most innovative store purpose-built for configurations. It is built based on the Configu configuration-as-code (CaC) approach and can model configurations and wrap them with unique layers, providing collaboration capabilities, visibility into configuration workflows, and security and compliance standardization.
Unlike legacy tools, which treat configurations as unstructured data or key-value pairs, Configu is leading the way with a Configuration-as-Code approach. By modeling configurations, they are treated as first-class citizens in the developers’ code. This makes our solution more robust and reliable and also enables Configu to provide more capabilities, such as visualization, a testing framework, and security abilities.
* Name: Configu
* Category: Configu
## Configuration
The Configu Orchestrator requires authorization to access your Configu organization. If you’re using the Configu CLI, simply run `configu login` to start an interactive login session. This will authenticate you with Configu ConfigStore and securely store your credentials for future use—no additional steps needed. Otherwise, you need to supply the following credentials:
* `credentials.org` - The organization identifier of the organization your want to use.
* `credentials.token` - [A token you generated via the Configu platform.](/integrations/store/configu/tokens)
You may optionally a tag to evaluate your configs with a [specific snapshot of any existing tags](/integrations/store/configu/config-history#evaluating-with-a-tag) to ensure your evaluations are deterministic via the `tag` parameter.
## Usage
### `.configu` store declaration
```yaml
stores:
my-store:
type: configu-platform
configuration:
credentials:
org: my-org
token: my-token
tag: v1.0.0
```
### CLI examples
#### Upsert command
```bash
configu upsert --store "my-store" --set "test" --schema "./start.cfgu.json" \
-c "GREETING=hello" \
-c "SUBJECT=configu"
```
#### Eval and export commands
```bash
configu eval --store "my-store" --set "test" --schema "./start.cfgu.json" \
| configu export
```
## Platform features
Configu Platform complements the [Configu OSS](https://github.com/configu/configu) management by providing:
* [A Single Source Of Truth](/integrations/store/configu/config-explorer) - with an easy way to explore and modify configurations
* **E2E Testing** - beyond the `Configu OSS` extensive test framework, `Configu Platform` adds a logic test layer that tests the big picture
* [History & Versioning](/integrations/store/configu/config-editor) - records configuration changes, making it easy to revert if needed
* [Activity Log](/integrations/store/configu/audit-logs) - record all actions that happen through Configu allowing for better collaboration
* [Webhooks](/integrations/store/configu/webhooks) - integrates with practically any 3rd-party tool or platform and enables push events
* [Integrations](/integrations/store/configu/integrations) - integrate with 3rd-party providers to enable features in the Configu Cloud
* [Permissions](/integrations/store/configu/members) - invite team members and control their permissions
* [Tokens](/integrations/store/configu/tokens) - enable other tools to integrate into Configu and manage configurations
* **Security** - increase your security and provide compliance standardization
* [Authorization](/integrations/store/configu/authorization) - control who can access what in the Configu Platform

# Settings
Source: https://docs.configu.com/integrations/store/configu/settings
You can manage your organization in your organization settings.
## Organization Information
Here you can find your organization information, including org and owner.

## Feature Settings
* **Domain Verification** - For increased security, we recommend that owners verify a domain via the Settings page so email accounts belonging to that domain can be added automatically to that organization.

## Protected Sets
For stricter access control, owners can define protected sets via the Settings page. Any mutation of protected sets within the organization will trigger change requests that are [queued for approval by an admin](/integrations/store/configu/approval-queue).

Config sets that do not yet exist can also be protected.
Mutations of protected sets create an `Upsert Config Request` [audit](/integrations/store/configu/audit-logs) entry.

## Danger Zone
The following will be visible only to the organization owner.

* **Transfer Ownership** - Gives another member the owner role which has permissions for all organization resources. The previous owner is assigned the [default role](/integrations/store/configu/authorization#default-role).
* **Delete this organization** - Permanently deletes the organization, its resources, and cancels any ongoing subscription.
The following will be visible to all other organization members.

* **Leave this organization** - Removes you from the organization. You can only rejoin if reinvited.
# Tokens
Source: https://docs.configu.com/integrations/store/configu/tokens
Provide restricted Configs access to an application.
A Configu Token is useful for:
* Authenticating the Configu CLI from a non-interactive system (e.g., CI/CD, Docker)
* Authenticating in real-time using one of our SDKs
## Creating a Token
To generate a token, head over to the Token page in the Settings tab.
New tokens are assigned [the reader role](/integrations/store/configu/authorization#predefined-roles).

A token can optionally be given an expiration date.


Safely store the token value. You won't be able to see it again!
## Assign roles to a Token
Organization tokens can be given roles that define what resources they can access. Read more about [role assignment](/integrations/store/configu/authorization#assign-roles) on the authorization page.


Tokens cannot be assigned the viewer role.
## Revoking a Token
In case a token is no longer necessary, you may prematurely revoke a token at any time.

# Webhooks
Source: https://docs.configu.com/integrations/store/configu/webhooks
Webhooks are user-defined HTTP callbacks. They are triggered by events in Configu and allow integration with different applications or third-party APIs. Webhooks in Configu are commonly used for sending messages or integrating with CI/CD platforms.
For example, a webhook can trigger a Github action flow when a Config is changed or notify about it in a Slack channel.
## Creating a Webhook
1. Go to the **Webhooks** page under the **Integrations** tab
2. Click the **Create Webhook** button and provide the webhook name and URL (both are mandatory fields)
3. After adding the webhook, you will see it listed in the Webhooks list

## Customizing Webhooks
### Customizing webhook events
The webhooks feature supports the ability to define which actions ("events") within the organization trigger the webhook invocation.
You may set the webhook to be triggered by all events or select individual events that are relevant to the use case of your webhook from the following list:
* `Upsert configs` - Upsert of config values to any and all sets.
* `Eval configs` - Evaluation or exports of config values from any and all sets.
### Customizing webhook payloads
You may use any of the predefined webhook payload properties within the header context by using [mustache templating](https://mustache.github.io/) as such:

List of generic properties:
* `orgId` - The unique identifier of your organization
* `message` - A simple string message that changes depending on the event that triggered the invocation
* `appUrl` - Link to the organization page within the Configu Cloud
* `assignee` - An object containing data regarding the entity that triggered the webhook
* `assignee.type` - The value can be `token` or `user` depending on the credentials used to trigger the webhook
* `assignee.name` - The name of the assignee which is either the token name or the user name
* `webhook` - An object containing the metadata of the webhook that was triggered
* `webhook.contentType` - The content type of the webhook
* `webhook.events` - An array that events that trigger the webhook
* `webhook.isActive` - Indicates if the webhook is enabled or disabled
* `webhook.name` - The display name of the webhook
* `webhook.orgId` - The organization identifier of the webhook-owning organization
* `webhook.createdAt` - A timestamp of the creation time of the webhook
* `webhook.updatedAt` -A timestamp of the last update time of the webhook
* `webhook.url` - The URL that receives an HTTP request when the webhook is invoked
* `event.type` - The type of the event from the list defined above
* `event.timestamp` - A timestamp of the time that the event was triggered
* `event.payload` - An object containing properties that change based on the event type
### Upsert configs event payload data
* `event.payload.upsertedConfigs` - An array containing all the configs that were upserted
* `event.payload.stagedSets` - An array containing all the unique sets that had at least one config that changed its value
* `event.payload.stagedConfigs` - An array containing all the configs that had their value changed as a result of the upsert
### Eval configs event payload data
* `event.payload.queries` - An array containing all the evaluation queries that were made to the Configu store.
### Customizing webhook headers
Webhook headers and payloads may be customized for specific use cases where you need to add properties to the webhook invocation.
By default, Configu sets the following headers:
* `content-type` - The value is defined by the content type you select when defining the webhook. The value cannot be changed by customizing the headers to ensure consistency.
* `user-agent` - Always set to `@configu/ua`. This value cannot be changed to ensure that you can consistently identify webhook invocations originating from Configu.
Popular examples of headers that you might want to customize:
* `authorization` - In cases where you need to authenticate the invocation you may set the authorization header to contain the required credentials.
### Additional notes
* When customizing both the webhook headers and payload, you may use any of the keywords mentioned above.
* Customizing the webhook payload overrides the default payload properties
* Using a keyword that is not defined within the context of the webhook will result in an empty value
* The value of the keyword is always stringified
* `event.payload` is an object, use [mustache templating](https://mustache.github.io/) syntax to extract your desired data.
for example: to print upserted configs use: `{{#event.payload.upsertedConfigs}}{{key}}{{value}}`
## Verify Webhook with test request
To verify that the webhook works, press on the **Test Webhook** button under the three dots menu.

## Disabling or Removing a Webhook
Enable or disable a webhook by clicking the Status button.
A webhook can be removed by clicking the Remove button under the dots menu.
## Integrations you might be interested in
* Communication
* [Discord](/guides/platform/discord-webhook)
* [Slack](/guides/platform/slack-webhook)
* Microsoft teams
* Telegram
* HubSpot
* Twilio
* Gmail
* CI/CD Trigger
* [Github Action](/guides/platform/github-actions-webhook)
* GitLab CI/CD
* Circle CI
* Others
* Zapier - allows integrations with hundreds of applications. See the full list on the [Zapier website](https://zapier.com/apps).
# CockroachDB
Source: https://docs.configu.com/integrations/store/db/cockroachdb
Integrates the Configu Orchestrator with [CockroachDB](https://www.cockroachlabs.com/).
* Name: CockroachDB
* Category: Database
## Configuration
Configu needs to be authorized to access your CockroachDB database. Configu utilizes [TypeORM](https://typeorm.io) under the hood to establish a connection with the database using [data source options](https://typeorm.io/data-source-options#postgres--cockroachdb-data-source-options) you need to supply.
## Usage
### `.configu` store declaration
To use the `CockroachDBConfigStore` with Configu, declare it in the `.configu` file as shown below:
```yaml
stores:
my-store:
type: cockroachdb
configuration:
host: localhost
username: test
password: test
database: test
```
### CLI Examples
#### Upsert command
```bash
configu upsert --store "my-store" --set "test" --schema "./start.cfgu.json" \
-c "GREETING=hello" \
-c "SUBJECT=configu"
```
#### Eval and export commands
```bash
configu eval --store "my-store" --set "test" --schema "./start.cfgu.json" \
| configu export
```
## Common Errors and Solutions
1. **Connection Timeout Troubleshooting**
* **Solution:** Increase the `connectTimeout` or `acquireTimeout` in the configuration options to handle long-running connection setups. Ensure the database is accessible.
2. **Authentication Failures**
* **Solution:** Verify the provided `username` and `password`, and confirm the user has access to the specified database. Use a CockroachDB client to check credentials.
3. **SSL Certificate Issues**
* **Solution:** Ensure the correct SSL certificate paths are provided if `ssl` is enabled. Verify that the certificates match the CockroachDB server configuration.
4. **Database Permissions Issues**
* **Solution:** Make sure the database user has `READ` and `WRITE` permissions for the specified table. Use the following SQL command to grant permissions:
```sql
GRANT ALL ON TABLE config_store TO ;
```
## References
* Integration documentation: [CockroachDB Documentation](https://www.cockroachlabs.com/docs/)
* TypeORM documentation: [https://typeorm.io](https://typeorm.io)
# MariaDB
Source: https://docs.configu.com/integrations/store/db/mariadb
Integrates the Configu Orchestrator with a [MariaDB database](https://mariadb.org/).
* Name: MariaDB
* Category: Database
## Configuration
Configu needs to be authorized to access your MariaDB database. Configu utilizes [TypeORM](https://typeorm.io) under the hood to establish a connection with the database using [data source options](https://typeorm.io/data-source-options#mysql--mariadb-data-source-options) you need to supply.
## Usage
### `.configu` store declaration
```yaml
stores:
my-store:
type: mariadb
configuration:
host: localhost
username: test
password: test
database: test
```
### CLI examples
#### Upsert command
```bash
configu upsert --store "my-store" --set "test" --schema "./start.cfgu.json" \
-c "GREETING=hey" \
-c "SUBJECT=configu"
```
#### Eval and export commands
```bash
configu eval --store "my-store" --set "test" --schema "./start.cfgu.json" \
| configu export
```
## Common errors and solutions
1. Connection timeout troubleshooting
* Solution: Increase the `connectTimeout` or `acquireTimeout` in the configuration options to handle long-running connection setups. Make sure the database is reachable from your application.
2. Authentication failures
* Solution: Verify that the provided `username` and `password` are correct, and that the user has the necessary permissions to access the specified database. Use a MariaDB client to manually confirm the credentials.
3. SSL Certificate issues
* Solution: Ensure the correct paths for SSL certificates are provided if `ssl` is enabled. Verify that the certificates match the MariaDB server's configuration.
4. Database permissions problems
* Solution: Ensure that the database user has the required `READ` and `WRITE` permissions for the `config_store` table. Use the following SQL command to grant permissions:
```sql
GRANT ALL PRIVILEGES ON config_store.* TO 'your_user'@'localhost';
FLUSH PRIVILEGES;
```
## References
* Integration documentation: [https://mariadb.org/documentation](https://mariadb.org/documentation)
* TypeORM documentation: [https://typeorm.io](https://typeorm.io)
# Microsoft SQL Server
Source: https://docs.configu.com/integrations/store/db/mssql
Integrates the Configu Orchestrator with [Microsoft SQL Server](https://learn.microsoft.com/en-us/sql/sql-server).
* Name: Microsoft SQL Server
* Category: Database
## Configuration
Configu needs to be authorized to access your Microsoft SQL Server database. Configu utilizes [TypeORM](https://typeorm.io) under the hood to establish a connection with the database using [data source options](https://typeorm.io/data-source-options#mssql-data-source-options) you need to supply.
### `.configu` Store Declaration
```yaml
stores:
my-store:
type: mssql
configuration:
host: localhost
username: test
password: test
database: test
```
### CLI Examples
### **CLI Examples**
#### **Upsert Command**
```bash
configu upsert --store "my-mssql-store" --set "test" --schema "./start.cfgu.json" \
-c "API_URL=https://example.com" \
-c "RETRY_LIMIT=5"
```
#### **Eval and Export Commands**
#### Upsert Command
```bash
configu upsert --store "my-store" --set "test" --schema "./start.cfgu.json" \
-c "GREETING=hey" \
-c "SUBJECT=configu"
```
#### Eval and Export Commands
```bash
configu eval --store "my-store" --set "test" --schema "./start.cfgu.json" \
| configu export
```
## Common Errors and Solutions
## **Common Errors and Solutions**
1. **Connection Timeout Issues**
* **Solution**: Verify that the host, port, and network configurations are correct. Increase `connectTimeout` in the configuration if needed.
2. **Authentication Failures**
* **Solution**: Ensure the provided `username` and `password` are correct, and the user has access to the specified database. Use a SQL client to verify credentials.
3. **Encryption Errors**
* **Solution**: If your SQL Server instance enforces encryption, ensure the `encrypt` option is set to `true`. If not, set it to `false`.
4. **Permission Issues**
* **Solution**: Verify that the user has `READ` and `WRITE` access to the required database. Use the following SQL command to grant permissions:
```sql
GRANT ALL PRIVILEGES ON DATABASE config_db TO [admin];
```
***
## **References**
* Integration documentation: [Microsoft SQL Server](https://learn.microsoft.com/en-us/sql/sql-server)
* TypeORM documentation: [MSSQL Data Source Options](https://typeorm.io/data-source-options#mssql-data-source-options)
***
1. Connection Issues
* Solution: Verify that the host, port, and encryption settings are correct. Make sure the database server is reachable from your application.
2. Authentication Failures
* Solution: Confirm the correctness of the provided `username` and `password`. Ensure the user has appropriate access to the specified database. You can verify credentials by logging in using an SQL client tool.
3. Encryption Configuration Problems
* Solution: Check if the `encrypt` option is set correctly for your database setup. If SQL Server requires encrypted connections, ensure that encryption is enabled in the configuration.
4. Database Permissions Issues
* Solution: Ensure the user has `READ` and `WRITE` access to the required table. Use the following SQL command to grant permissions:
```sql
GRANT ALL ON config_store TO [your_user];
```
## References
* Integration documentation: [https://learn.microsoft.com/en-us/sql/sql-server](https://learn.microsoft.com/en-us/sql/sql-server)
* TypeORM documentation: [https://typeorm.io](https://typeorm.io)
# MySQL
Source: https://docs.configu.com/integrations/store/db/mysql
Integrates the Configu MySQLConfigStore with [MySQL](https://www.mysql.com).
* Name: MySQL
* Category: Database
## Configuration
Configu needs to be authorized to access your MySQL database. Configu utilizes [TypeORM](https://typeorm.io) under the hood to establish a connection with the database using [data source options](https://typeorm.io/data-source-options#mysql--mariadb-data-source-options) you need to supply.
## Usage
### `.configu` store declaration
```yaml
stores:
my-store:
type: my-sql
configuration:
host: localhost
username: test
password: test
database: test
```
### CLI examples
#### Upsert command
```bash
configu upsert --store "my-store" --set "test" --schema "./start.cfgu.json" \
-c "GREETING=hey" \
-c "SUBJECT=configu"
```
#### Eval and export commands
```bash
configu eval --store "my-store" --set "test" --schema "./start.cfgu.json" \
| configu export
```
## Common Errors and Solutions
1. **Connection Timeout Troubleshooting**
* **Solution:** Increase the `connectTimeout` or `acquireTimeout` in the configuration options to handle long-running connection setups. Make sure the database is reachable from your application.
2. **Authentication Failures**
* **Solution:** Verify that the provided `username` and `password` are correct, and that the user has the necessary permissions to access the specified database. Use a MySQL client to manually confirm the credentials.
3. **SSL Certificate Issues**
* **Solution:** Ensure the correct paths for SSL certificates are provided if `ssl` is enabled. Verify that the certificates match the MySQL server's configuration.
4. **Database Permissions Problems**
* **Solution:** Ensure that the database user has the required `READ` and `WRITE` permissions for the `config_store` table. Use the following SQL command to grant permissions:
```sql
GRANT ALL PRIVILEGES ON config_store.* TO 'your_user'@'localhost';
FLUSH PRIVILEGES;
```
## References
* Integration documentation: [https://dev.mysql.com/doc](https://dev.mysql.com/doc)
* TypeORM documentation: [https://typeorm.io](https://typeorm.io)
# PostgreSQL
Source: https://docs.configu.com/integrations/store/db/postgresql
Integrates the Configu Orchestrator with [PostgreSQL](https://www.postgresql.org).
* Name: PostgreSQL
* Category: Database
## Configuration
Configu needs to be authorized to access your PostgreSQL database. Configu utilizes [TypeORM](https://typeorm.io) under the hood to establish a connection with the database using [data source options](https://typeorm.io/data-source-options#postgres--cockroachdb-data-source-options) you need to supply.
## Usage
### `.configu` store declaration
```yaml
stores:
my-store:
type: postgresql
configuration:
host: localhost
username: test
password: test
database: test
```
### CLI examples
#### Upsert command
```bash
configu upsert --store "my-store" --set "test" --schema "./start.cfgu.json" \
-c "GREETING=hey" \
-c "SUBJECT=configu node.js sdk"
```
#### Eval and export commands
```bash
configu eval --store "my-store" --set "test" --schema "./start.cfgu.json" \
| configu export
```
## References
* Integration documentation: [https://www.postgresql.org/docs/current/tutorial-start.html](https://www.postgresql.org/docs/current/tutorial-start.html)
* TypeORM documentation: [https://typeorm.io](https://typeorm.io)
# SQLite
Source: https://docs.configu.com/integrations/store/db/sqlite
Integrates the Configu Orchestrator with [SQLite](https://www.sqlite.org/docs.html).
* Name: SQLite
* Category: Database
## Configuration
Configu needs to be authorized to access your SQLite database. Configu utilizes [TypeORM](https://typeorm.io) under the hood to establish a connection with the database using [data source options](https://typeorm.io/data-source-options#better-sqlite3-data-source-options) you need to supply.
## Usage
### `.configu` store declaration
```yaml
stores:
my-store:
type: sqlite
configuration:
host: localhost
username: test
password: test
database: test
```
### CLI examples
#### Upsert command
```bash
configu upsert --store "my-store" --set "test" --schema "./start.cfgu.json" \
-c "GREETING=hey" \
-c "SUBJECT=configu"
```
#### Eval and export commands
```bash
configu eval --store "my-store" --set "test" --schema "./start.cfgu.json" \
| configu export
```
## Common errors and solutions
1. Database is locked
* Solution: Ensure that only one thread is writing to the database at a time. Use transactions to control access. Set the `PRAGMA busy_timeout` to make SQLite wait before throwing the error, e.g.
```sql
PRAGMA busy_timeout = 3000;
```
2. Disk I/O error
* Solution: Ensure the disk isn’t full. Make sure SQLite has permission to read and write to the database file. Verify that the path to the database file is correct.
3. Database disk image is malformed
* Solution: Create a backup of the corrupted database file. Use the SQLite `.dump` command to export and re-import data
```sql
sqlite3 corrupted.db ".dump" > backup.sql
sqlite3 new.db < backup.sql
```
4. No such table: table\_name
* Solution: Check if the table exists in the database by running `.tables` in the SQLite CLI. Verify the correct database file is being accessed. Ensure the SQL code or migrations to create the table have been executed before trying to access it.
## References
* Integration documentation: [https://www.sqlite.org/docs.html](https://www.sqlite.org/docs.html)
* TypeORM documentation: [https://typeorm.io](https://typeorm.io)
# CloudBees Feature Management
Source: https://docs.configu.com/integrations/store/ff/cloudbees-feature-management
Integrates the Configu Orchestrator with [CloudBees Feature Management](https://docs.cloudbees.com/docs/cloudbees-feature-management/latest).
* Name: CloudBees
* Category: Feature flag manager
## Configuration
Configu needs to be authorized to access your CloudBees app. You must specify an `appKey` that corresponds to an an environment of some CloudBees environment and an optional context that has a `targetingKey` that identifies the subject (end-user, or client service) of a flag evaluation. You may also configure [`providerOptions`](https://github.com/DefinitelyTyped/DefinitelyTyped/blob/dc3f51b89bf7741b8d327311321ab6db041aa88d/types/rox-node/index.d.ts#L35C35-L35C35) to customize the CloudBees client.
## Limitations
* Only supports the eval and export commands.
## Usage
### `.configu` store declaration
```yaml
stores:
my-store:
type: cloud-bees
configuration:
appKey: example-appKey
```
### CLI Examples
#### Upsert command
Not supported
#### Eval and export commands
```bash
configu eval --store "my-store" --set "test" --schema "./start.cfgu.json" \
| configu export
```
## Common errors and solutions
1. Invalid API token
* Solution: Verify that the provided `apiToken` is valid and has access to the necessary resources. Regenerate the token if needed via the CloudBees dashboard.
2. Connection timeout
* Solution: Check the `url` and ensure the CloudBees instance is accessible. Make sure there are no firewall or network restrictions blocking access.
3. Unauthorized access
* Solution: Ensure that the API token or credentials have the necessary permissions for the specified project and environment. Update the permissions via the CloudBees admin console.
4. Configuration not found
* Solution: Verify that the correct `project` and `environment` names are provided in the store configuration. Check if the configuration exists in the CloudBees instance.
## References
* Integration Documentation: [https://docs.cloudbees.com/docs/cloudbees-platform/latest/feature-management](https://docs.cloudbees.com/docs/cloudbees-platform/latest/feature-management)
# LaunchDarkly
Source: https://docs.configu.com/integrations/store/ff/launchdarkly
Integrates the Configu Orchestrator with [LaunchDarkly](https://launchdarkly.com/).
* Name: LaunchDarkly
* Category: Feature flag manager
## Configuration
Configu needs to be authorized to access your LaunchDarkly project. You must specify an `sdkKey` that corresponds to an SDK key of an environment of some LaunchDarkly project and a context that has a `key` or a `targetingKey` that identifies the subject (end-user, or client service) of a flag evaluation. You may also configure [`ldOptions`](https://launchdarkly.github.io/node-server-sdk/interfaces/_launchdarkly_node_server_sdk_.LDOptions.html) to customize the LaunchDarkly client.
## Usage
### `.configu` store declaration
```yaml
stores:
my-store:
type: launch-darkly
configuration:
sdkKey: example-sdkKey
context:
targetingKey: default
```
### CLI examples
#### Upsert command
```bash
configu upsert --store "my-store" --set "test" --schema "./start.cfgu.json" \
-c "GREETING=hey" \
-c "SUBJECT=configu"
```
#### Eval and export commands
```bash
configu eval --store "my-store" --set "test" --schema "./start.cfgu.json" \
| configu export
```
## References
* Integration documentation: [https://docs.launchdarkly.com](https://docs.launchdarkly.com)
# Split
Source: https://docs.configu.com/integrations/store/ff/split
Integrates the Configu Orchestrator with [Split](https://help.split.io/hc/en-us).
* Name: Split
* Category: Feature flag manager
## Configuration
Configu needs to be authorized to access your Split project. You must specify an `authKey` that corresponds to an SDK key of an environment of some Split project, a context that has a `targetingKey` that identifies the subject (end-user or client service) of a flag evaluation, and optionally a `key` that represents a customer identifier, [more details can be found in the Split SDK initialization documentation](https://help.split.io/hc/en-us/articles/360020564931-Node-js-SDK#initialization).
## Usage
### `.configu` store declaration
```yaml
stores:
my-store:
type: split
configuration:
authKey:
context:
targetingKey:
```
### CLI examples
#### Upsert command
```bash
configu upsert --store "my-store" --set "test" --schema "./start.cfgu.json" \
-c "GREETING=hey" \
-c "SUBJECT=configu"
```
#### Eval and export commands
```bash
configu eval --store "my-store" --set "test" --schema "./start.cfgu.json" \
| configu export
```
## Common errors and solutions
1. Invalid API key
* Solution: Verify that the provided `apiKey` is correct and active. You can regenerate it in the Split dashboard if needed.
2. Environment or workspace not found
* Solution: Ensure that the specified `workspace` and `environment` exist in your Split account. Use the Split dashboard to confirm their names.
3. Permission issues
* Solution: Verify that the API key has the necessary permissions to read, write, and modify feature flags in the target environment.
4. Rate limit exceeded
* Solution: If the API rate limit is exceeded, consider optimizing the frequency of API requests. Monitor Split’s rate limit policies in the [API documentation](https://docs.split.io/reference/rate-limiting).
## References
* Integration documentation: [https://help.split.io/hc/en-us](https://help.split.io/hc/en-us)
# CSV File
Source: https://docs.configu.com/integrations/store/file/csv-file
Integrates the Configu Orchestrator with [CSV files](https://en.wikipedia.org/wiki/Comma-separated_values).
* Name: CSV File
* Category: File
## Configuration
Configu needs to be directed to your desired file by providing a file path via the `path` parameter.
## Usage
### `.configu` store declaration
```yaml
stores:
my-store:
type: csv-file
configuration:
path: path/to/file.csv
```
### CLI examples
#### Upsert command
```bash
configu upsert --store "my-store" --set "test" --schema "./start.cfgu.json" \
-c "GREETING=hello" \
-c "SUBJECT=configu"
```
#### Eval and export commands
```bash
configu eval --store "my-store" --set "test" --schema "./start.cfgu.json" \
| configu export
```
## References
* Integration documentation: [https://en.wikipedia.org/wiki/Comma-separated\_values](https://en.wikipedia.org/wiki/Comma-separated_values)
# INI File
Source: https://docs.configu.com/integrations/store/file/ini-file
Integrates the Configu Orchestrator with [INI files](https://en.wikipedia.org/wiki/INI_file).
* Name: INI File
* Category: File
## Configuration
Configu needs to be directed to your desired file by providing a file path via the `path` parameter.
## Usage
### `.configu` store declaration
```yaml
stores:
my-store:
type: ini-file
configuration:
path: path/to/file.ini
```
### CLI examples
#### Upsert command
```bash
configu upsert --store "my-store" --set "test" --schema "./start.cfgu.json" \
-c "GREETING=hello" \
-c "SUBJECT=configu"
```
#### Eval and export commands
```bash
configu eval --store "my-store" --set "test" --schema "./start.cfgu.json" \
| configu export
```
## References
* Integration documentation: [https://en.wikipedia.org/wiki/INI\_file](https://en.wikipedia.org/wiki/INI_file)
# JSON File
Source: https://docs.configu.com/integrations/store/file/json-file
Integrates the Configu Orchestrator with [JSON files](https://www.json.org/json-en.html).
* Name: JSON File
* Category: File
## Configuration
Configu needs to be directed to your desired file by providing a file path via the `path` parameter.
## Usage
### `.configu` store declaration
```yaml
stores:
my-store:
type: json-file
configuration:
path: path/to/file.json
```
### CLI examples
#### Upsert command
```bash
configu upsert --store "my-store" --set "test" --schema "./start.cfgu.json" \
-c "GREETING=hello" \
-c "SUBJECT=configu"
```
#### Eval and export commands
```bash
configu eval --store "my-store" --set "test" --schema "./start.cfgu.json" \
| configu export
```
## Common errors and solutions
1. File permission issues
* Solution: Ensure that the application has read and write permissions for the specified JSON file path. Check the file system permissions and adjust them if necessary.
2. Invalid JSON format
* Solution: Verify that the JSON file follows the correct syntax. Use a JSON validator or parser to check for errors if you manually edit the file.
3. File path not found
* Solution: Make sure the specified path exists and is accessible. Create any necessary parent directories before attempting to read or write the JSON file.
4. Encoding issues
* Solution: Ensure the JSON file is saved with UTF-8 encoding to support all characters properly. If you encounter encoding problems, check the file's encoding and convert it if necessary.
## References
* Integration documentation: [https://www.json.org/json-en.html](https://www.json.org/json-en.html)
# TOML File
Source: https://docs.configu.com/integrations/store/file/toml-file
Integrates the Configu Orchestrator with [TOML files](https://toml.io/en/).
* Name: Toml File
* Category: File
## Configuration
Configu needs to be directed to your desired file by providing a file path via the `path` parameter.
## Usage
### `.configu` store declaration
```yaml
stores:
my-store:
type: toml-file
configuration:
path: path/to/file.toml
```
### CLI examples
#### Upsert command
```bash
configu upsert --store "my-store" --set "test" --schema "./start.cfgu.json" \
-c "GREETING=hey" \
-c "SUBJECT=configu"
```
#### Eval and export commands
```bash
configu eval --store "my-store" --set "test" --schema "./start.cfgu.json" \
| configu export
```
## References
* Integration documentation: [https://toml.io/en/v1.0.0](https://toml.io/en/v1.0.0)
# XML File
Source: https://docs.configu.com/integrations/store/file/xml-file
Integrates the Configu Orchestrator with [XML files](https://www.w3.org/XML/).
* Name: XML File
* Category: File
## Configuration
Configu needs to be directed to your desired file by providing a file path via the `path` parameter.
## Usage
### `.configu` store declaration
```yaml
stores:
my-store:
type: xml-file
configuration:
path: path/to/file.xml
```
### CLI Examples
#### Upsert command
```bash
configu upsert --store "my-store" --set "test" --schema "./start.cfgu.json" \
-c "GREETING=hello" \
-c "SUBJECT=configu"
```
#### Eval and export commands
```bash
configu eval --store "my-store" --set "test" --schema "./start.cfgu.json" \
| configu export
```
## Common errors and solutions
1. File permission issues
* Solution: Ensure that the application has read and write permissions for the specified XML file path. Check the file system permissions and adjust them if necessary.
2. Invalid XML format
* Solution: Verify that the XML file follows the correct structure. Use an XML validator to check for syntax errors if you manually edit the file.
3. File path not found
* Solution: Make sure the specified path exists and is accessible. Create any necessary parent directories before initializing the store.
4. Encoding issues
* Solution: Ensure the XML file is saved with UTF-8 encoding to support all characters properly. If you encounter encoding problems, check the file's encoding and convert it if necessary.
## References
* Integration documentation: [https://www.w3.org/XML](https://www.w3.org/XML)
# AWS Systems Manager Parameter Store
Source: https://docs.configu.com/integrations/store/other/aws-parameter-store
Integrates the Configu Orchestrator with [AWS Parameter Store](https://docs.aws.amazon.com/systems-manager/latest/userguide/systems-manager-parameter-store.html).
* Name: AWS Parameter Store
* Category: Key-value store
## Configuration
Configu needs to be authorized to access your AWS Secrets Manager account. By default, Configu uses the standard authentication methods that the AWS SDKs use, if you have the right IAM access credentials, there's no special action to take. Otherwise, you need to supply [SSMClientConfig](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/Package/-aws-sdk-client-ssm/Interface/SSMClientConfig/).
## Usage
### `.configu` store declaration
```yaml
stores:
my-store:
type: aws-parameter-store
configuration:
credentials:
accessKeyId:
secretAccessKey:
region: us-east-1
```
### CLI examples
#### Upsert command
```bash
configu upsert --store "my-store" --set "test" --schema "./start.cfgu.json" \
-c "GREETING=hello" \
-c "SUBJECT=configu"
```
#### Eval and export commands
```bash
configu eval --store "my-store" --set "test" --schema "./start.cfgu.json" \
| configu export
```
## References
* Integration documentation: [https://docs.aws.amazon.com/systems-manager/latest/userguide/systems-manager-parameter-store.html](https://docs.aws.amazon.com/systems-manager/latest/userguide/systems-manager-parameter-store.html)
* SSM Client documentation: [https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/client/ssm](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/client/ssm)
# etcd
Source: https://docs.configu.com/integrations/store/other/etcd
Integrates the Configu Orchestrator with [etcd](https://etcd.io/).
* Name: etcd
* Category: Key-value store
## Configuration
Configu needs to be authorized to access your etcd store. You may pass [options into the etcd client constructor](https://microsoft.github.io/etcd3/interfaces/ioptions.html) to configure how the client connects to etcd.
## Usage
### `.configu` store declaration
```yaml
stores:
my-store:
type: etcd
configuration:
hosts:
- http://localhost:2379
- http://localhost:2380
username: # Optional
password: # Optional
```
### CLI examples
#### Upsert command
```bash
configu upsert --store "my-store" --set "test" --schema "./start.cfgu.json" \
-c "APP_MODE=production" \
-c "RETRY_COUNT=5"
```
#### Eval and export commands
```bash
configu eval --store "my-store" --set "test" --schema "./start.cfgu.json" \
| configu export
```
## Common errors and solutions
1. Connection timeout
* Solution: Ensure the `hosts` URLs are reachable from your application. Increase the `timeout` value if the network latency is high.
2. Authentication failure
* Solution: If authentication is enabled, verify the provided `username` and `password`. Test with:
```bash
etcdctl --user : endpoint status
```
3. Cluster unavailability
* Solution: Ensure that all nodes in the etcd cluster are healthy. Use the following command to check cluster health:
```bash
etcdctl endpoint health
```
4. Key collision issues
* Solution: Use unique keys or prefixes for different configuration sets to avoid conflicts.
## References
* Integration documentation: [https://etcd.io/docs](https://etcd.io/docs)
* Integration SDK documentation: [https://microsoft.github.io/etcd3/classes/etcd3.html](https://microsoft.github.io/etcd3/classes/etcd3.html)
# LocalForage
Source: https://docs.configu.com/integrations/store/other/localforage
Integrates the Configu Orchestrator with [LocalForage](https://localforage.github.io/localForage/), a fast and simple storage library for offline data, offering a unified API for IndexedDB, WebSQL, and localStorage.
* Name: LocalForage
* Category: Browser Key-Value store
## Configuration
The localForage store needs to be initialized with the [localForage configuration options](https://localforage.github.io/localForage/#settings-api-config).
## Usage
localForage only integrates with the browser hence it cannot be used with either `@configu/cli` or `@configu/proxy` and can only be used directly.
### Example SDK usage
```js
import { ConfigSet, ConfigSchema, UpsertCommand, EvalCommand, ExportCommand } from '@configu/sdk';
import { LocalForageConfigStore } from '@configu-integrations/localforage';
(async () => {
try {
const store = new LocalForageConfigStore({ name: 'example-db-name' });
const set = new ConfigSet('test');
const schema = new ConfigSchema(schemaContents);
await new UpsertCommand({
store,
set,
schema,
configs: {
GREETING: 'hey',
SUBJECT: 'configu',
},
}).run();
const { result: data } = await new EvalCommand({
store,
set,
schema,
}).run();
const configurationData = await new ExportCommand({ pipe: data }).run();
console.log(configurationData);
} catch (error) {
console.error(error);
}
})();
```
## Common errors and solutions
1. Driver unsupported error
* Solution: Verify that the selected driver (e.g., IndexedDB) is supported by the browser. If not, fallback to `localStorage` or `WebSQL`:
```yaml
driver: LOCALSTORAGE
```
2. Storage quota exceeded
* Solution: Reduce the amount of data stored, or prompt the user to free up space. IndexedDB generally provides more storage space than localStorage.
3. Version conflict
* Solution: Ensure the `version` specified in the configuration matches the current database version. If changing schema, increment the version number.
4. Data persistence issues
* Solution: Verify that the store name and driver configuration are correct. Use the browser's DevTools to inspect the storage.
## References
* Integration documentation: [https://localforage.github.io/localForage/](https://localforage.github.io/localForage/)
# AWS Secrets Manager
Source: https://docs.configu.com/integrations/store/secret/aws-secrets-manager
Integrates the Configu Orchestrator with [AWS Secrets Manager](https://docs.aws.amazon.com/secretsmanager).
* Name: AWS Secrets Manager
* Category: Secret manager
## Configuration
Configu needs to be authorized to access your AWS Secrets Manager account. By default, Configu uses the standard authentication methods that the AWS SDKs use, if you have the right IAM access credentials, there's no special action to take. Otherwise, you need to supply [SecretsManagerClient Configuration](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/client/secrets-manager/).
## Limitations
* A secret scheduled for deletion cannot be changed by the Configu Orchestrator. You will need to manually cancel the secret deletion.
## Usage
### `.configu` store declaration
```yaml
stores:
my-store:
type: aws-secrets-manager
configuration:
credentials:
accessKeyId:
secretAccessKey:
region: us-east-1
```
### CLI examples
#### Upsert command
```bash
configu upsert --store "my-store" --set "test" --schema "./start.cfgu.json" \
-c "GREETING=hey" \
-c "SUBJECT=configu node.js sdk"
```
#### Eval and export commands
```bash
configu eval --store "my-store" --set "test" --schema "./start.cfgu.json" \
| configu export
```
## Examples
Secrets list after upsert:

Values upserted to the `test` config set:

## References
* Integration documentation: [https://docs.aws.amazon.com/secretsmanager](https://docs.aws.amazon.com/secretsmanager)
# Azure Key Vault
Source: https://docs.configu.com/integrations/store/secret/azure-key-vault
Integrates the Configu Orchestrator with [Azure Key Vault](https://learn.microsoft.com/en-us/azure/key-vault/).
* Name: Azure Key Vault
* Category: Secret manager
## Configuration
Configu needs to be authorized to access Azure Key Vault. Configu uses the [default azure credentials](https://www.npmjs.com/package/@azure/identity#defaultazurecredential) which by default will read account information specified via [environment variables](https://www.npmjs.com/package/@azure/identity#environment-variables) and use it to authenticate. The `vaultUrl` parameter must always be provided.
The examples below will use the following environment variables for authentication: `AZURE_CLIENT_ID`, `AZURE_CLIENT_SECRET`, `AZURE_TENANT_ID` in conjunction with the required `vaultUrl` parameter.
## Limitations
* Deleted configs do not immediately remove secrets [due to soft deletion](https://learn.microsoft.com/en-us/azure/key-vault/general/soft-delete-overview). Attempting to upsert to a deleted secret that is not purged will throw an error.
## Usage
### `.configu` store declaration
```yaml
stores:
my-store:
type: azure-key-vault
configuration:
credential: {}
vaultUrl: https://my-vault.vault.azure.net/
```
### CLI Examples
#### Upsert Command
```bash
configu upsert --store "my-store" --set "test" --schema "./start.cfgu.json" \
-c "GREETING=hey" \
-c "SUBJECT=configu"
```
#### Eval and export commands
```bash
configu eval --store "my-store" --set "test" --schema "./start.cfgu.json" \
| configu export
```
## Common errors and solutions
1. Authentication failure
* Solution: Ensure the correct `clientId`, `clientSecret`, and `tenantId` are provided. Verify the service principal's permissions in the Azure portal.
2. Vault not found
* Solution: Ensure the `vaultUrl` is correct and the key vault exists in your Azure subscription. Verify with:
```bash
az keyvault show --name my-vault
```
3. Access denied
* Solution: Make sure the service principal has the necessary access policy to manage secrets. Use the following command to grant permissions:
```bash
az keyvault set-policy --name my-vault --spn --secret-permissions get list set delete
```
4. Network connectivity issues
* Solution: Verify that your network allows access to the vault endpoint. Test the connectivity with:
```bash
curl -I https://my-vault.vault.azure.net/
```
## References
* Integration documentation: [https://docs.aws.amazon.com/secretsmanager](https://docs.aws.amazon.com/secretsmanager)
* Azure Identity SDK: [https://learn.microsoft.com/en-us/azure/active-directory/develop/reference-v2-libraries](https://learn.microsoft.com/en-us/azure/active-directory/develop/reference-v2-libraries)
# GCP Secret Manager
Source: https://docs.configu.com/integrations/store/secret/gcp-secret-manager
Integrates the Configu Orchestrator with [Google Cloud Secret Manager](https://cloud.google.com/secret-manager).
* Name: GCP Secret Manager
* Category: Secret manager
## Configuration
Configu needs to be authorized to access your GCP Secret manager account. By default, Configu uses the [standard authentication methods](https://cloud.google.com/docs/authentication/application-default-credentials) that the GCP SDKs use, if you have the right IAM access credentials, you only need to provide the `projectId` parameter.
## Usage
### `.configu` store declaration
```yaml
stores:
my-store:
type: gcp-secret-manager
configuration:
projectId: my-gcp-project
keyFile: path/to/service-account.json
```
### CLI examples
#### Upsert command
```bash
configu upsert --store "my-store" --set "test" --schema "./config.cfgu.json" \
-c "GREETING=hey" \
-c "SUBJECT=configu"
```
#### Eval and export commands
```bash
configu eval --store "my-store" --set "test" --schema "./config.cfgu.json" \
| configu export
```
## Common errors and solutions
1. Authentication error
* Solution: Ensure the `credentials` file points to a valid service account JSON key, or verify that your environment is authenticated with GCP using:
```bash
gcloud auth application-default login
```
2. Insufficient permissions
* Solution: Grant the necessary permissions to the service account by assigning the `Secret Manager Admin` role:
```bash
gcloud projects add-iam-policy-binding my-gcp-project \
--member="serviceAccount:my-service-account@my-gcp-project.iam.gserviceaccount.com" \
--role="roles/secretmanager.admin"
```
3. Secret not found
* Solution: Ensure the secret exists in the GCP Secret Manager and that the correct `projectId` is provided in the configuration.
4. Quota limit exceeded
* Solution: Check your GCP quotas and upgrade if necessary. Manage the number of secrets to stay within allowed limits.
## References
* Integration Documentation: [https://cloud.google.com/secret-manager/docs](https://cloud.google.com/secret-manager/docs)
# HashiCorp Vault
Source: https://docs.configu.com/integrations/store/secret/hashicorp-vault
Integrates the Configu Orchestrator with [HashiCorp Vault](https://www.vaultproject.io/).
* Name: HashiCorp Vault
* Category: Secret manager
## Configuration
Configu needs to be authorized to access your HashiCorp vault account. For this, you need to provide the following parameters: `address`, `engine`, `token`. By default, Configu attempts to use the following environment variables for the vault address and token: `VAULT_ADDR`, `VAULT_TOKEN`. The `engine` parameter must always be provided.
## Limitations
* Only supports the K/V2 engine.
* Does not support root set (E.g. `configu upsert --set "/"`).
## Usage
### `.configu` store declaration
```yaml
stores:
my-store:
type: hashicorp-vault
configuration:
address: https://vault.example.com
token: example-token
engine: example-engine
```
### CLI examples
#### Upsert command
```bash
configu upsert --store "my-store" --set "test" --schema "./start.cfgu.json" \
-c "GREETING=hey" \
-c "SUBJECT=configu"
```
#### Eval and export commands
```bash
configu eval --store "my-store" --set "test" --schema "./start.cfgu.json" \
| configu export
```
## Common errors and solutions
1. Authentication failure
* Solution: Ensure the provided `token` is valid and has sufficient permissions. Verify the token with:
```bash
vault token lookup
```
2. Timeout issues
* Solution: Increase the `timeout` value in the configuration if the Vault server takes longer to respond.
3. Path not Found
* Solution: Ensure the provided `path` exists and the token has access to it. Use:
```bash
vault list secret/
```
4. Certificate errors in HTTPS connections
* Solution: If using HTTPS, ensure that the correct CA certificates are configured. Use the `VAULT_CACERT` environment variable to specify the certificate path:
```bash
export VAULT_CACERT=/path/to/ca.pem
```
## References
* Integration documentation: [https://www.vaultproject.io/docs](https://www.vaultproject.io/docs)
# Kubernetes Secret
Source: https://docs.configu.com/integrations/store/secret/kubernetes-secret
Integrates the Configu Orchestrator with [Kubernetes Secrets](https://kubernetes.io/docs/concepts/configuration/secret/).
* Name: Kubernetes Secrets
* Category: Secret manager
## Configuration
Configu needs to be authorized to access your Kubernetes Secret instance. By default, Configu attempts to [load the default kubeconfig credentials](https://kubernetes.io/docs/concepts/configuration/organize-cluster-access-kubeconfig/#the-kubeconfig-environment-variable) via the `KUBECONFIG` environment variable. You can manually provide credentials via a kubeconfig file via the `kubeconfig` parameter. The `namespace` parameter must always be provided.
## Usage
### `.configu` store declaration
```yaml
stores:
my-store:
type: kubernetes-secret
configuration:
namespace: default
kubeconfig: ~/.kube/config
```
### CLI examples
#### Upsert command
```bash
configu upsert --store "my-store" --set "test" --schema "./start.cfgu.json" \
-c "GREETING=hey" \
-c "SUBJECT=configu"
```
#### Eval and export commands
```bash
configu eval --store "my-k8s-secret-store" --set "test" --schema "./start.cfgu.json" \
| configu export
```
## Common errors and solutions
1. Cluster Access Issues
* Solution: Ensure that the kubeconfig path is correct and that your user or service account has access to the cluster. Test connectivity with:
```bash
kubectl get nodes
```
2. Insufficient Permissions
* Solution: Make sure your account has `GET`, `CREATE`, and `UPDATE` permissions for secrets. Use the following command to grant access:
```bash
kubectl create rolebinding configu-access --clusterrole=admin --serviceaccount=default:default
```
3. Namespace Not Found
* Solution: Verify that the specified namespace exists by listing all available namespaces:
```bash
kubectl get namespaces
```
4. Secret Access Errors
* Solution: Check that the target secret exists and the user has proper access permissions. Use:
```bash
kubectl get secrets -n
```
## References
* Integration documentation: [https://kubernetes.io/docs/concepts/configuration/secret](https://kubernetes.io/docs/concepts/configuration/secret)
* Kubernetes authentication: [https://kubernetes.io/docs/concepts/configuration/organize-cluster-access-kubeconfig](https://kubernetes.io/docs/concepts/configuration/organize-cluster-access-kubeconfig)
# Configu Configuration-as-Code Format
Source: https://docs.configu.com/interfaces/.cfgu
The `Cfgu` format defines the characteristics of a software configuration in Configu, providing metadata and constraints for `ConfigValues`. When attached to a `ConfigKey` in a `ConfigSchema`, it enables validation of `ConfigValues`, facilitating their implementation in the code.
export const CfguExt = () => .cfgu.yaml|yml|json;
## Location
`.cfgu` files essentially set the boundaries of different domains in the code relative to the configuration they use. Developers are free to organize and structure their `.cfgu` files in a way that makes sense for their specific needs and workflow. There is no limit on the number of `.cfgu` files that can be created, and they can be spread across different codebases, subfolders in the same project, and different repositories.
## Format
The `.cfgu` file can be written in one of the following formats: `YAML` or `JSON`. The name suffix of this file should be according to the format used.
## \$schema
Include the `$schema` property at the beginning of the file to specify the `Cfgu` version to communicate to other readers and tooling which specification version is intended.
Also, most modern editors will use this property to provide IntelliSense and validation for the `Cfgu` file.
```yaml example.cfgu.yaml
$schema: https://files.configu.com/schema/.cfgu.json
```
```json example.cfgu.json
{
"$schema": "https://files.configu.com/schema/.cfgu.json"
}
```
```yaml vscode-yaml
# yaml-language-server: $schema=https://files.configu.com/schema/.cfgu.json
```
## Properties
Describe a `ConfigKey`'s purpose within the application.
Use this property to validate a `ConfigValue`. This property receives a string or an array of strings representing an
expression that evaluates to a boolean. If an array is provided, all expressions must evaluate to `true` for the value
to be considered valid.
{' '}
The `ConfigValue` to be validated.
The `ConfigValue` to be validated as a raw string as it is stored in the `ConfigStore`.
The `Cfgu` of the evaluated config.
The `ConfigKey` of the evaluated config.
The origin of the `ConfigValue`. One of `empty`, `default`, `store`, `override`, or `const`.
An array containing all of the labels of the config. If the config has no labels, then the array will be empty. Acts
as syntax sugar for `$.cfgu.label` for expression consistency.
The `ConfigStore` provided as input to the command.
The `ConfigSet` provided as input to the command.
The `ConfigSchema` provided as input to the command.
Use this to access the `Cfgu` properties of another ConfigKey.
Use this to access the `value` of another ConfigKey.
Use this to access the `storedValue` of another ConfigKey.
```yaml example.cfgu.yaml
$schema: https://files.configu.com/schema/.cfgu.json
keys:
NODE_ENV:
description: Defines the environment in which the application runs
test: expect($.value).to.be.a('string')
enum:
- development
- production
- test
default: production
ENABLE_FEATURE:
description: Enables a feature flag. Needs be enabled in production
test:
- validator.isBoolean($.storedValue)
- '$.configs.NODE_ENV.value === "production" ? expect($.value).to.be.true : true'
default: false
ENABLE_DEBUG_MODE:
description: Enables a debug mode. Must not be enabled in production
test:
- validator.isBoolean($.storedValue)
- '$.configs.NODE_ENV.value === "production" ? expect($.value).to.be.false : true'
default: false
```
```json example.cfgu.json
{
"$schema": "https://files.configu.com/schema/.cfgu.json",
"keys": {
"NODE_ENV": {
"description": "Defines the environment in which the application runs",
"test": "expect($.value).to.be.a('string')",
"enum": ["development", "production", "test"],
"default": "production"
},
"ENABLE_FEATURE": {
"description": "Enables a feature flag. Needs to be enabled in production",
"test": [
"validator.isBoolean($.storedValue)",
"$.configs.NODE_ENV.value === \"production\" ? expect($.value).to.be.true : true"
],
"default": false
},
"ENABLE_DEBUG_MODE": {
"description": "Enables a debug mode. Must not be enabled in production",
"test": [
"validator.isBoolean($.storedValue)",
"$.configs.NODE_ENV.value === \"production\" ? expect($.value).to.be.false : true"
],
"default": false
}
}
}
```
Define a constant value for a `ConfigKey` through a `ConfigExpression`, these `ConfigKeys` are never queried through a
`ConfigStore`. This property cannot be set together with `lazy`, `default`, or `required`.
The `Cfgu` of the evaluated
config.
The `ConfigKey` of the evaluated config.
An array containing all of the labels of the config. If the config has no labels, then the array will be empty. Acts as syntax sugar for `$.cfgu.label` for expression consistency.
The `ConfigStore` provided as input to the
command.
The `ConfigSet` provided as input to the command.
The `ConfigSchema`
provided as input to the command.
Use this to access the `Cfgu` properties of another ConfigKey.
Use this to access the `value` of another ConfigKey.
Use this to access the `storedValue` of another ConfigKey.
Define a regular expression a `ConfigValue` must match. This property must be provided if the `type` is `RegEx`.
Specify a JSON schema a `ConfigValue` must conform to. This property must be provided if the `type` is `JSONSchema`.
Specify a list of allowable `ConfigValues` for a `ConfigKey`. This property cannot be an empty array or contain empty
strings. Each option must be unique.
Set a default `ConfigValue` for a `ConfigKey` if not explicitly provided.
This property cannot be set together with `required`, `const` or `lazy` properties.
If `enum` is set, the default value must be one of the options.
Indicate whether a `ConfigKey` is essential for the application's functionality. When set to `true`, a `ConfigValue`
must be found on `EvalCommand`. This property cannot be set together with `default` or `const`.
Indicate that a `ConfigValue` is set only during `EvalCommand` execution, excluding it from `UpsertCommand`
assignments. This property cannot be set together with `const` or `default`.
Indicate that this `ConfigKey` will be omitted from `ExportCommand` results.
List labels to categorize `ConfigKeys` for easier filtering on `ExportCommand`.
## Example
```yaml example.cfgu.yaml
$schema: https://files.configu.com/schema/.cfgu.json
keys:
NODE_ENV:
description: Defines the environment in which the application runs
test: validator.isString($.value)
enum:
- development
- production
- test
default: development
LOG_LEVEL:
description: Defines the level of logs to be recorded
test: validator.isString($.value)
enum:
- error
- warn
- info
- verbose
- debug
- silly
default: info
SERVICE_ENDPOINT:
description: Defines the endpoint for the service
test: validator.isURL($.value)
required: true
AWS_REGION:
description: Defines the AWS region for the service
enum:
- af-south-1
- ap-east-1
- ap-northeast-1
- ap-northeast-2
- ap-northeast-3
- ap-south-1
- ap-southeast-1
- ap-southeast-2
- ca-central-1
- cn-north-1
- cn-northwest-1
- eu-central-1
- eu-north-1
- eu-south-1
- eu-west-1
- eu-west-2
- eu-west-3
- me-south-1
- sa-east-1
- us-east-1
- us-east-2
- us-gov-east-1
- us-gov-west-1
- us-west-1
- us-west-2
default: us-east-1
```
```json example.cfgu.json
{
"$schema": "https://files.configu.com/schema/.cfgu.json",
"keys": {
"NODE_ENV": {
"description": "Defines the environment in which the application runs",
"test": "validator.isString($.value)",
"enum": ["development", "production", "test"],
"default": "development"
},
"LOG_LEVEL": {
"description": "Defines the level of logs to be recorded",
"test": "validator.isString($.value)",
"enum": ["error", "warn", "info", "verbose", "debug", "silly"],
"default": "info"
},
"SERVICE_ENDPOINT": {
"description": "Defines the endpoint for the service",
"test": "validator.isURL($.value)",
"required": true
},
"AWS_REGION": {
"description": "Defines the AWS region for the service",
"enum": [
"af-south-1",
"ap-east-1",
"ap-northeast-1",
"ap-northeast-2",
"ap-northeast-3",
"ap-south-1",
"ap-southeast-1",
"ap-southeast-2",
"ca-central-1",
"cn-north-1",
"cn-northwest-1",
"eu-central-1",
"eu-north-1",
"eu-south-1",
"eu-west-1",
"eu-west-2",
"eu-west-3",
"me-south-1",
"sa-east-1",
"us-east-1",
"us-east-2",
"us-gov-east-1",
"us-gov-west-1",
"us-west-1",
"us-west-2"
],
"default": "us-east-1"
}
}
}
```
# Configu Interface Configuration File
Source: https://docs.configu.com/interfaces/.configu
The `.configu` file is an optional configuration file used by the various Configu interfaces to customize its behavior. The file should be named `.configu` regardless of the format used: JSON or YAML.
## Location
Configu interfaces recursively search for the `.configu` file starting from the current working directory and continuing up to the user's home directory. Once it finds a `.configu` file, it uses it in conjunction with the locally stored `.configu` file in the user's home directory (`$HOME/.configu/.configu`) and stops searching.
Alternatively, you may provide an explicit `.configu` file by passing a path as an environment variable via `CONFIGU_CONFIG` or `CONFIGU_CONFIGURATION`.
## Format
The `.configu` file can be written in one of the following formats: `YAML` or `JSON`. The file should be named `.configu` regardless of the format used.
## \$schema
include the `$schema` property at the beginning of the file to specify the `Cfgu` version to communicate to other readers and tooling which specification version is intended.
Also, most modern editors will use this property to provide IntelliSense and validation for the `Cfgu` file.
```yaml YAML
$schema: https://files.configu.com/schema/.configu.json
```
```json JSON
{
"$schema": "https://files.configu.com/schema/.configu.json"
}
```
```yaml vscode-yaml
# yaml-language-server: $schema=https://files.configu.com/schema/.configu.json
```
## Properties
### stores
The `.configu` file allows you to save `ConfigStore` configurations as friendly names, which can be later used as values for the `--store` flag in all the commands.
To define a `ConfigStore`, add a new key-value pair to the `stores` section of the `.configu` file, where the key represents the friendly name, and the value is an object with the `type` and `configuration` properties. The `type` property represents the store type, and the `configuration` property contains the specific configuration options for the store.
You can activate backup for a specific store by adding the `backup` property to the store configuration object and set it to `true`.
If you want to mark a `ConfigStore` as your default store whenever you choose to omit a `ConfigStore` as an input when performing actions with Configu's high-level interfaces, add the `default` property to a store configuration object and set it to `true`. If your `.configu` file only has a single store, it is automatically behaves as your default store.
For detailed information about the available store options, please refer to the relevant store on the [integrations section](/integrations/overview#configstore).
### backup
The `.configu` file allows you to define the backup file path for the Configu CLI. The backup is used to store the results of the `configu eval` command to provide failsafe and faster access to the results.
To define the backup configuration, add a new key-value pair to the `.configu` file, where the key is `backup`, and the value is path to the backup file.
By default, the backup file is stored in the os cache directory as follows:
* macOS: `~/Library/Caches/configu/config.sqlite`
* Unix: `~/.cache/configu/config.sqlite`
* Windows: `%LOCALAPPDATA%\configu\config.sqlite`
### schemas
The `.configu` file allows you to save `ConfigSchema` paths as friendly names, which can be later used as values for the `--schema` flag in all the commands.
To define a custom script, add a new key-value pair to the `schemas` section of the `.configu` file, where the key represents the friendly name, and the value is the schema absolute or relative path.
### scripts
The `.configu` file allows you to save `Configu CLI` snippets as friendly names, which can be later used as values for the `--script` flag in the `configu run --script