Closed jlmmns closed 1 year ago
https://github.com/deployphp/action/issues/21
Output when it randomly fails, without proper debugging info (using -vvv)
2021-08-31T08:34:15.4531783Z ##[group]Run deployphp/action@master 2021-08-31T08:34:15.4533452Z with: 2021-08-31T08:34:15.4587951Z private-key: *** 2021-08-31T08:34:15.4602740Z known-hosts: *** 2021-08-31T08:34:15.4604557Z dep: deploy devweb1 -f ./.github/deploy.yml -vvv 2021-08-31T08:34:15.4606300Z env: 2021-08-31T08:34:15.4608143Z repo_url: https://github.com/organization/repo 2021-08-31T08:34:15.4610591Z assets_artifact_name: deploy-develop-#138-assets 2021-08-31T08:34:15.4612374Z ##[endgroup] 2021-08-31T08:34:16.5438689Z ##[error]Command failed with exit code 1: vendor/bin/dep deploy devweb1 -f ./.github/deploy.yml -vvv
Job
deploy-web1: name: deploy web1 runs-on: ubuntu-20.04 needs: build steps: - name: Set up PHP uses: shivammathur/setup-php@v2 with: php-version: 7.4 tools: composer:v2 - name: Checkout Repository uses: actions/checkout@v2 - name: Create .env file run: | printf "${{ secrets.DOT_ENV_DEVELOP }}" >> ./.env - name: Set up cache directory for Composer id: composer-cache run: | echo "::set-output name=dir::$(composer config cache-files-dir)" - name: Use cache directory for Composer uses: actions/cache@v2 with: path: ${{ steps.composer-cache.outputs.dir }} key: ${{ runner.os }}-composer-${{ hashFiles('composer.lock') }} restore-keys: | ${{ runner.os }}-composer- - name: Install Composer Dependencies run: composer install -q --no-ansi --no-interaction --no-scripts --no-progress --prefer-dist - name: Download compiled assets uses: actions/download-artifact@v2 with: name: ${{ env.assets_artifact_name }} path: public - name: Move Deployer Binary run: | mv ./.github/deployer.phar ./vendor/bin/dep chmod +x ./vendor/bin/dep - name: Run Deployer uses: deployphp/action@master with: private-key: ${{ secrets.SSH_PRIVATE_KEY_WEB1 }} known-hosts: ${{ secrets.SSH_KNOWN_HOSTS_WEB1 }} dep: deploy devweb1 -f ./.github/deploy.yml -vvv
.github/deploy.yml
import: - recipe/laravel.php - contrib/rsync.php - contrib/php-fpm.php config: application: repo repository: git@github.com:organization/repo.git php_fpm_version: 7.4 shared_files: [] hosts: devweb1: stage: develop hostname: 'ip_address_1' rsync_src: ./../ rsync_dest: '{{release_path}}' deploy_path: /var/web/ssh_username/repo remote_user: ssh_username ssh_multiplexing: false ssh_type: native port: 22 devweb2: stage: develop hostname: 'ip_address_2' rsync_src: ./../ rsync_dest: '{{release_path}}' deploy_path: /var/web/ssh_username/repo remote_user: ssh_username ssh_multiplexing: false ssh_type: native port: 22 tasks: deploy: - deploy:info - deploy:setup - deploy:lock - deploy:release - git:clone - rsync - deploy:shared - deploy:writable - deploy:vendors - artisan:key:generate - artisan:storage:link - artisan:migrate # # TODO: Remove anonymous functions to enable caching. # - artisan:config:cache # - artisan:route:cache - artisan:view:cache - deploy:symlink - deploy:unlock - deploy:cleanup - deploy:success - php-fpm:reload git:clone: script: - 'cd {{release_path}}' - 'git clone -b develop {{repository}} .' after: deploy:failed: deploy:unlock
Hmm, could it be this?
mv ./.github/deployer.phar ./vendor/bin/dep
https://github.com/deployphp/action/issues/21
Output when it randomly fails, without proper debugging info (using -vvv)
Job
.github/deploy.yml
Upvote & Fund