# Environment Variables (CybusMQ)

Configure CybusMQ to match your deployment requirements using environment variables.

{% hint style="info" %}
CybusMQ uses the original VerneMQ variable names.
{% endhint %}

{% hint style="warning" %}

### Prefer Helm Values Over Environment Variables in Kubernetes Deployments

For Kubernetes deployments, configuration is primarily done through Helm chart values. Environment variables should only be used if there is no corresponding Helm value.
{% endhint %}

The following environment variables are available for simple configurations. If you need further options, you must provide your own configuration file in which you can use all VerneMQ configuration options.

## Environment Variables

| Environment Variable                               | Description                                                            |
| -------------------------------------------------- | ---------------------------------------------------------------------- |
| `DOCKER_VERNEMQ_ALLOW_REGISTER_DURING_NETSPLIT`    | Allows clients to connect even if the cluster is incomplete.           |
| `DOCKER_VERNEMQ_ALLOW_PUBLISH_DURING_NETSPLIT`     | Allows clients to publish even if the cluster is incomplete.           |
| `DOCKER_VERNEMQ_ALLOW_SUBSCRIBE_DURING_NETSPLIT`   | Allows clients to subscribe even if the cluster is incomplete.         |
| `DOCKER_VERNEMQ_ALLOW_UNSUBSCRIBE_DURING_NETSPLIT` | Allows clients to unsubscribe even if the cluster is incomplete.       |
| `MAX_OFFLINE_MESSAGES`                             | Maximum number of messages stored while a client is offline.           |
| `MAX_ONLINE_MESSAGES`                              | Maximum number of messages stored while a client is online.            |
| `PERSISTENT_CLIENT_EXPIRATION`                     | Defines how long persistent sessions are kept without client activity. |
| `DOCKER_VERNEMQ_LOG__CONSOLE__LEVEL`               | Configures the console log level.                                      |


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.cybus.io/broker/cybusmq/environment-variables.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
