Merge pull request #1 from patterncatalyst/feat/top-level-demo-runner #8
This file contains hidden or 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: CI | |
| # Fast, deterministic checks on every push/PR to main: | |
| # 1. Liquid hazard scan (scripts/check-liquid.py) — the four Liquid | |
| # build-breakers the Pages build has hit historically. | |
| # 2. Jekyll build via the github-pages gem — the same build GitHub Pages | |
| # runs, so a green job here means Pages will publish. | |
| # 3. hadolint lint of every Containerfile — gates on ERRORs only; style | |
| # warnings/info print as advice (see .hadolint.yaml). | |
| # | |
| # Full `podman build` of the example images is intentionally NOT run here: | |
| # several build gRPC / OpenTelemetry-cpp / libabigail from source (tens of | |
| # minutes) and would blow past sensible CI budgets. Verify those on the host | |
| # (see each demo's demo.sh) or add a manual `workflow_dispatch` job if needed. | |
| on: | |
| push: | |
| branches: [main] | |
| pull_request: | |
| workflow_dispatch: | |
| permissions: | |
| contents: read | |
| jobs: | |
| site: | |
| name: Build site (liquid + jekyll) | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - name: Liquid hazard check | |
| run: python3 scripts/check-liquid.py | |
| - uses: ruby/setup-ruby@v1 | |
| with: | |
| ruby-version: '3.3' # github-pages gem compatibility | |
| bundler-cache: true | |
| - name: Jekyll build (Pages-equivalent) | |
| env: | |
| JEKYLL_ENV: production | |
| run: bundle exec jekyll build | |
| lint-containerfiles: | |
| name: Lint Containerfiles | |
| runs-on: ubuntu-latest | |
| # Gates only on hadolint ERRORs (see .hadolint.yaml); style warnings/info | |
| # still print in the log but do not fail the build. | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - name: Install hadolint | |
| run: | | |
| sudo curl -fsSL -o /usr/local/bin/hadolint \ | |
| https://github.com/hadolint/hadolint/releases/download/v2.12.0/hadolint-Linux-x86_64 | |
| sudo chmod +x /usr/local/bin/hadolint | |
| - name: Run hadolint on every Containerfile | |
| run: | | |
| find examples -name 'Containerfile*' -print0 \ | |
| | xargs -0 -r -n1 hadolint |