Skip to main content

All DX configuration variables

This document includes all of the variables you can configure the Moderne agent to run with. Your configuration will only use some of these.

Maven repository access variables

Variables:

Variable NameRequiredDefaultDescription
MODERNE_DX_MAVEN_{index}_URLtrueThe URL of your Maven repository.
MODERNE_DX_MAVEN_{index}_LOCALREPOSITORYtrue~/.moderne-mavenThe path on disk where LST artifacts and Maven index files will be downloaded to. This is on the disk where the agent is being run and not on the Maven instance.

LST artifacts are deleted from this location after they are transmitted to Moderne. Index files will remain behind to be used to detect diffs in the artifacts.

If multiple Maven repositories are configured on the agent, they must have different MODERNE_DX_MAVEN_{index}_LOCALREPOSITORY configured.
MODERNE_DX_MAVEN_{index}_ASTSOURCEfalsetrueSpecifies whether or not this repository should be searched for LST artifacts. (Note: LSTs used to be called ASTs).
MODERNE_DX_MAVEN_{index}_USERNAMEfalsenullThe username used to resolve artifacts.
MODERNE_DX_MAVEN_{index}_PASSWORDfalsenullThe password used to resolve artifacts.
MODERNE_DX_MAVEN_{index}_RELEASESfalsetrueSpecifies whether or not this repository should be searched for releases.
MODERNE_DX_MAVEN_{index}_SNAPSHOTSfalsetrueSpecifies whether or not this repository should be searched for snapshots.
MODERNE_DX_MAVEN_{index}_RECIPESOURCEfalsetrueSpecifies whether or not this repository should be searched for recipe jars.
MODERNE_DX_MAVEN_{index}_SKIPSSLfalsefalseWhether or not to skip SSL/TLS verification for calls from the agent to this Maven repository. This must be set to true if you use a self-signed SSL/TLS certificate.
MODERNE_DX_MAVEN_{index}_SKIPVALIDATECONNECTIVITYfalsefalseBy default, on DX startup, we validate that it can connect to the configured resource, and fail to start up the DX if we cannot. Set this to true to skip this validation.

Example:

docker run \
# ... Existing variables
-e MODERNE_DX_MAVEN_0_URL=https://myartifactory.example.com/artifactory/libs-releases-local \
-e MODERNE_DX_MAVEN_0_LOCALREPOSITORY=~/.moderne-maven \
-e MODERNE_DX_MAVEN_0_USERNAME=admin \
-e MODERNE_DX_MAVEN_0_PASSWORD=password \
# ... Additional variables

Artifactory LST variables

Variables:

Variable NameRequiredDefaultDescription
MODERNE_DX_STORAGE_ENABLEDtruefalseEnables persistent storage for the LST index.
MODERNE_DX_STORAGE_PATHtrue<dx configuration directory>/storageThe path of the LST index directory on the container or local disk. (<dx configuration directory>refers to the location where all configuration for DX lives, including the recipe catalog, tokens, etc. It's not configurable.
MODERNE_DX_ARTIFACTORY_{index}_URLtrueThe URL of your Artifactory instance.
MODERNE_DX_ARTIFACTORY_{index}_USERNAMEtrueThe username used to connect to your Artifactory instance. This user must have permission to run AQL queries.
MODERNE_DX_ARTIFACTORY_{index}_PASSWORDtrueThe password used to connect to your Artifactory instance.
MODERNE_DX_ARTIFACTORY_{index}_ASTQUERYFILTERS_{index}trueThe AQL query fragment used to select LST artifacts to send to Moderne. If multiple are specified, they are combined together with an AND.
MODERNE_DX_ARTIFACTORY_{index}_SKIPSSLfalsefalseSpecifies whether or not to skip SSL verification for HTTP connections from the service to this Artifactory instance. This must be set to true if you use a self-signed SSL/TLS certificate.
MODERNE_DX_ARTIFACTORY_{index}_SKIPVALIDATECONNECTIVITYfalsefalseBy default, on DX startup, we validate that it can connect to the configured resource, and fail to start up the DX if we cannot. Set this to_ true _to skip this validation.
MODERNE_DX_ARTIFACTSYNC_SINCEfalseSpecifies how long in the past to sync your artifacts. Defaults to syncing all time. It is recommended to set a start date of the sync or it will try to search your entire artifactory.

Example:

docker run \
# ... Existing variables
-e MODERNE_DX_STORAGE_ENABLED=true \
-e MODERNE_DX_STORAGE_PATH=/some/storage/path \
-e MODERNE_DX_ARTIFACTORY_0_URL=https://myartifactory.example.com/artifactory/ \
-e MODERNE_DX_ARTIFACTORY_0_USERNAME=admin \
-e MODERNE_DX_ARTIFACTORY_0_PASSWORD=password \
-e MODERNE_DX_ARTIFACTORY_0_ASTQUERYFILTERS_0='"name":{"$match":"*-ast.jar"}' \
-e MODERNE_DX_ARTIFACTORY_0_ASTQUERYFILTERS_1='"repo":{"$eq":"example-maven"}' \
-e MODERNE_DX_ARTIFACTSYNC_SINCE=2024-01-01T00:00:00Z
# ... Additional variables

Artifactory recipe variables

Variables:

Variable NameRequiredDefaultDescription
MODERNE_DX_MAVEN_{index}_URLtrueThe URL of your Maven repository inside of Artifactory.
MODERNE_DX_MAVEN_{index}_ASTSOURCEtruetrueSpecifies whether or not this repository should be searched for LST artifacts. Defaults to true – but you should set this to false (Note: LSTs used to be called ASTs).
MODERNE_DX_MAVEN_{index}_LOCALREPOSITORYtrue~/.moderne-mavenThe path on disk where Maven index files will be downloaded to. This is on the disk where the service is being run and not in Artifactory.

If multiple Maven repositories are configured on the agent, they must have different MODERNE_DX_MAVEN_{index}_LOCALREPOSITORY configured.
MODERNE_DX_MAVEN_{index}_USERNAMEfalsenullThe username used to resolve artifacts.
MODERNE_DX_MAVEN_{index}_PASSWORDfalsenullThe password used to resolve artifacts.
MODERNE_DX_MAVEN_{index}_RELEASESfalsetrueSpecifies whether or not this repository should be searched for releases.
MODERNE_DX_MAVEN_{index}_SNAPSHOTSfalsetrueSpecifies whether or not this repository should be searched for snapshots.
MODERNE_DX_MAVEN_{index}_RECIPESOURCEfalsetrueSpecifies whether or not this repository should be searched for recipe jars.
MODERNE_DX_MAVEN_{index}_SKIPSSLfalsefalseWhether or not to skip SSL/TLS verification for calls from the agent to this Maven repository. This must be set to true if you use a self-signed SSL/TLS certificate.
MODERNE_DX_MAVEN_{index}_SKIPVALIDATECONNECTIVITYfalsefalseBy default, on DX startup, we validate that it can connect to the configured resource, and fail to start up the DX if we cannot. Set this to true to skip this validation.

Example:

docker run \
# ... Existing variables
-e MODERNE_DX_MAVEN_0_URL=https://myartifactory.example.com/artifactory/libs-releases-local \
-e MODERNE_DX_MAVEN_0_ASTSOURCE=false \
-e MODERNE_DX_MAVEN_0_LOCALREPOSITORY=~/.moderne-maven \
-e MODERNE_DX_MAVEN_0_USERNAME=admin \
-e MODERNE_DX_MAVEN_0_PASSWORD=password \
# ... Additional variables

On-prem SCM variables

Variables:

Variable NameRequiredDefaultDescription
MODERNE_DX_SCM_{index}_BASEURLtrueThe primary URL of your SCM server. This URL will be used as the origin.
MODERNE_DX_SCM_{index}_TYPEtrueSpecifies the type of the SCM server (case insensitive). Choose between: GitHub, GitLab, Bitbucket, BitbucketCloud, AzureDevOps.
MODERNE_DX_SCM_{index}_ALTERNATEURLS_{alternate_url_index}trueOne or more alternate URLs (each with a different {alternate_url_index}) which point to the same server. Use this to specify all the protocol and port combinations that can be used to reach the same server.

Example:

docker run \
# ... Existing variables
-e MODERNE_DX_SCM_0_BASEURL=https://bitbucket.example.com/stash \
-e MODERNE_DX_SCM_0_TYPE=Bitbucket \
-e MODERNE_DX_SCM_0_ALTERNATEURLS_0=ssh://bitbucket.example.com:7999 \
-e MODERNE_DX_SCM_0_ALTERNATEURLS_1=http://bitbucket.example.com:8080/stash \
# ... Additional variables

Organizations service variables

Variables:

Variable NameRequiredDefaultDescription
MODERNE_DX_ORGANIZATION_URLtrueThe URL of your GraphQL service that provides organization information. Cannot be combined with MODERNE_DX_ORGANIZATION_REPOSCSV.
MODERNE_DX_ORGANIZATION_REPOSCSVtrueThe path of your repos.csv file that provides organization information. Cannot be combined with MODERNE_DX_ORGANIZATION_URL.
MODERNE_DX_ORGANIZATION_DEFAULTCOMMITOPTIONSfalseThe commit options used if not specified by the organization service.
MODERNE_DX_ORGANIZATION_UPDATE_INTERVAL_SECONDSfalse600Specifies how often to request your organization information. Only used when combined with MODERNE_DX_ORGANIZATION_URL.
MODERNE_DX_ORGANIZATION_SKIPSSLfalsefalseSpecifies whether or not to skip SSL validation for HTTP connections to this Organization service instance. Only used when combined with MODERNE_DX_ORGANIZATION_URL. This must be set to true if you use a self-signed SSL/TLS certificate.

Example:

docker run \
# ... Existing variables
-e MODERNE_DX_ORGANIZATION_URL=http://localhost:8091 \
-e MODERNE_DX_ORGANIZATION_UPDATE_INTERVAL_SECONDS=600 \
-e MODERNE_DX_ORGANIZATION_DEFAULTCOMMITOPTIONS=Direct,Branch,Fork,PullRequest,ForkAndPullRequest \
# ... Additional variables

Strict recipe sources variables

Variables:

Variable NameRequiredDefaultDescription
MODERNE_DX_RECIPE_USEONLYCONFIGUREDtrueOnly use the recipe sources configured in the service.
MODERNE_DX_RECIPE_POMCACHE_TYPEfalseUsed to specify what type of cache the POM should use. Acceptable values: IN_MEMORY or REDIS.
MODERNE_DX_RECIPE_POMCACHE_ENTRYTTLMINUTESfalseHow long entries should live in the POM cache.
MODERNE_DX_RECIPE_POMCACHE_REDIS_HOSTtrue (If the POM cache type is set to REDIS)The URL of the Redis instance.
MODERNE_DX_RECIPE_POMCACHE_REDIS_PORTtrue (If the POM cache type is set to REDIS)The port number of the Redis instance.
MODERNE_DX_RECIPE_POMCACHE_REDIS_USERNAMEfalseThe username needed to authenticate to the Redis instance.
MODERNE_DX_RECIPE_POMCACHE_REDIS_PASSWORDfalseThe password needed to authenticate with the Redis instance.
MODERNE_DX_RECIPE_POMCACHE_REDIS_SSLfalsefalseIf set to true, then SSL will be enabled for the connection to the Redis instance.
MODERNE_DX_RECIPE_POMCACHE_REDIS_DATABASEfalseThe Redis DB index.

Example:

docker run \
# ... Existing variables
-e MODERNE_DX_RECIPE_USEONLYCONFIGURED=true \
# ... Additional variables