Configuration File
Last updated
Was this helpful?
Last updated
Was this helpful?
The configuration file is created when you start the project cma.js
, it's a tool that allows you to be in control of important parts of the project without headaches.
Magento configuration is located in magento
field and contains the following fields:
first_name
- Admin first name
last_name
- Admin last name
email
- Admin email
user
- Admin user name
password
Admin password
adminuri
- Admin panel URL
mode
- Magento mode (description and list of available modes is located )
edition
- Magento edition. Allowed values: community
, enterprise
.
In the configuration
field we can configure PHP, Composer and Docker services.
PHP configuration is located in the php
field and contains the following fields:
env
- Environment variables for container object.
Nginx configuration is located in the nginx
field and contains the following fields:
image
- Container image string. For Nginx default version is nginx:1.18.0
.
MariaDB configuration is located in the mariadb
field and contains the following fields:
image
- Container image. string.
useOptimizerSwitch
- MariaDB specific setting. string or boolean.
By default set to true for MariaDB 10.4 and newer version.
During template file compilation true will be transformed to the following configuration:
SearchEngine configuration is located in the searchengine
field and allows you to select elasticsearch and opensearch as options.
For Magento 2.4.7 and older CMA by default will select elasticsearch for searchengine
configuration.
From Magento 2.4.8 and newer CMA by default will select opensearch for searchengine
configuration.
ElasticSearch configuration is located in the elasticsearch
field and contains the following fields:
image
- Container image string.
env
- Environment variables for container object.
ElasticSearch configuration is located in the opensearch
field and contains the following fields:
image
- Container image string.
env
- Environment variables for container object.
Redis configuration is located in the redis
field and contains the following fields:
image
- Container image string. For Redis default version is 6.0.10-alpine
Composer configuration is located in the composer
field and contains the following fields:
version
- Composer version string.
plugins
- Map of Composer global plugins with a configuration that will be added to project image.
plugins[name].options
- a string
with additional options for composer global require <name> <options>
command.
Varnish configuration is located in the varnish
field and contains the following fields:
enabled
- A boolean option to manually enable or disable Varnish in the setup. (Default: false
)
image
- Varnish image string.
healthCheck
- A boolean option to manually enable or disable Varnish HealthCheck in the setup. (Default: false
)
SSL Terminator is an Nginx instance, its configuration is located in sslTerminator
field and contains the following fields:
image
- Container image string.
Available only on Linux. WSL/MacOS are not supported.
NewRelic is a monitoring service for applications and uses the following configurations fileds:
enabled
- Boolean indicating if NewRelic is used in the application or not. Default is false
.
licenseKey
- License key string. Located in API Keys section on NewRelic.
The host configuration is a string located in host
field and by default, it is set to localhost
.
You can put your own host domain that will be set to nginx config as server_name
and set Magento secure and unsecure base_url values.
storeDomains
allows to set different domains for Magento stores.
Use store code
as key
and domain as a value
.
SSL configuration is located in the ssl
field and contains the following values:
enabled
- Enables or disables SSL in the application. boolean (false
by default)
external_provider
- Allows to use external SSL provider in the application. boolean (false
by default)
ssl_certificate
- SSL certificate file location string. You can put there your SSL certificate file location relative to the project root folder or use absolute value.
ssl_certificate_key
- SSL certificate key file location string. You can put there your SSL certificate file location relatively to the project root folder or use absolute value.
Prefix configuration is a boolean located in the prefix
field and by default, it is set to true
.
baseImage
- PHP image without XDebug installed. You can select an image from the .
debugImage
- PHP image with XDebug installed. You can select an image from the .
configTemplate
- php.ini
template file location. With this option, you can define your own php.ini
file that will be used by PHP. (Original php.template.ini
file can be found )
debugTemplate
- xdebug.ini
template file location. With this option you can tweak the XDebug configuration used in together with debugImage
. (Original php-debug.template.ini
file can be found )
fpmConfigTemplate
- php-fpm.conf
template file location. With this option you can tweak the PHP-FPM configuration used by PHP-FPM. (Original php-fpm.template.conf
file can be found )
extensions
- Map of extensions that will be used for the project. By default, it contains the following extensions that are required by Magento. You can add an extension that will be required by some Composer package, CMA will automatically install it with the correct version.
Learn more about installing extensions in our guide on !
configTemplate
- Nginx template file location string. With this option, you can define your own nginx.conf file that will be used by Nginx. (Original nginx.template.conf
file can be found )
Nginx image is pulled from .
Can be set to any valid configuration from .
MariaDB image is pulled from .
ElasticSearch image is pulled from .
Magento 2.2.10 - 2.3.4 are using our that works on amd64 and arm64 architectures.
OpenSearch image is pulled from .
Redis image is pulled from .
plugins[name].enabled
- a boolean
which determines if the plugin should be enabled. For example, if you are using an older Magento version with Composer 1 plugin is enabled by default to speed-up installation and you can disable it!
configTemplate
- varnish.vcl
template file location. With this option, you can define your own varnish.vcl
file that will be used by Varnish. (Original varnish.template.vcl
file can be found )
Varnish image is pulled from .
configTemplate
- SSL Terminator template file location string. With this option, you can define your own ssl-terminator.template.conf
- File that will be copied inside the $CMA_CACHE/ssl-terminator/conf.d/
folder which is mounted in Nginx container to /etc/nginx/conf.d/
folder. string (Original ssl-terminator.template.conf
file can be found )
Nginx image is pulled from .
Learn about adding NewRelic to your application .
Learn about adding a localhost domain to your application .
Learn about configuring Multi-Store domains in your application .
Learn about enabling SSL in your application .
But what prefixes are used for?
Prefix is a unique identifier that will be appended to docker container and volume names to prevent possible interference between folders with similar names. (Interference between folders look like )
Setting prefix
to false
is generally not recommended but might be necessary for legacy projects.