Skip to content

Commit

Permalink
Merge pull request #1591 from bakaphp/feat-ec2-deploy-prod
Browse files Browse the repository at this point in the history
add docker compose to conditional
  • Loading branch information
rwhite27 authored Jul 1, 2024
2 parents 7428782 + 1a7dd21 commit 5713749
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion .github/workflows/ec2-deploy.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -40,10 +40,11 @@ jobs:
key: ${{ secrets.AWS_EC2_PRIVATE_SSH_KEY }}
script: |
cd ${{secrets.AWS_EC2_TARGET_DIR}}
docker compose -f docker-compose.${{ github.ref_name }}.yml up -d
if ["docker-compose.${{ github.ref_name }}.yml" == "docker-compose.1.x.yml"]; then
docker-compose -f docker-compose.${{ github.ref_name }}.yml up -d
docker exec -i phpkanvas-ecosystem composer install --no-dev --optimize-autoloader;
else
docker compose -f docker-compose.${{ github.ref_name }}.yml up -d
docker exec -i phpkanvas-ecosystem composer install --optimize-autoloader;
fi
docker exec -i phpkanvas-ecosystem php artisan lighthouse:cache
Expand Down

0 comments on commit 5713749

Please sign in to comment.