update documentation

This commit is contained in:
Daniel Seifert 2024-10-18 16:46:34 +02:00
parent c98b0ab3f2
commit ca042a3a3f
2 changed files with 26 additions and 5 deletions

View File

@ -4,17 +4,21 @@ This project uses [Deployer](https://deployer.org/) for scripted installation
## Preparation
### Initial setup
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`. Commit the `composer.lock` file, if it's changed.
Run `composer install`.
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
@ -39,10 +43,8 @@ This command set `current` directory to previous deployment:
## Available tasks
- dep `deploy` [stage] - create a new release for defined stage
- dep `rollback` [stage] - switch to previous release
- dep `migrate`[stage] - run all database migrations
- dep `setup:createDbConfig` [stage] - generate database configuration file
- dep `list`- list all available commands
### work in progress

19
provisioning.md Normal file
View File

@ -0,0 +1,19 @@
# Provisioning
## initial
- checkout the customer repository
- `git remote add deployment gitfhfac@git.d3data.de:D3Private/deployerRecipes.git && git remote set-url --push deployment DONTPUSH`
- `git fetch deployment`
- `git switch -c deployment deployment/[template branch]`
checkout remote branch and rename it to `deployment`
- `git push origin deployment`
- `git remote rm deployment`
## update
- checkout the customer repository
- `git checkout deployment && git pull origin deployment`
- `git remote add deployment gitfhfac@git.d3data.de:D3Private/deployerRecipes.git && git remote set-url --push deployment DONTPUSH`
- `git fetch deployment`
- `git merge deployment/[template branch]`
- `git push origin deployment`
- `git remote rm deployment`