From 29ab2534847ffdb226ab2c990861c3daa927140b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bj=C3=B6rn=20Fromme?= Date: Tue, 4 Oct 2022 17:32:39 +0200 Subject: [PATCH] Upgrade deployer and use official GitHub action --- .github/workflows/deploy.yaml | 9 +++++---- composer.json | 2 +- deploy.php | 4 +++- 3 files changed, 9 insertions(+), 6 deletions(-) diff --git a/.github/workflows/deploy.yaml b/.github/workflows/deploy.yaml index 03b253b5..62143496 100644 --- a/.github/workflows/deploy.yaml +++ b/.github/workflows/deploy.yaml @@ -4,6 +4,8 @@ on: push: branches: [ master ] +concurrency: production_environment + jobs: build: name: Build assets and deploy @@ -42,8 +44,7 @@ jobs: - run: npm run build - name: Deploy - uses: musps/action-deployer-php@master + uses: deployphp/action@v1 with: - args: deploy production - env: - SSH_PRIVATE_KEY: ${{ secrets.SSH_PRIVATE_KEY }} + private-key: ${{ secrets.SSH_PRIVATE_KEY }} + dep: deploy production diff --git a/composer.json b/composer.json index 21fe94d0..5ad1a6cf 100644 --- a/composer.json +++ b/composer.json @@ -77,7 +77,7 @@ } }, "require-dev": { - "deployer/deployer": "^7", + "deployer/deployer": "^v7.0", "ichhabrecht/filefill": "^3.3", "typo3/testing-framework": "^6.16" }, diff --git a/deploy.php b/deploy.php index 38016e17..94f55cae 100644 --- a/deploy.php +++ b/deploy.php @@ -64,6 +64,7 @@ host('production') ->set('buspronet_path', '/home/www/p546128/html/kuschick/buspronet/buspronet') ->set('bin/php', '/usr/local/bin/php') ->set('http_user', 'p546128') + ->set('writable_mode', 'chmod') ->set('bin/composer', '/usr/local/bin/composer') ->set('composer_options', '--prefer-dist --no-progress --no-interaction --optimize-autoloader') ->set('rsync_src', __DIR__) @@ -83,6 +84,7 @@ host('staging') ->set('buspronet_path', '/home/www/p546128/html/kuschick/buspronet/buspronet') ->set('bin/php', '/usr/local/bin/php') ->set('http_user', 'p546128') + ->set('writable_mode', 'chmod') ->set('bin/composer', '/usr/local/bin/composer') ->set('composer_options', '--prefer-dist --no-progress --no-interaction --optimize-autoloader') ->set('rsync_src', __DIR__) @@ -93,7 +95,7 @@ host('staging') task('deploy', [ 'deploy:info', - 'deploy:prepare', + 'deploy:setup', 'deploy:lock', 'deploy:release', 'rsync',