feat: add deployment to production
This commit is contained in:
@@ -28,14 +28,7 @@ jobs:
|
|||||||
with:
|
with:
|
||||||
php-version: ${{ env.PHP_VERSION }}
|
php-version: ${{ env.PHP_VERSION }}
|
||||||
|
|
||||||
- name: Check if composer.json exists
|
|
||||||
id: check_files
|
|
||||||
uses: andstor/file-existence-action@87d74d4732ddb824259d80c8a508c0124bf1c673
|
|
||||||
with:
|
|
||||||
files: 'composer.json'
|
|
||||||
|
|
||||||
- name: Run composer install if composer.json exists
|
- name: Run composer install if composer.json exists
|
||||||
if: steps.check_files.outputs.files_exists == 'true'
|
|
||||||
run: |
|
run: |
|
||||||
composer validate --no-check-publish && composer install --prefer-dist --no-progress --ignore-platform-reqs
|
composer validate --no-check-publish && composer install --prefer-dist --no-progress --ignore-platform-reqs
|
||||||
|
|
||||||
@@ -109,28 +102,28 @@ jobs:
|
|||||||
dep: --file=./build/deploy.php release:switch stage
|
dep: --file=./build/deploy.php release:switch stage
|
||||||
private-key: ${{secrets.STAGE_KEY}}
|
private-key: ${{secrets.STAGE_KEY}}
|
||||||
|
|
||||||
# deploy-production:
|
deploy-production:
|
||||||
# needs: build
|
needs: build
|
||||||
# runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
# steps:
|
steps:
|
||||||
# - name: Setup PHP
|
- name: Setup PHP
|
||||||
# uses: shivammathur/setup-php@7c0b4c8c8ebed23eca9ec2802474895d105b11bc
|
uses: shivammathur/setup-php@7c0b4c8c8ebed23eca9ec2802474895d105b11bc
|
||||||
# with:
|
with:
|
||||||
# php-version: ${{ env.PHP_VERSION }}
|
php-version: ${{ env.PHP_VERSION }}
|
||||||
# - uses: actions/download-artifact@v3
|
- uses: actions/download-artifact@v3
|
||||||
# with:
|
with:
|
||||||
# name: typo3
|
name: typo3
|
||||||
# - name: Extract artifact
|
- name: Extract artifact
|
||||||
# run: |
|
run: |
|
||||||
# tar xf typo3.tar.gz
|
tar xf typo3.tar.gz
|
||||||
# rm typo3.tar.gz
|
rm typo3.tar.gz
|
||||||
# - name: Install ssh agent and rsync
|
- name: Install ssh agent and rsync
|
||||||
# run: |
|
run: |
|
||||||
# apt update
|
apt update
|
||||||
# apt install -y openssh-client rsync
|
apt install -y openssh-client rsync
|
||||||
# - name: Deploy
|
- name: Deploy
|
||||||
# uses: deployphp/action@v1
|
uses: deployphp/action@v1
|
||||||
# with:
|
with:
|
||||||
# deployer-binary: "./bin/dep"
|
deployer-binary: "./bin/dep"
|
||||||
# dep: --file=./build/deploy.php release:create production
|
dep: --file=./build/deploy.php release:create production
|
||||||
# private-key: ${{secrets.PROD_KEY}}
|
private-key: ${{secrets.PROD_KEY}}
|
||||||
|
|||||||
@@ -20,13 +20,7 @@ jobs:
|
|||||||
uses: shivammathur/setup-php@7c0b4c8c8ebed23eca9ec2802474895d105b11bc
|
uses: shivammathur/setup-php@7c0b4c8c8ebed23eca9ec2802474895d105b11bc
|
||||||
with:
|
with:
|
||||||
php-version: ${{ env.PHP_VERSION }}
|
php-version: ${{ env.PHP_VERSION }}
|
||||||
- name: Check if composer.json exists
|
- name: Run composer install
|
||||||
id: check_files
|
|
||||||
uses: andstor/file-existence-action@87d74d4732ddb824259d80c8a508c0124bf1c673
|
|
||||||
with:
|
|
||||||
files: 'composer.json'
|
|
||||||
- name: Run composer install if composer.json exists
|
|
||||||
if: steps.check_files.outputs.files_exists == 'true'
|
|
||||||
run: |
|
run: |
|
||||||
composer validate --no-check-publish && composer install --prefer-dist --no-progress --ignore-platform-reqs
|
composer validate --no-check-publish && composer install --prefer-dist --no-progress --ignore-platform-reqs
|
||||||
- name: Install ssh agent, rsync
|
- name: Install ssh agent, rsync
|
||||||
|
|||||||
@@ -2,7 +2,7 @@ hosts:
|
|||||||
production:
|
production:
|
||||||
stage: production
|
stage: production
|
||||||
hostname: web-arm.cloonar.com
|
hostname: web-arm.cloonar.com
|
||||||
remote_user: gbv_aktuell_at
|
remote_user: lena_schilling_at
|
||||||
writable_mode: chmod
|
writable_mode: chmod
|
||||||
forward_agent: true
|
forward_agent: true
|
||||||
deploy_path: ~/
|
deploy_path: ~/
|
||||||
|
|||||||
Reference in New Issue
Block a user