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

chore: migrate CI to public runner #2100

Merged
merged 1 commit into from
Mar 10, 2023
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
5 changes: 3 additions & 2 deletions .github/workflows/bundle-stats.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -12,14 +12,15 @@ permissions:
jobs:
bundle-stats:
name: Bundle stats compare
runs-on: [self-hosted, rspack-common, ARM64]
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v3
- name: Install protoc
uses: arduino/setup-protoc@v1
- uses: actions/setup-node@v3
with:
node-version: "16"
architecture: "arm64"
- name: Install dependencies && and build lib
run: |
node -e "console.log(process.arch)"
Expand Down
6 changes: 3 additions & 3 deletions .github/workflows/check-js.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -16,14 +16,14 @@ concurrency:
jobs:
test-js:
name: Node binding test
runs-on: [self-hosted, rspack-common]
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v3
# - name: Install protoc
# uses: arduino/setup-protoc@v1
with:
repo-token: ${{ secrets.GITHUB_TOKEN }}
- name: Install protoc
uses: arduino/setup-protoc@v1
- uses: actions/setup-node@v3
with:
node-version: "16"
Expand Down
24 changes: 8 additions & 16 deletions .github/workflows/check-rs.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -22,13 +22,13 @@ concurrency:
cancel-in-progress: true

env:
RUSTFLAGS: -D warnings
RUSTFLAGS: -D warnings
# TRACE: DEBUG

jobs:
format:
name: Format Rust Files
runs-on: [self-hosted, rspack-common]
runs-on: ubuntu-latest
steps:
# - name: Cleanup workspace
# uses: TooMuch4U/actions-clean@v2.1
Expand All @@ -53,21 +53,16 @@ jobs:

lint:
name: Lint Rust Files
runs-on: [self-hosted, rspack-common]
runs-on: ubuntu-latest
steps:
# - name: Cleanup workspace
# uses: TooMuch4U/actions-clean@v2.1
# if: ${{ always() }}
- name: Checkout repository
uses: actions/checkout@v3
# - name: Install protoc
# uses: arduino/setup-protoc@v1
with:
repo-token: ${{ secrets.GITHUB_TOKEN }}
- name: Install protoc
uses: arduino/setup-protoc@v1
- name: Install toolchain
run: rustup show
#- name: Cache
# uses: speedy-js/rust-cache-self-hosted@v1
- name: Run cargo check
run: cargo check --workspace --all-targets --release --locked

Expand All @@ -84,18 +79,15 @@ jobs:
name: Rust test
strategy:
fail-fast: true
runs-on: [self-hosted, rspack-common]
runs-on: ubuntu-latest
timeout-minutes: 30
steps:
# - name: Cleanup workspace
# uses: TooMuch4U/actions-clean@v2.1
# if: ${{ always() }}
- name: Checkout repository
uses: actions/checkout@v3
# - name: Install protoc
# uses: arduino/setup-protoc@v1
with:
repo-token: ${{ secrets.GITHUB_TOKEN }}
- name: Install protoc
uses: arduino/setup-protoc@v1
- uses: actions/setup-node@v3
with:
node-version: "16"
Expand Down
24 changes: 0 additions & 24 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -59,31 +59,7 @@ jobs:
REPOSITORY: ${{ github.repository }}
PULL_REQUEST_NUMBER: ${{ github.event.issue.number }}
COMMENT: ${{ toJson(github.event.comment) }}
artifact:
runs-on: ubuntu-latest
if: ${{ github.event_name == 'workflow_dispatch' }}
steps:
- name: Poor kids' remove old artifacts
uses: actions/github-script@v6
id: artifact
with:
script: |
const res = await github.rest.actions.listArtifactsForRepo({
owner: context.repo.owner,
repo: context.repo.repo,
})

res.data.artifacts
.forEach(({ id }) => {
github.rest.actions.deleteArtifact({
owner: context.repo.owner,
repo: context.repo.repo,
artifact_id: id,
})
})
build:
needs:
- artifact
strategy:
fail-fast: false
matrix:
Expand Down
23 changes: 0 additions & 23 deletions .github/workflows/test.yml.bak → .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,30 +16,7 @@ concurrency:
cancel-in-progress: true

jobs:
artifact:
runs-on: ubuntu-latest
steps:
- name: Poor kids' remove old artifacts
uses: actions/github-script@v6
id: artifact
with:
script: |
const res = await github.rest.actions.listArtifactsForRepo({
owner: context.repo.owner,
repo: context.repo.repo,
})

res.data.artifacts
.forEach(({ id }) => {
github.rest.actions.deleteArtifact({
owner: context.repo.owner,
repo: context.repo.repo,
artifact_id: id,
})
})
build:
needs:
- artifact
strategy:
fail-fast: false
matrix:
Expand Down