|
|
|
@@ -120,7 +120,7 @@ jobs:
|
|
|
|
|
update-flake:
|
|
|
|
|
needs: changes
|
|
|
|
|
if: needs.changes.outputs.gomod == 'true'
|
|
|
|
|
runs-on: ${{ github.repository_owner == 'coder' && 'buildjet-8vcpu-ubuntu-2204' || 'ubuntu-latest' }}
|
|
|
|
|
runs-on: ${{ github.repository_owner == 'coder' && 'depot-ubuntu-22.04-8' || 'ubuntu-latest' }}
|
|
|
|
|
steps:
|
|
|
|
|
- name: Checkout
|
|
|
|
|
uses: actions/checkout@v4
|
|
|
|
@@ -139,7 +139,7 @@ jobs:
|
|
|
|
|
lint:
|
|
|
|
|
needs: changes
|
|
|
|
|
if: needs.changes.outputs.offlinedocs-only == 'false' || needs.changes.outputs.ci == 'true' || github.ref == 'refs/heads/main'
|
|
|
|
|
runs-on: ${{ github.repository_owner == 'coder' && 'buildjet-8vcpu-ubuntu-2204' || 'ubuntu-latest' }}
|
|
|
|
|
runs-on: ${{ github.repository_owner == 'coder' && 'depot-ubuntu-22.04-8' || 'ubuntu-latest' }}
|
|
|
|
|
steps:
|
|
|
|
|
- name: Checkout
|
|
|
|
|
uses: actions/checkout@v4
|
|
|
|
@@ -160,7 +160,7 @@ jobs:
|
|
|
|
|
echo "LINT_CACHE_DIR=$dir" >> $GITHUB_ENV
|
|
|
|
|
|
|
|
|
|
- name: golangci-lint cache
|
|
|
|
|
uses: buildjet/cache@v4
|
|
|
|
|
uses: actions/cache@v4
|
|
|
|
|
with:
|
|
|
|
|
path: |
|
|
|
|
|
${{ env.LINT_CACHE_DIR }}
|
|
|
|
@@ -193,7 +193,7 @@ jobs:
|
|
|
|
|
|
|
|
|
|
gen:
|
|
|
|
|
timeout-minutes: 8
|
|
|
|
|
runs-on: ${{ github.repository_owner == 'coder' && 'buildjet-8vcpu-ubuntu-2204' || 'ubuntu-latest' }}
|
|
|
|
|
runs-on: ${{ github.repository_owner == 'coder' && 'depot-ubuntu-22.04-8' || 'ubuntu-latest' }}
|
|
|
|
|
needs: changes
|
|
|
|
|
if: needs.changes.outputs.docs-only == 'false' || needs.changes.outputs.ci == 'true' || github.ref == 'refs/heads/main'
|
|
|
|
|
steps:
|
|
|
|
@@ -243,7 +243,7 @@ jobs:
|
|
|
|
|
fmt:
|
|
|
|
|
needs: changes
|
|
|
|
|
if: needs.changes.outputs.offlinedocs-only == 'false' || needs.changes.outputs.ci == 'true' || github.ref == 'refs/heads/main'
|
|
|
|
|
runs-on: ${{ github.repository_owner == 'coder' && 'buildjet-8vcpu-ubuntu-2204' || 'ubuntu-latest' }}
|
|
|
|
|
runs-on: ${{ github.repository_owner == 'coder' && 'depot-ubuntu-22.04-8' || 'ubuntu-latest' }}
|
|
|
|
|
timeout-minutes: 7
|
|
|
|
|
steps:
|
|
|
|
|
- name: Checkout
|
|
|
|
@@ -270,7 +270,7 @@ jobs:
|
|
|
|
|
run: ./scripts/check_unstaged.sh
|
|
|
|
|
|
|
|
|
|
test-go:
|
|
|
|
|
runs-on: ${{ matrix.os == 'ubuntu-latest' && github.repository_owner == 'coder' && 'buildjet-4vcpu-ubuntu-2204' || matrix.os == 'macos-latest' && github.repository_owner == 'coder' && 'macos-latest-xlarge' || matrix.os == 'windows-2022' && github.repository_owner == 'coder' && 'windows-latest-16-cores' || matrix.os }}
|
|
|
|
|
runs-on: ${{ matrix.os == 'ubuntu-latest' && github.repository_owner == 'coder' && 'depot-ubuntu-22.04-4' || matrix.os == 'macos-latest' && github.repository_owner == 'coder' && 'macos-latest-xlarge' || matrix.os == 'windows-2022' && github.repository_owner == 'coder' && 'windows-latest-16-cores' || matrix.os }}
|
|
|
|
|
needs: changes
|
|
|
|
|
if: needs.changes.outputs.go == 'true' || needs.changes.outputs.ci == 'true' || github.ref == 'refs/heads/main'
|
|
|
|
|
timeout-minutes: 20
|
|
|
|
@@ -326,7 +326,7 @@ jobs:
|
|
|
|
|
api-key: ${{ secrets.DATADOG_API_KEY }}
|
|
|
|
|
|
|
|
|
|
test-go-pg:
|
|
|
|
|
runs-on: ${{ github.repository_owner == 'coder' && 'buildjet-8vcpu-ubuntu-2204' || 'ubuntu-latest' }}
|
|
|
|
|
runs-on: ${{ github.repository_owner == 'coder' && 'depot-ubuntu-22.04-8' || 'ubuntu-latest' }}
|
|
|
|
|
needs:
|
|
|
|
|
- changes
|
|
|
|
|
if: needs.changes.outputs.go == 'true' || needs.changes.outputs.ci == 'true' || github.ref == 'refs/heads/main'
|
|
|
|
@@ -361,7 +361,7 @@ jobs:
|
|
|
|
|
api-key: ${{ secrets.DATADOG_API_KEY }}
|
|
|
|
|
|
|
|
|
|
test-go-race:
|
|
|
|
|
runs-on: ${{ github.repository_owner == 'coder' && 'buildjet-8vcpu-ubuntu-2204' || 'ubuntu-latest' }}
|
|
|
|
|
runs-on: ${{ github.repository_owner == 'coder' && 'depot-ubuntu-22.04-8' || 'ubuntu-latest' }}
|
|
|
|
|
needs: changes
|
|
|
|
|
if: needs.changes.outputs.go == 'true' || needs.changes.outputs.ci == 'true' || github.ref == 'refs/heads/main'
|
|
|
|
|
timeout-minutes: 25
|
|
|
|
@@ -396,7 +396,7 @@ jobs:
|
|
|
|
|
# These tests are skipped in the main go test jobs because they require root
|
|
|
|
|
# and mess with networking.
|
|
|
|
|
test-go-tailnet-integration:
|
|
|
|
|
runs-on: ${{ github.repository_owner == 'coder' && 'buildjet-8vcpu-ubuntu-2204' || 'ubuntu-latest' }}
|
|
|
|
|
runs-on: ${{ github.repository_owner == 'coder' && 'depot-ubuntu-22.04-8' || 'ubuntu-latest' }}
|
|
|
|
|
needs: changes
|
|
|
|
|
# Unnecessary to run on main for now
|
|
|
|
|
if: needs.changes.outputs.tailnet-integration == 'true' || needs.changes.outputs.ci == 'true'
|
|
|
|
@@ -418,7 +418,7 @@ jobs:
|
|
|
|
|
run: make test-tailnet-integration
|
|
|
|
|
|
|
|
|
|
test-js:
|
|
|
|
|
runs-on: ${{ github.repository_owner == 'coder' && 'buildjet-8vcpu-ubuntu-2204' || 'ubuntu-latest' }}
|
|
|
|
|
runs-on: ${{ github.repository_owner == 'coder' && 'depot-ubuntu-22.04-8' || 'ubuntu-latest' }}
|
|
|
|
|
needs: changes
|
|
|
|
|
if: needs.changes.outputs.ts == 'true' || needs.changes.outputs.ci == 'true' || github.ref == 'refs/heads/main'
|
|
|
|
|
timeout-minutes: 20
|
|
|
|
@@ -435,7 +435,7 @@ jobs:
|
|
|
|
|
working-directory: site
|
|
|
|
|
|
|
|
|
|
test-e2e:
|
|
|
|
|
runs-on: ${{ github.repository_owner == 'coder' && 'buildjet-16vcpu-ubuntu-2204' || 'ubuntu-latest' }}
|
|
|
|
|
runs-on: ${{ github.repository_owner == 'coder' && 'depot-ubuntu-22.04-16' || 'ubuntu-latest' }}
|
|
|
|
|
needs: changes
|
|
|
|
|
if: needs.changes.outputs.go == 'true' || needs.changes.outputs.ts == 'true' || needs.changes.outputs.ci == 'true' || github.ref == 'refs/heads/main'
|
|
|
|
|
timeout-minutes: 20
|
|
|
|
@@ -579,7 +579,7 @@ jobs:
|
|
|
|
|
offlinedocs:
|
|
|
|
|
name: offlinedocs
|
|
|
|
|
needs: changes
|
|
|
|
|
runs-on: ${{ github.repository_owner == 'coder' && 'buildjet-8vcpu-ubuntu-2204' || 'ubuntu-latest' }}
|
|
|
|
|
runs-on: ${{ github.repository_owner == 'coder' && 'depot-ubuntu-22.04-8' || 'ubuntu-latest' }}
|
|
|
|
|
if: needs.changes.outputs.offlinedocs == 'true' || needs.changes.outputs.ci == 'true' || needs.changes.outputs.docs == 'true'
|
|
|
|
|
|
|
|
|
|
steps:
|
|
|
|
@@ -677,11 +677,10 @@ jobs:
|
|
|
|
|
|
|
|
|
|
build:
|
|
|
|
|
# This builds and publishes ghcr.io/coder/coder-preview:main for each commit
|
|
|
|
|
# to main branch. We are only building this for amd64 platform. (>95% pulls
|
|
|
|
|
# are for amd64)
|
|
|
|
|
# to main branch.
|
|
|
|
|
needs: changes
|
|
|
|
|
if: github.ref == 'refs/heads/main' && needs.changes.outputs.docs-only == 'false' && !github.event.pull_request.head.repo.fork
|
|
|
|
|
runs-on: ${{ github.repository_owner == 'coder' && 'buildjet-8vcpu-ubuntu-2204' || 'ubuntu-latest' }}
|
|
|
|
|
runs-on: ${{ github.repository_owner == 'coder' && 'depot-ubuntu-22.04-8' || 'ubuntu-latest' }}
|
|
|
|
|
env:
|
|
|
|
|
DOCKER_CLI_EXPERIMENTAL: "enabled"
|
|
|
|
|
outputs:
|
|
|
|
@@ -887,7 +886,7 @@ jobs:
|
|
|
|
|
# runs sqlc-vet to ensure all queries are valid. This catches any mistakes
|
|
|
|
|
# in migrations or sqlc queries that makes a query unable to be prepared.
|
|
|
|
|
sqlc-vet:
|
|
|
|
|
runs-on: ${{ github.repository_owner == 'coder' && 'buildjet-8vcpu-ubuntu-2204' || 'ubuntu-latest' }}
|
|
|
|
|
runs-on: ${{ github.repository_owner == 'coder' && 'depot-ubuntu-22.04-8' || 'ubuntu-latest' }}
|
|
|
|
|
needs: changes
|
|
|
|
|
if: needs.changes.outputs.db == 'true' || needs.changes.outputs.ci == 'true' || github.ref == 'refs/heads/main'
|
|
|
|
|
steps:
|
|
|
|
|