updates info #6
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Laravel CI/CD Workflow | |
on: | |
push: | |
branches: | |
- main | |
pull_request: | |
branches: | |
- main | |
workflow_dispatch: | |
jobs: | |
ci: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout code | |
uses: actions/checkout@v2 | |
- name: Run CI job | |
uses: basantsd/laravel-ci-cd@v2 | |
with: | |
job: 'ci' | |
github_token: ${{ secrets.GITHUB_TOKEN }} | |
repo: 'your-username/your-repo' | |
code_cleanup: | |
runs-on: ubuntu-latest | |
needs: ci | |
steps: | |
- name: Checkout code | |
uses: actions/checkout@v2 | |
- name: Run Code Cleanup job | |
uses: basantsd/laravel-ci-cd@v2 | |
with: | |
job: 'code_cleanup' | |
github_token: ${{ secrets.GITHUB_TOKEN }} | |
repo: 'your-username/your-repo' | |
cd: | |
runs-on: ubuntu-latest | |
needs: code_cleanup | |
steps: | |
- name: Checkout code | |
uses: actions/checkout@v2 | |
- name: Run CD job | |
uses: basantsd/laravel-ci-cd@v2 | |
with: | |
job: 'cd' | |
vps_private_key: ${{ secrets.VPS_PRIVATE_KEY }} | |
vps_username: ${{ secrets.VPS_USERNAME }} | |
vps_host: ${{ secrets.VPS_HOST }} | |
deploy_path: '/path/to/deploy' | |
production_branch: 'main' | |
php_version: '8.0' | |
github_token: ${{ secrets.GITHUB_TOKEN }} | |
repo: 'your-username/your-repo' |