Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .github/workflows/docs-api-check.yml
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,7 @@ concurrency:
jobs:
generated-up-to-date:
name: API Reference / Generated Pages Up To Date
if: github.repository == 'rivet-dev/rivet'
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
Expand Down
1 change: 1 addition & 0 deletions .github/workflows/docs-sync-api.yml
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@ on:

jobs:
sync:
if: github.repository == 'rivet-dev/rivet'
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
Expand Down
17 changes: 14 additions & 3 deletions .github/workflows/publish.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -84,6 +84,15 @@ jobs:
build_wasm: ${{ steps.ctx.outputs.build_wasm }}
build_docker: ${{ steps.ctx.outputs.build_docker }}
steps:
# Every build and publish job needs this one, so failing here stops the
# whole run before anything is built or uploaded. 654560183 is the
# immutable ID of rivet-dev/rivet, so a copy of this workflow in any other
# repository never publishes.
- name: Refuse to publish outside the OSS repository
if: github.repository_id != '654560183'
run: |
echo "::error::publish.yaml only publishes from rivet-dev/rivet (repository ID 654560183), not ${{ github.repository }}."
exit 1
- uses: actions/checkout@v4
with:
fetch-depth: 1
Expand Down Expand Up @@ -338,7 +347,8 @@ jobs:
# ---------------------------------------------------------------------------
docker-images:
needs: [context]
if: needs.context.outputs.build_docker == 'true'
# This ID identifies the OSS repository and remains stable across renames.
if: needs.context.outputs.build_docker == 'true' && github.repository_id == '654560183'
name: "Docker ${{ matrix.arch_suffix }}"
strategy:
fail-fast: false
Expand Down Expand Up @@ -429,6 +439,7 @@ jobs:
cache: pnpm
- run: pnpm install --frozen-lockfile
- uses: ./.github/actions/docker-setup
if: github.repository_id == '654560183'
with:
docker_username: ${{ secrets.DOCKER_CI_USERNAME }}
docker_password: ${{ secrets.DOCKER_CI_ACCESS_TOKEN }}
Expand Down Expand Up @@ -673,7 +684,7 @@ jobs:
--allow-dirty

- name: Create Docker multi-arch manifests
if: needs.context.outputs.build_docker == 'true'
if: needs.context.outputs.build_docker == 'true' && github.repository_id == '654560183'
run: pnpm --filter=publish exec tsx src/ci/bin.ts docker-manifest --sha ${{ needs.context.outputs.sha }}

# ---- release-only tail ----
Expand All @@ -690,7 +701,7 @@ jobs:


- name: Retag Docker manifests to version
if: needs.context.outputs.trigger == 'release'
if: needs.context.outputs.trigger == 'release' && github.repository_id == '654560183'
run: |
pnpm --filter=publish exec tsx src/ci/bin.ts docker-retag \
--sha ${{ needs.context.outputs.sha }} \
Expand Down
Loading