Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[FH-550] prevent pushes from non-default branch #184

Merged
merged 6 commits into from
Jan 30, 2025
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/action.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
name: TypeScript-based Action

on:
merge_group:
pull_request:
push:
branches: [main]
Expand All @@ -15,7 +16,7 @@
steps:
- uses: actions/checkout@v4
- uses: DeterminateSystems/nix-installer-action@main
- uses: DeterminateSystems/magic-nix-cache-action@main

Check warning on line 19 in .github/workflows/action.yml

View workflow job for this annotation

GitHub Actions / build-artifacts-X64-Linux

Magic Nix Cache is deprecated

Magic Nix Cache has been deprecated due to a change in the underlying GitHub APIs and will stop working on 1 February 2025. To continue caching Nix builds in GitHub Actions, use FlakeHub Cache instead. Replace... - uses: DeterminateSystems/magic-nix-cache-action@main ...with... - uses: DeterminateSystems/flakehub-cache-action@main For more details: https://dtr.mn/magic-nix-cache-eol

Check warning on line 19 in .github/workflows/action.yml

View workflow job for this annotation

GitHub Actions / Check the dist/ folder is up to date

Magic Nix Cache is deprecated

Magic Nix Cache has been deprecated due to a change in the underlying GitHub APIs and will stop working on 1 February 2025. To continue caching Nix builds in GitHub Actions, use FlakeHub Cache instead. Replace... - uses: DeterminateSystems/magic-nix-cache-action@main ...with... - uses: DeterminateSystems/flakehub-cache-action@main For more details: https://dtr.mn/magic-nix-cache-eol

Check warning on line 19 in .github/workflows/action.yml

View workflow job for this annotation

GitHub Actions / build-artifacts-macos (aarch64-darwin, macos-latest-xlarge)

Magic Nix Cache is deprecated

Magic Nix Cache has been deprecated due to a change in the underlying GitHub APIs and will stop working on 1 February 2025. To continue caching Nix builds in GitHub Actions, use FlakeHub Cache instead. Replace... - uses: DeterminateSystems/magic-nix-cache-action@main ...with... - uses: DeterminateSystems/flakehub-cache-action@main For more details: https://dtr.mn/magic-nix-cache-eol

Check warning on line 19 in .github/workflows/action.yml

View workflow job for this annotation

GitHub Actions / build-artifacts-macos (x86_64-darwin, macos-13-large)

Magic Nix Cache is deprecated

Magic Nix Cache has been deprecated due to a change in the underlying GitHub APIs and will stop working on 1 February 2025. To continue caching Nix builds in GitHub Actions, use FlakeHub Cache instead. Replace... - uses: DeterminateSystems/magic-nix-cache-action@main ...with... - uses: DeterminateSystems/flakehub-cache-action@main For more details: https://dtr.mn/magic-nix-cache-eol
with:
use-gha-cache: false
- name: Install pnpm dependencies
Expand Down
1 change: 1 addition & 0 deletions .github/workflows/build.yaml
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
name: Build artifacts

on:
merge_group:
workflow_dispatch:
workflow_call:
pull_request:
Expand All @@ -20,7 +21,7 @@

- uses: DeterminateSystems/nix-installer-action@main

- uses: DeterminateSystems/magic-nix-cache-action@main

Check warning on line 24 in .github/workflows/build.yaml

View workflow job for this annotation

GitHub Actions / build-artifacts-X64-Linux

Magic Nix Cache is deprecated

Magic Nix Cache has been deprecated due to a change in the underlying GitHub APIs and will stop working on 1 February 2025. To continue caching Nix builds in GitHub Actions, use FlakeHub Cache instead. Replace... - uses: DeterminateSystems/magic-nix-cache-action@main ...with... - uses: DeterminateSystems/flakehub-cache-action@main For more details: https://dtr.mn/magic-nix-cache-eol

Check warning on line 24 in .github/workflows/build.yaml

View workflow job for this annotation

GitHub Actions / Check the dist/ folder is up to date

Magic Nix Cache is deprecated

Magic Nix Cache has been deprecated due to a change in the underlying GitHub APIs and will stop working on 1 February 2025. To continue caching Nix builds in GitHub Actions, use FlakeHub Cache instead. Replace... - uses: DeterminateSystems/magic-nix-cache-action@main ...with... - uses: DeterminateSystems/flakehub-cache-action@main For more details: https://dtr.mn/magic-nix-cache-eol

Check warning on line 24 in .github/workflows/build.yaml

View workflow job for this annotation

GitHub Actions / build-artifacts-macos (aarch64-darwin, macos-latest-xlarge)

Magic Nix Cache is deprecated

Magic Nix Cache has been deprecated due to a change in the underlying GitHub APIs and will stop working on 1 February 2025. To continue caching Nix builds in GitHub Actions, use FlakeHub Cache instead. Replace... - uses: DeterminateSystems/magic-nix-cache-action@main ...with... - uses: DeterminateSystems/flakehub-cache-action@main For more details: https://dtr.mn/magic-nix-cache-eol

Check warning on line 24 in .github/workflows/build.yaml

View workflow job for this annotation

GitHub Actions / build-artifacts-macos (x86_64-darwin, macos-13-large)

Magic Nix Cache is deprecated

Magic Nix Cache has been deprecated due to a change in the underlying GitHub APIs and will stop working on 1 February 2025. To continue caching Nix builds in GitHub Actions, use FlakeHub Cache instead. Replace... - uses: DeterminateSystems/magic-nix-cache-action@main ...with... - uses: DeterminateSystems/flakehub-cache-action@main For more details: https://dtr.mn/magic-nix-cache-eol
with:
use-gha-cache: false

Expand Down Expand Up @@ -65,7 +66,7 @@

- uses: DeterminateSystems/nix-installer-action@main

- uses: DeterminateSystems/magic-nix-cache-action@main

Check warning on line 69 in .github/workflows/build.yaml

View workflow job for this annotation

GitHub Actions / build-artifacts-X64-Linux

Magic Nix Cache is deprecated

Magic Nix Cache has been deprecated due to a change in the underlying GitHub APIs and will stop working on 1 February 2025. To continue caching Nix builds in GitHub Actions, use FlakeHub Cache instead. Replace... - uses: DeterminateSystems/magic-nix-cache-action@main ...with... - uses: DeterminateSystems/flakehub-cache-action@main For more details: https://dtr.mn/magic-nix-cache-eol

Check warning on line 69 in .github/workflows/build.yaml

View workflow job for this annotation

GitHub Actions / Check the dist/ folder is up to date

Magic Nix Cache is deprecated

Magic Nix Cache has been deprecated due to a change in the underlying GitHub APIs and will stop working on 1 February 2025. To continue caching Nix builds in GitHub Actions, use FlakeHub Cache instead. Replace... - uses: DeterminateSystems/magic-nix-cache-action@main ...with... - uses: DeterminateSystems/flakehub-cache-action@main For more details: https://dtr.mn/magic-nix-cache-eol

Check warning on line 69 in .github/workflows/build.yaml

View workflow job for this annotation

GitHub Actions / build-artifacts-macos (aarch64-darwin, macos-latest-xlarge)

Magic Nix Cache is deprecated

Magic Nix Cache has been deprecated due to a change in the underlying GitHub APIs and will stop working on 1 February 2025. To continue caching Nix builds in GitHub Actions, use FlakeHub Cache instead. Replace... - uses: DeterminateSystems/magic-nix-cache-action@main ...with... - uses: DeterminateSystems/flakehub-cache-action@main For more details: https://dtr.mn/magic-nix-cache-eol

Check warning on line 69 in .github/workflows/build.yaml

View workflow job for this annotation

GitHub Actions / build-artifacts-macos (x86_64-darwin, macos-13-large)

Magic Nix Cache is deprecated

Magic Nix Cache has been deprecated due to a change in the underlying GitHub APIs and will stop working on 1 February 2025. To continue caching Nix builds in GitHub Actions, use FlakeHub Cache instead. Replace... - uses: DeterminateSystems/magic-nix-cache-action@main ...with... - uses: DeterminateSystems/flakehub-cache-action@main For more details: https://dtr.mn/magic-nix-cache-eol
with:
use-gha-cache: false

Expand Down
16 changes: 1 addition & 15 deletions .github/workflows/production-test.yml
Original file line number Diff line number Diff line change
@@ -1,27 +1,16 @@
name: Production test

on:
pull_request:
types:
- opened
- reopened
- synchronize
- labeled
merge_group:

jobs:
build:
uses: ./.github/workflows/build.yaml
if: |
(github.event.action == 'labeled' && github.event.label.name == 'production test')
|| (github.event.action != 'labeled' && contains(github.event.pull_request.labels.*.name, 'production test'))

production-test:
needs: build
runs-on: UbuntuLatest32Cores128G
timeout-minutes: 5
if: |
(github.event.action == 'labeled' && github.event.label.name == 'production test')
|| (github.event.action != 'labeled' && contains(github.event.pull_request.labels.*.name, 'production test'))
permissions:
id-token: write # In order to request a JWT for AWS auth
contents: read # Specifying id-token wiped this out, so manually specify that this action is allowed to checkout this private repo
Expand All @@ -30,7 +19,7 @@

- uses: DeterminateSystems/nix-installer-action@main

- uses: DeterminateSystems/magic-nix-cache-action@main

Check warning on line 22 in .github/workflows/production-test.yml

View workflow job for this annotation

GitHub Actions / build-artifacts-X64-Linux

Magic Nix Cache is deprecated

Magic Nix Cache has been deprecated due to a change in the underlying GitHub APIs and will stop working on 1 February 2025. To continue caching Nix builds in GitHub Actions, use FlakeHub Cache instead. Replace... - uses: DeterminateSystems/magic-nix-cache-action@main ...with... - uses: DeterminateSystems/flakehub-cache-action@main For more details: https://dtr.mn/magic-nix-cache-eol

Check warning on line 22 in .github/workflows/production-test.yml

View workflow job for this annotation

GitHub Actions / Check the dist/ folder is up to date

Magic Nix Cache is deprecated

Magic Nix Cache has been deprecated due to a change in the underlying GitHub APIs and will stop working on 1 February 2025. To continue caching Nix builds in GitHub Actions, use FlakeHub Cache instead. Replace... - uses: DeterminateSystems/magic-nix-cache-action@main ...with... - uses: DeterminateSystems/flakehub-cache-action@main For more details: https://dtr.mn/magic-nix-cache-eol

Check warning on line 22 in .github/workflows/production-test.yml

View workflow job for this annotation

GitHub Actions / build-artifacts-macos (aarch64-darwin, macos-latest-xlarge)

Magic Nix Cache is deprecated

Magic Nix Cache has been deprecated due to a change in the underlying GitHub APIs and will stop working on 1 February 2025. To continue caching Nix builds in GitHub Actions, use FlakeHub Cache instead. Replace... - uses: DeterminateSystems/magic-nix-cache-action@main ...with... - uses: DeterminateSystems/flakehub-cache-action@main For more details: https://dtr.mn/magic-nix-cache-eol

Check warning on line 22 in .github/workflows/production-test.yml

View workflow job for this annotation

GitHub Actions / build-artifacts-macos (x86_64-darwin, macos-13-large)

Magic Nix Cache is deprecated

Magic Nix Cache has been deprecated due to a change in the underlying GitHub APIs and will stop working on 1 February 2025. To continue caching Nix builds in GitHub Actions, use FlakeHub Cache instead. Replace... - uses: DeterminateSystems/magic-nix-cache-action@main ...with... - uses: DeterminateSystems/flakehub-cache-action@main For more details: https://dtr.mn/magic-nix-cache-eol
with:
use-gha-cache: false

Expand All @@ -40,9 +29,6 @@
path: flakehub-push-X64-Linux

- name: Production test
if: |
(github.event.action == 'labeled' && github.event.label.name == 'production test')
|| (github.event.action != 'labeled' && contains(github.event.pull_request.labels.*.name, 'production test'))
uses: ./
with:
visibility: "hidden"
Expand Down
1 change: 1 addition & 0 deletions .github/workflows/release-prs.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
name: Release PR

on:
merge_group:
pull_request:
types:
- opened
Expand Down
Loading
Loading