# Deployer recipe for OXID 7.x This project uses [Deployer](https://deployer.org/) for scripted installation ## Preparation To setup the customer repository, see [provisioning](provisioning.md). ### Server setup Install Composer. Clone the repository into a separate directory (`deployer` for example) on your server and checkout this branch. Run `composer install` in it. Add an alias for the deployer command: `alias dep='/usr/local/php8.2/bin/php /home/XXX/deployer/vendor/bin/dep'`. Load the changed configuration. Change project settings in the `inventory.yml`. Create a deploy key (if it's not exist). Set it in the repository settings. Commit changed files. ### Update Deployer - `cd deployer` - `composer update` - commit changes ## Project ### Deployment - `cd deployer` - `dep deploy [stage]` ### Rollback ... in case of errors after successful deployment This command set `current` directory to previous deployment: - `dep rollback [stage]` ## Other available tasks - dep `shop:getVersion` [stage] - show version of current OXID installation - dep `shop:runMigration` [stage] - run all database migrations - dep `setup:createDbConfig` [stage] - generate database configuration file - dep `list`- list all available commands ### work in progress - dep `duplicateDatabase` [stage] - dump contents from source database (live) to destination database (stage) and replace live to stage URLs