Skip to content

Modern Docker Management, Designed for Everyone

chore: move main push ci to depot ci

Kyle Mendella5b9fa0006f5
diff --git a/.depot/workflows/ci.yml b/.depot/workflows/ci.yml
new file mode 100644
index 000000000..a13696469
--- /dev/null
+++ b/.depot/workflows/ci.yml
@@ -0,0 +1,293 @@
+name: CI
+
+env:
+ GOEXPERIMENT: jsonv2
+
+on:
+ push:
+ branches: [main]
+
+permissions:
+ contents: read
+ actions: read
+ checks: write
+ id-token: write
+
+concurrency:
+ group: "${{ github.workflow }}-${{ github.ref }}"
+ cancel-in-progress: true
+
+jobs:
+ go-tests:
+ name: Go Tests (${{ matrix.module.name }})
+ runs-on: depot-ubuntu-latest
+ timeout-minutes: 30
+ strategy:
+ fail-fast: false
+ matrix:
+ module:
+ - name: backend
+ path: backend
+ timeout: 30
+ gcc: true
+ cgo_enabled: "1"
+ - name: cli
+ path: cli
+ timeout: 10
+ gcc: false
+ cgo_enabled: "1"
+ - name: types
+ path: types
+ timeout: 10
+ gcc: false
+ cgo_enabled: "1"
+ steps:
+ - name: Checkout
+ uses: actions/[email protected]
+
+ - name: Setup Just
+ uses: extractions/setup-just@v4
+
+ - name: Set up Depot CLI
+ if: matrix.module.gcc
+ uses: depot/setup-action@v1
+
+ - name: Setup Go
+ uses: actions/setup-go@v6
+ with:
+ go-version-file: ${{ matrix.module.path }}/go.mod
+ cache: true
+ cache-dependency-path: ${{ matrix.module.path }}/go.sum
+
+ - name: Install GCC
+ if: matrix.module.gcc
+ run: |
+ sudo apt-get update
+ sudo apt-get install -y gcc
+
+ - name: Download modules
+ run: just deps install go
+
+ - name: Run unit tests
+ env:
+ CGO_ENABLED: ${{ matrix.module.cgo_enabled }}
+ GO_JUNIT_REPORT_FILE: test-results/junit.xml
+ run: just test ${{ matrix.module.name }}
+
+ - name: Report Go test results to Depot
+ if: ${{ !cancelled() }}
+ uses: depot/test-report-action@v1
+ with:
+ path: ${{ matrix.module.path }}/test-results/
+
+ - name: Upload coverage artifact
+ if: always()
+ uses: actions/upload-artifact@v7
+ with:
+ name: ${{ matrix.module.name }}-coverage
+ path: ${{ matrix.module.path }}/coverage.txt
+
+ go-linter:
+ name: Go Linter (${{ matrix.module.name }})
+ runs-on: depot-ubuntu-latest
+ strategy:
+ fail-fast: false
+ matrix:
+ module:
+ - name: backend
+ args: --build-tags=exclude_frontend --config=../.github/.golangci.yml
+ - name: cli
+ args: --config=../.github/.golangci.yml
+ - name: types
+ args: --config=../.github/.golangci.yml
+ steps:
+ - name: Checkout code
+ uses: actions/[email protected]
+
+ - name: Set up Go
+ uses: actions/setup-go@v6
+ with:
+ go-version-file: ${{ matrix.module.name }}/go.mod
+ cache-dependency-path: ${{ matrix.module.name }}/go.sum
+
+ - name: Run Golangci-lint
+ uses: golangci/[email protected]
+ with:
+ version: latest
+ args: ${{ matrix.module.args }}
+ working-directory: ${{ matrix.module.name }}
+ only-new-issues: false
+
+ type-check:
+ name: Type Check
+ runs-on: depot-ubuntu-latest
+ steps:
+ - name: Checkout code
+ uses: actions/[email protected]
+
+ - name: Setup pnpm
+ uses: pnpm/action-setup@v6
+
+ - name: Setup Node.js
+ uses: actions/setup-node@v6
+ with:
+ node-version: 26
+ cache: pnpm
+
+ - name: Setup Just
+ uses: extractions/setup-just@v4
+
+ - name: Install Node dependencies
+ run: pnpm install --frozen-lockfile
+
+ - name: Add svelte-check problem matcher
+ run: echo "::add-matcher::.github/matchers/svelte-check-matcher.json"
+
+ - name: Build frontend
+ run: just build single frontend
+
+ - name: Run workspace type checks
+ run: just lint js
+
+ e2e-tests:
+ name: E2E Tests (${{ matrix.database.name }})
+ runs-on: depot-ubuntu-24.04-4
+ permissions:
+ contents: read
+ actions: write
+ id-token: write
+ strategy:
+ fail-fast: false
+ matrix:
+ database:
+ - name: sqlite
+ compose_file: setup/compose.yaml
+ port: 3000
+ - name: postgres
+ compose_file: setup/compose-postgres.yaml
+ port: 3001
+ - name: proxy
+ compose_file: setup/compose-proxy.yaml
+ port: 3002
+ steps:
+ - name: Checkout code
+ uses: actions/[email protected]
+
+ - name: Setup pnpm
+ uses: pnpm/action-setup@v6
+ with:
+ run_install: false
+
+ - name: Setup Just
+ uses: extractions/setup-just@v4
+
+ - name: Setup Node.js
+ uses: actions/setup-node@v6
+ with:
+ node-version: 26
+ cache: pnpm
+
+ - name: Set up Depot CLI
+ uses: depot/setup-action@v1
+
+ - name: Setup depot buildx driver
+ run: depot configure-docker
+
+ - name: Cache Playwright Browsers
+ uses: actions/[email protected]
+ id: playwright-cache
+ with:
+ path: ~/.cache/ms-playwright
+ key: ${{ runner.os }}-playwright-${{ hashFiles('tests/pnpm-lock.yaml', 'tests/package.json') }}
+ restore-keys: |
+ ${{ runner.os }}-playwright-
+
+ - name: Pull and save test images
+ run: |
+ docker pull public.ecr.aws/nginx/nginx:stable-alpine
+ docker pull ghcr.io/linuxserver/radarr:nightly
+ docker save public.ecr.aws/nginx/nginx:stable-alpine ghcr.io/linuxserver/radarr:nightly > /tmp/test-images.tar
+
+ - name: Setup and Install Playwright Dependencies
+ run: just deps install tests
+
+ - name: Run Playwright E2E tests
+ run: mkdir -p tests/test-results && pnpm -C tests exec playwright test --project=chromium
+ env:
+ COMPOSE_FILE: ${{ matrix.database.compose_file }}
+ BASE_URL: http://localhost:${{ matrix.database.port }}
+ PLAYWRIGHT_JUNIT_OUTPUT_FILE: test-results/playwright-${{ matrix.database.name }}.xml
+
+ - name: Upload Playwright HTML report
+ if: always()
+ uses: actions/upload-artifact@v7
+ with:
+ name: playwright-report-${{ matrix.database.name }}
+ path: tests/.report
+ include-hidden-files: true
+ retention-days: 15
+
+ - name: Report Playwright test results to Depot
+ if: ${{ !cancelled() }}
+ uses: depot/test-report-action@v1
+ with:
+ path: tests/test-results/
+
+ cli-e2e-tests:
+ name: CLI E2E Tests (proxy)
+ runs-on: depot-ubuntu-24.04-4
+ permissions:
+ contents: read
+ actions: write
+ id-token: write
+ steps:
+ - name: Checkout code
+ uses: actions/[email protected]
+
+ - name: Setup pnpm
+ uses: pnpm/action-setup@v6
+ with:
+ run_install: false
+
+ - name: Setup Node.js
+ uses: actions/setup-node@v6
+ with:
+ node-version: 26
+ cache: pnpm
+
+ - name: Setup Go
+ uses: actions/setup-go@v6
+ with:
+ go-version-file: cli/go.mod
+ cache-dependency-path: cli/go.sum
+
+ - name: Set up Depot CLI
+ uses: depot/setup-action@v1
+
+ - name: Setup depot buildx driver
+ run: depot configure-docker
+
+ - name: Install Playwright test dependencies
+ run: pnpm -C tests install
+
+ - name: Run CLI E2E tests against socket proxy
+ run: mkdir -p tests/test-results && pnpm -C tests exec playwright test --project=cli
+ env:
+ COMPOSE_FILE: setup/compose-proxy.yaml
+ BASE_URL: http://localhost:3002
+ PLAYWRIGHT_JUNIT_OUTPUT_FILE: test-results/playwright-cli.xml
+
+ - name: Upload Playwright HTML report
+ if: always()
+ uses: actions/upload-artifact@v7
+ with:
+ name: playwright-report-proxy-cli
+ path: tests/.report
+ include-hidden-files: true
+ retention-days: 15
+
+ - name: Report Playwright test results to Depot
+ if: ${{ !cancelled() }}
+ uses: depot/test-report-action@v1
+ with:
+ path: tests/test-results/
diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml
index dbe4b6150..d9252022a 100644
--- a/.github/workflows/ci.yml
+++ b/.github/workflows/ci.yml
@@ -4,8 +4,6 @@ env:
GOEXPERIMENT: jsonv2
on:
- push:
- branches: [main]
pull_request:
branches: [main, "release/**", "breaking/**"]
@@ -17,7 +15,7 @@ permissions:
id-token: write
concurrency:
- group: "${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}"
+ group: "${{ github.workflow }}-${{ github.event.pull_request.number }}"
cancel-in-progress: true
jobs: