Back to Blog
GitHub ActionsCI/CDDevOpsAutomation

GitHub Actions: Advanced CI/CD Patterns

Build effective CI/CD pipelines with GitHub Actions. Learn workflow patterns, caching, and deployment strategies.

B
Bootspring Team
Engineering
February 27, 2026
1 min read

GitHub Actions automates your build, test, and deployment workflows.

Basic CI Workflow#

1name: CI 2 3on: 4 push: 5 branches: [main] 6 pull_request: 7 branches: [main] 8 9jobs: 10 build: 11 runs-on: ubuntu-latest 12 steps: 13 - uses: actions/checkout@v4 14 - uses: actions/setup-node@v4 15 with: 16 node-version: '20' 17 cache: 'npm' 18 - run: npm ci 19 - run: npm run lint 20 - run: npm test 21 - run: npm run build

Matrix Testing#

1jobs: 2 test: 3 runs-on: ${{ matrix.os }} 4 strategy: 5 matrix: 6 os: [ubuntu-latest, windows-latest] 7 node: [18, 20, 22] 8 steps: 9 - uses: actions/checkout@v4 10 - uses: actions/setup-node@v4 11 with: 12 node-version: ${{ matrix.node }} 13 - run: npm ci && npm test

Reusable Workflows#

1# .github/workflows/reusable-deploy.yml 2on: 3 workflow_call: 4 inputs: 5 environment: 6 required: true 7 type: string 8 9jobs: 10 deploy: 11 runs-on: ubuntu-latest 12 environment: ${{ inputs.environment }} 13 steps: 14 - uses: actions/checkout@v4 15 - run: ./deploy.sh ${{ inputs.environment }}

Conditional Jobs#

1jobs: 2 changes: 3 outputs: 4 frontend: ${{ steps.filter.outputs.frontend }} 5 steps: 6 - uses: dorny/paths-filter@v3 7 id: filter 8 with: 9 filters: | 10 frontend: 11 - 'frontend/**' 12 13 frontend-tests: 14 needs: changes 15 if: ${{ needs.changes.outputs.frontend == 'true' }} 16 runs-on: ubuntu-latest 17 steps: 18 - run: npm test

GitHub Actions provides flexible automation for any CI/CD workflow.

Share this article

Help spread the word about Bootspring