Elentra Deployment
Elentra Deployment Tool v2.0.0
Last updated
Elentra Deployment Tool v2.0.0
Last updated
As of Elentra ME 1.19, the recommended deployment strategy for deploying Elentra to servers is to use a PHP-based deployment tool called Deployer. The Elentra Deployment Tool v2.0.0 recipe is based off of Deployer v6.8.0, which comes pre-installed with the Elentra Developer Docker environment and can easily be installed on host workstations or CI/CD servers.
To obtain the standard Elentra Deployment Tool template, you can either:
If your local elentra-developer
Docker environment is up to date, then the template already exists on your computer in the ~/Documents/elentra-developers/resources/templates/deployer/v6
directory. If you're not up to date, simply pull down the latest commits from the master
branch.
Alternatively, you can always download the latest from our elentra-developer GitHub repository.
The following describes the default available deployment variables.
For more documentation related to host configuration options, please see the Deployer Hosts documentation, which is quite extensive.
This section illustrates a single server that has multiple Apache virtual hosts defined, which are used for both staging and production.
This section illustrates a single staging server and multiple separate production server hosts.
Tip: When deploying to multiple production servers, you should use the -p
or --parallel
flag to deploy to multiple servers at the same time: dep deploy production -p
Deployer also supports host ranges (e.g., elentra[01:05].med.university.edu
).
Deployer deployment commands are typically executed from within your Elentra Developer Docker Environment within the /var/www/vhosts/uni-elentra-1x-me/deployment
directory, but can also be executed by your CI/CD server to automate the deployment process.
Variable
Description
application
Application Name (e.g.,uni-elentra-1x-me
)
packagist_token
Institutional Packagist.com Composer token
repository
Branded Edition Elentra ME Git repository location
branch
The default deployment branch (e.g., master
) within your Branded Edition Elentra ME Git repository. This value is always overridden by the host configuration section (if present), so it not overly important.
repository_ejs
Branded Edition Elentra JS 2.x Git repository location.
branch_ejs
The default deployment branch (e.g., master
) within your Branded Edition Elentra JS Git repository. This value is always overridden by the host configuration section (if present), so it not overly important.
enable_branded_api
If you have a Branded Edition Elentra API with your implementation of Elentra then please set this to true
. Default value is false
.
allow_anonymous_stats
It is not recommended to change this value. Default value is false
.
build_directory
Local build directory where repositories are stored before deployment. Default value is /tmp
.
clear_paths
Array of files or directories removed from host(s) after deployment. Default value is www-root/setup
.
default_stage
Default stage to be deployed with dep deploy. Default value is staging
.
enable_restart_supervisor
Restart supervisord during the deployment process. Requires appropriate permissions. Default value is true
.
exclude_paths
Exclude any files or directories in Elentra's .deployignore from deployment upload. Default value is true
.
git_tty
Allocate tty for git clone. Default value is false
.
keep_releases
Number of previous deployments to keep on the server. Default value is 10
.
Deployer
Notes
dep deploy staging
dep deploy production
Add -p
flag to speed up multi-server deployments.
Add -v|vv|vvv
flag to increase the verbosity of messages.
dep rollback staging
dep ssh hostname
Connect via SSH to the specified host.