2024-11-03 20:43:45 +01:00
# Deployer recipe for OXID 7.x
2024-10-16 08:20:07 +02:00
2024-11-03 20:43:45 +01:00
This project uses [Deployer ](https://deployer.org/ ) for scripted installation.
The project can usually also be used for projects based on OXID 6.4 and 6.5.
2024-10-16 08:20:07 +02:00
2024-10-18 16:46:34 +02:00
### Server setup
2024-10-16 08:20:07 +02:00
2024-10-30 15:59:00 +01:00
Install [Composer ](https://getcomposer.org/ ).
2024-11-03 20:43:45 +01:00
Run the command `composer create-project --no-dev d3/oxid-deployer-project deployer ^1.0`
2024-10-16 08:20:07 +02:00
2024-10-30 15:59:00 +01:00
After that, add an alias for the deployer command: `alias dep='/usr/local/php8.2/bin/php /home/XXX/deployer/vendor/bin/dep'` and reload the changed configuration.
2024-10-16 08:20:07 +02:00
2024-10-30 15:59:00 +01:00
Rename `inventory.yml.dist` to `inventory.yml` and change project settings in it.
2024-10-16 08:20:07 +02:00
2024-10-30 15:59:00 +01:00
Make sure, that Deployer has at least read access to the customers repository.
2024-10-16 08:20:07 +02:00
2024-10-30 15:59:00 +01:00
Commit changed files in the customers repository.
2024-10-16 08:20:07 +02:00
### Update Deployer
- `cd deployer`
- `composer update`
2024-10-30 15:59:00 +01:00
- apply changes in the `inventory.yml`
2024-10-25 11:23:34 +02:00
- commit changes
2024-10-16 08:20:07 +02:00
## Project
### Deployment
- `cd deployer`
2024-10-17 08:55:37 +02:00
- `dep deploy [stage]`
2024-10-16 08:20:07 +02:00
### Rollback
... in case of errors after successful deployment
This command set `current` directory to previous deployment:
2024-10-17 08:55:37 +02:00
- `dep rollback [stage]`
2024-10-16 08:20:07 +02:00
2024-10-25 11:23:34 +02:00
## Other available tasks
2024-10-16 08:20:07 +02:00
2024-11-02 14:43:29 +01:00
Run `dep list` to show all available tasks.