Bump rubyzip from 3.3.1 to 3.4.0 #4218
Workflow file for this run
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 | |
| permissions: | |
| contents: read | |
| on: | |
| pull_request: | |
| push: | |
| branches: [main] | |
| jobs: | |
| scan_ruby: | |
| runs-on: ubuntu-latest | |
| permissions: | |
| contents: read | |
| security-events: write | |
| steps: | |
| - name: Checkout code | |
| uses: actions/checkout@v6 | |
| - name: Set up Ruby | |
| uses: ruby/setup-ruby@v1 | |
| with: | |
| ruby-version: .ruby-version | |
| bundler-cache: true | |
| - name: Scan for vulnerabilities with Brakeman | |
| continue-on-error: true | |
| run: bin/brakeman --no-pager -f sarif -o brakeman.sarif.json | |
| - name: Upload SARIF to GitHub Code Scanning | |
| uses: github/codeql-action/upload-sarif@v4 | |
| with: | |
| sarif_file: brakeman.sarif.json | |
| scan_js: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Checkout code | |
| uses: actions/checkout@v6 | |
| - name: Set up Ruby | |
| uses: ruby/setup-ruby@v1 | |
| with: | |
| ruby-version: .ruby-version | |
| bundler-cache: true | |
| - name: Scan for security vulnerabilities in JavaScript dependencies | |
| run: bin/importmap audit | |
| lint: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Checkout code | |
| uses: actions/checkout@v6 | |
| - name: Set up Ruby | |
| uses: ruby/setup-ruby@v1 | |
| with: | |
| ruby-version: .ruby-version | |
| bundler-cache: true | |
| - name: Lint code for consistent style | |
| run: bin/rubocop -f github | |
| frontend: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Checkout code | |
| uses: actions/checkout@v6 | |
| - name: Set up Ruby | |
| uses: ruby/setup-ruby@v1 | |
| with: | |
| ruby-version: .ruby-version | |
| bundler-cache: true | |
| - name: Set up Bun | |
| uses: oven-sh/setup-bun@v2 | |
| - name: Install JavaScript dependencies | |
| run: bun install --frozen-lockfile | |
| - name: Generate js_from_routes path helpers | |
| env: | |
| JS_FROM_ROUTES_FORCE: "true" | |
| run: bin/rake js_from_routes:generate | |
| - name: Run Svelte type checks | |
| run: bun run check:svelte | |
| - name: Run Svelte formatting checks | |
| run: bun run format:svelte:check | |
| - name: Run Knip (unused files / deps / exports) | |
| run: bun run knip | |
| zeitwerk: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Checkout code | |
| uses: actions/checkout@v6 | |
| - name: Set up Ruby | |
| uses: ruby/setup-ruby@v1 | |
| with: | |
| ruby-version: .ruby-version | |
| bundler-cache: true | |
| - name: Run Rails Zeitwerk check | |
| run: bin/rails zeitwerk:check | |
| docker_build: | |
| runs-on: blacksmith-4vcpu-ubuntu-2404 | |
| strategy: | |
| fail-fast: false | |
| matrix: | |
| dockerfile: [Dockerfile, Dockerfile.dev] | |
| steps: | |
| - name: Checkout code | |
| uses: actions/checkout@v6 | |
| - name: Setup Blacksmith Builder | |
| uses: useblacksmith/setup-docker-builder@v1 | |
| - name: Build ${{ matrix.dockerfile }} | |
| uses: useblacksmith/build-push-action@v2 | |
| with: | |
| context: . | |
| file: ${{ matrix.dockerfile }} | |
| push: false | |
| load: false | |
| test: | |
| runs-on: blacksmith-4vcpu-ubuntu-2404 | |
| services: | |
| postgres: | |
| image: postgres:16-alpine | |
| ports: | |
| - 5432:5432 | |
| options: --health-cmd pg_isready --health-interval 10s --health-timeout 5s --health-retries 5 | |
| env: | |
| POSTGRES_USER: postgres | |
| POSTGRES_PASSWORD: postgres | |
| POSTGRES_DB: app_test | |
| steps: | |
| - name: Checkout code | |
| uses: actions/checkout@v6 | |
| - name: Set up Ruby | |
| uses: ruby/setup-ruby@v1 | |
| with: | |
| ruby-version: .ruby-version | |
| bundler-cache: true | |
| - name: Run tests | |
| env: | |
| RAILS_ENV: test | |
| TEST_DATABASE_URL: postgres://postgres:postgres@localhost:5432/app_test | |
| PGHOST: localhost | |
| PGUSER: postgres | |
| PGPASSWORD: postgres | |
| run: | | |
| bin/rails db:create RAILS_ENV=test | |
| bin/rails db:schema:load RAILS_ENV=test | |
| bin/rails test | |
| - name: Ensure Swagger docs are up to date | |
| env: | |
| RAILS_ENV: test | |
| TEST_DATABASE_URL: postgres://postgres:postgres@localhost:5432/app_test | |
| PGHOST: localhost | |
| PGUSER: postgres | |
| PGPASSWORD: postgres | |
| run: | | |
| bin/rails rswag:specs:swaggerize | |
| git diff --exit-code swagger/ | |
| test_system: | |
| runs-on: blacksmith-4vcpu-ubuntu-2404 | |
| services: | |
| postgres: | |
| image: postgres:16-alpine | |
| ports: | |
| - 5432:5432 | |
| options: --health-cmd pg_isready --health-interval 10s --health-timeout 5s --health-retries 5 | |
| env: | |
| POSTGRES_USER: postgres | |
| POSTGRES_PASSWORD: postgres | |
| POSTGRES_DB: app_test | |
| steps: | |
| - name: Checkout code | |
| uses: actions/checkout@v6 | |
| - name: Set up Ruby | |
| uses: ruby/setup-ruby@v1 | |
| with: | |
| ruby-version: .ruby-version | |
| bundler-cache: true | |
| - name: Set up Bun | |
| uses: oven-sh/setup-bun@v2 | |
| - name: Setup Chrome | |
| id: setup-chrome | |
| uses: browser-actions/setup-chrome@latest | |
| with: | |
| install-chromedriver: true | |
| - name: Install JavaScript dependencies | |
| run: bun install --frozen-lockfile | |
| - name: Generate js_from_routes path helpers | |
| env: | |
| JS_FROM_ROUTES_FORCE: "true" | |
| run: bin/rake js_from_routes:generate | |
| - name: Pre-build Vite assets for test | |
| run: bin/vite build | |
| env: | |
| RAILS_ENV: test | |
| - name: Run system tests | |
| env: | |
| RAILS_ENV: test | |
| TEST_DATABASE_URL: postgres://postgres:postgres@localhost:5432/app_test | |
| PGHOST: localhost | |
| PGUSER: postgres | |
| PGPASSWORD: postgres | |
| CHROME_BIN: ${{ steps.setup-chrome.outputs.chrome-path }} | |
| CHROMEDRIVER_BIN: ${{ steps.setup-chrome.outputs.chromedriver-path }} | |
| run: | | |
| bin/rails db:create RAILS_ENV=test | |
| bin/rails db:schema:load RAILS_ENV=test | |
| bin/rails test:system | |
| - name: Keep screenshots from failed system tests | |
| uses: actions/upload-artifact@v7 | |
| if: failure() | |
| with: | |
| name: screenshots | |
| path: ${{ github.workspace }}/tmp/screenshots | |
| if-no-files-found: ignore |