feat(web,mobile): English imprint + privacy pages with browser-lang detection #254
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 | |
| on: | |
| push: | |
| branches: [main] | |
| pull_request: | |
| branches: [main] | |
| concurrency: | |
| group: ci-${{ github.workflow }}-${{ github.head_ref || github.run_id }} | |
| cancel-in-progress: ${{ github.event_name == 'pull_request' }} | |
| jobs: | |
| lint: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - uses: dtolnay/rust-toolchain@stable | |
| with: | |
| components: rustfmt, clippy | |
| - uses: Swatinem/rust-cache@v2 | |
| with: | |
| workspaces: backend | |
| - uses: extractions/setup-just@v3 | |
| - name: cargo fmt | |
| run: just lint-backend-fmt | |
| - name: cargo clippy | |
| run: just lint-backend-clippy | |
| backend: | |
| runs-on: ubuntu-latest | |
| services: | |
| db: | |
| image: postgis/postgis:16-3.4 | |
| env: | |
| POSTGRES_USER: test | |
| POSTGRES_PASSWORD: test | |
| POSTGRES_DB: test | |
| ports: | |
| - 5432:5432 | |
| options: >- | |
| --health-cmd "pg_isready -U test" | |
| --health-interval 5s | |
| --health-timeout 5s | |
| --health-retries 10 | |
| env: | |
| TEST_DATABASE_URL: postgres://test:test@localhost:5432/test | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - uses: dtolnay/rust-toolchain@stable | |
| - uses: Swatinem/rust-cache@v2 | |
| with: | |
| workspaces: backend | |
| - uses: extractions/setup-just@v3 | |
| - name: cargo test | |
| run: just test-backend | |
| frontend: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - uses: actions/setup-node@v4 | |
| with: | |
| node-version: 22 | |
| cache: npm | |
| cache-dependency-path: web/package-lock.json | |
| - run: npm ci | |
| working-directory: web | |
| - uses: extractions/setup-just@v3 | |
| - name: build | |
| run: just build-web | |
| - name: vitest + mobile-style parity | |
| run: just test-web | |
| frontend-e2e: | |
| runs-on: ubuntu-latest | |
| if: github.event_name != 'pull_request' || github.event.pull_request.draft != true | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - uses: actions/setup-node@v4 | |
| with: | |
| node-version: 22 | |
| cache: npm | |
| cache-dependency-path: web/package-lock.json | |
| - run: npm ci | |
| working-directory: web | |
| - name: Cache Playwright browsers | |
| uses: actions/cache@v4 | |
| with: | |
| path: ~/.cache/ms-playwright | |
| key: playwright-${{ runner.os }}-${{ hashFiles('web/package-lock.json') }} | |
| - name: Install Playwright chromium | |
| run: npx playwright install --with-deps chromium | |
| working-directory: web | |
| - uses: extractions/setup-just@v3 | |
| - name: playwright smoke | |
| run: just test-e2e-web | |
| - name: Upload Playwright report on failure | |
| if: failure() | |
| uses: actions/upload-artifact@v4 | |
| with: | |
| name: playwright-report | |
| path: | | |
| web/playwright-report | |
| web/test-results | |
| retention-days: 7 | |
| ship: | |
| needs: [lint, backend, frontend, frontend-e2e] | |
| if: github.event_name == 'push' | |
| uses: ./.github/workflows/cd.yml | |
| secrets: inherit | |
| permissions: | |
| contents: read | |
| packages: write |