Docker Compose Environment Variables¶
Zammad’s Docker Compose supports several environment variables that are not
set by default. The best way to provide these is within the file .env
.
In case our default docker-compose.yml
is not good enough, please use
docker-compose.override.yml
to provide own changes.
Note
Unless stated otherwise, below environment variables count for the whole Zammad stack and not single containers. Below grouping is to help you find them better, but do not reflect their container.
Docker Compose¶
Variable |
Default Value |
Description |
Additional Info |
---|---|---|---|
RESTART |
|
By default containers will be restarted in case they stopped for whatever reason. |
|
VERSION |
This variables contains the version tag. Example: |
We update this string from time to time, Docker Hub may contain more current tags to the moment you’re pulling. |
Zammad¶
Variable |
Default Value |
Description |
Additional Info |
---|---|---|---|
AUTOWIZARD_JSON |
|
This variable allows you to provide initial configuration data for your instance. Autowizard JSON is out of scope of this documentation, however this example file should help. |
Tip This variable is specific to the |
ZAMMAD_WEB_CONCURRENCY |
|
Allows spawning |
Tip This variable is specific to the |
ZAMMAD_SESSION_JOBS
_CONCURRENT
|
|
Allows spawning |
Tip This variable is specific to the |
ZAMMAD_PROCESS_SCHEDULED
_JOBS_WORKERS
|
|
Allows spawning |
Tip This variable is specific to the |
ZAMMAD_PROCESS_DELAYED
_JOBS_WORKERS
|
|
Allows spawning |
Tip This variable is specific to the |
RAILS_TRUSTED_PROXIES |
|
By default Zammad trusts localhost proxies only. |
Tip This variable is specific to the Danger ⚠ Only change this option if you know what you’re doing! ⚠ |
Elasticsearch¶
Variable |
Default Value |
Description |
Additional Info |
---|---|---|---|
ELASTICSEARCH_ENABLED |
|
Setting this variable to false will allow you to run your Zammad without Elasticsearch. Please note that we strongly advise against doing so. |
Tip This variable is specific to the |
ELASTICSEARCH_HOST |
|
Provide a host name or address to your external Elasticsearch cluster. |
Tip This variable is specific to the |
ELASTICSEARCH_PORT |
|
Provide a different port for Elasticsearch if needed. |
Tip This variable is specific to the |
ELASTICSEARCH_SCHEMA |
|
By default Elasticsearch is reachable via HTTP. |
Tip This variable is specific to the |
ELASTICSEARCH_NAMESPACE |
|
With this name space all Zammad related indexes will be created. Change this if you’re using external clusters. |
Tip This variable is specific to the |
ELASTICSEARCH_REINDEX |
|
By default the docker-compose will always re-index upon a restart. On big installations this may be troublesome. |
Warning Disabling this setting requires you to re-index your search index manually whenever that’s needed by upgrading to a new Zammad version! Tip This variable is specific to the |
ELASTICSEARCH_SSL_VERIFY |
|
Allows you to let the compose scripts ignore self signed SSL certificates for your Elasticsearch installation if needed. |
Tip This variable is specific to the |
Memcached¶
Variable |
Default Value |
Description |
Additional Info |
---|---|---|---|
MEMCACHE_SERVERS |
|
Provide your own Memcached instance if you already have one existing. |
Warning Was |
Redis¶
Variable |
Default Value |
Description |
Additional Info |
---|---|---|---|
REDIS_URL |
|
Provide your own Redis instance if you already have one. |
Warning This method currently does not allow authentication. |
NGINX¶
Variable |
Default Value |
Description |
Additional Info |
---|---|---|---|
NGINX_PORT |
|
The port Nginx will listen on. |
Tip This variable is specific to the |
NGINX_SERVER_NAME |
|
By default the Nginx container of Zammad will respond to all request. You can provide your IP / FQDN if you want to. |
Tip This variable is specific to the |
NGINX_SERVER_SCHEME |
|
If the Nginx container for Zammad is not the upstream server (aka you’re using another proxy in front of nginx) |
Tip This variable is specific to the |
ZAMMAD_RAILSSERVER_HOST |
|
Host name of the rails server container. |
|
ZAMMAD_RAILSSERVER_PORT |
|
Port of Zammads rails server. |
Please also note Configuration via Environment Variables in this regard. |
ZAMMAD_WEBSOCKET_HOST |
|
Host name of Zammads websocket server. |
Tip This variable is specific to the |
ZAMMAD_WEBSOCKET_PORT |
|
Port of Zammads websocket server. |
Please also note Configuration via Environment Variables in this regard. |
Tip
😖 Can’t login because of CSRF token errors?
This usually affects systems with more than one proxy server only. For this to function you may have to tell your web server directly which connection type was used.
Warning
Do not use below options if you’re unsure, they may technically be a security issue!
The following options expect HTTPs connections which should be your goal.
Within your virtual host configuration, locate both directives
proxy_set_header X-Forwarded-Proto
and replace $scheme
by
https
.
Within your virtual host configuration just above the first
ProxyPass
directive insert:
RequestHeader set X_FORWARDED_PROTO 'https'
RequestHeader set X-Forwarded-Ssl on
PostgreSQL¶
Variable |
Default Value |
Description |
Additional Info |
---|---|---|---|
POSTGRESQL_HOST |
|
Host name of your PostgreSQL server. Use your own if you already have one. |
|
POSTGRESQL_PORT |
|
Adjust the Port of your PostgreSQL server. |
|
POSTGRESQL_USER |
|
The database user for Zammad. |
|
POSTGRESQL_PASS |
|
The password of Zammads database user. |
|
POSTGRESQL_DB |
|
Zammads database to use. |
|
POSTGRESQL_OPTIONS |
|
Additional postgresql params to be appended to the database URI. |
|
POSTGRESQL_DB_CREATE |
|
By default we will create the required database. |
Note On own database servers this setting might be troublesome. Tip This variable is specific to the |