docs/recipe/typo3.md
require 'recipe/typo3.php';
Deployer is a free and open source deployment tool written in PHP. It helps you to deploy your TYPO3 application to a server. It is very easy to use and has a lot of features.
Three main features of Deployer are:
Additionally, Deployer has a lot of other features, like:
You can read more about Deployer in Getting Started.
The deploy task of TYPO3 consists of:
The typo3 recipe is based on the common recipe.
TYPO3 Deployer Recipe
Usage Examples:
Deploy to production (using Git as source): vendor/bin/dep deploy production
Deploy to staging using rsync: # In deploy.php or servers config, enable rsync set('use_rsync', true); vendor/bin/dep deploy staging
Common TYPO3 commands: vendor/bin/dep typo3:cache:flush # Clear all TYPO3 caches vendor/bin/dep typo3:cache:warmup # Warmup system caches vendor/bin/dep typo3:language:update # Update extension language files vendor/bin/dep typo3:extension:setup # Set up all extensions vendor/bin/dep typo3:install:fixfolderstructure # Automatically create required files and folders for TYPO3
Parse composer.json and return its contents as an array. Used for auto-detecting TYPO3 settings like public_dir and bin_dir.
return json_decode(file_get_contents('./composer.json'), true, 512, JSON_THROW_ON_ERROR);
TYPO3 public (web) directory. Automatically determined from composer.json. Defaults to "public". :::info Autogenerated The value of this configuration is autogenerated on access. :::
Path to the TYPO3 CLI binary. Determined from composer.json "config.bin-dir" or defaults to "vendor/bin/typo3". :::info Autogenerated The value of this configuration is autogenerated on access. :::
Log files to display when running ./vendor/bin/dep logs:app
'var/log/typo3_*.log'
Overrides shared_dirs from recipe/deploy/shared.php.
Directories that persist between releases. Shared via symlinks from the shared/ directory.
[
'{{typo3/public_dir}}/fileadmin',
'{{typo3/public_dir}}/typo3temp/assets',
'var/lock',
'var/log',
'var/session',
'var/spool',
]
Overrides writable_dirs from recipe/deploy/writable.php.
Writeable directories
[
'{{typo3/public_dir}}/fileadmin',
'{{typo3/public_dir}}/typo3temp/assets',
'var/cache',
'var/lock',
'var/log',
]
Overrides composer_options from recipe/deploy/vendors.php.
Composer install options for production.
' --no-dev --verbose --prefer-dist --no-progress --no-interaction --optimize-autoloader'
If set in the config this recipe uses rsync. Default setting: false (uses the Git repository)
false
return get('use_rsync') ? 'rsync' : 'deploy:update_code';
[
'exclude' => array_merge(get('shared_dirs'), get('shared_files'), $exclude),
'exclude-file' => false,
'include' => ['vendor'],
'include-file' => false,
'filter' => ['dir-merge,-n /.gitignore'],
'filter-file' => false,
'filter-perdir' => false,
'flags' => 'avz',
'options' => ['delete', 'keep-dirlinks', 'links'],
'timeout' => 600,
]
TYPO3 - Clear all caches.
TYPO3 Commands All run via bin/php release_path/bin/typo3 <command>
TYPO3 - Cache warmup for system caches.
TYPO3 - Update the language files of all activated extensions.
TYPO3 - Set up all extensions.
TYPO3 - Fix folder structure.
Deploys a TYPO3 project.
Main deploy task for TYPO3.
This task is group task which contains next tasks: