Skip to content

Commit c97851c

Browse files
CI: Use Linux-based job for building and deploying dev dashboard
The macOS job runs tests with the `--sanitize address`, which slows down the test execution, so we couldn't deploy the result quickly.
1 parent 06ef6ac commit c97851c

File tree

1 file changed

+23
-22
lines changed

1 file changed

+23
-22
lines changed

.github/workflows/main.yml

Lines changed: 23 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -27,8 +27,7 @@ jobs:
2727
development-toolchain-tag: swift-DEVELOPMENT-SNAPSHOT-2024-07-08-a
2828
wasi-swift-sdk-download: "https://github.com/swiftwasm/swift/releases/download/swift-wasm-DEVELOPMENT-SNAPSHOT-2024-07-09-a/swift-wasm-DEVELOPMENT-SNAPSHOT-2024-07-09-a-wasm32-unknown-wasi.artifactbundle.zip"
2929
wasi-swift-sdk-id: DEVELOPMENT-SNAPSHOT-2024-07-09-a-wasm32-unknown-wasi
30-
test-args: "--sanitize address --enable-code-coverage"
31-
build-dev-dashboard: true
30+
test-args: "--sanitize address"
3231

3332
runs-on: ${{ matrix.os }}
3433
name: "build-macos (${{ matrix.xcode }})"
@@ -61,25 +60,6 @@ jobs:
6160
- run: ./Vendor/checkout-dependency
6261
- run: swift test ${{ matrix.test-args }}
6362

64-
- if: matrix.build-dev-dashboard
65-
run: ./CI/build-dev-dashboard.sh
66-
- if: matrix.build-dev-dashboard
67-
id: deployment
68-
uses: actions/upload-pages-artifact@v3
69-
with:
70-
path: .build/html
71-
72-
deploy-dev-dashboard:
73-
environment:
74-
name: github-pages
75-
url: ${{ steps.deployment.outputs.page_url }}
76-
runs-on: ubuntu-latest
77-
if: ${{ github.event_name == 'push' && github.ref == 'refs/heads/main' }}
78-
needs: build-macos
79-
steps:
80-
- id: deployment
81-
uses: actions/deploy-pages@v4
82-
8363
build-xcode:
8464
runs-on: macos-15
8565
steps:
@@ -106,6 +86,8 @@ jobs:
10686
development-toolchain-download: "https://download.swift.org/development/ubuntu2004/swift-DEVELOPMENT-SNAPSHOT-2024-07-08-a/swift-DEVELOPMENT-SNAPSHOT-2024-07-08-a-ubuntu20.04.tar.gz"
10787
wasi-swift-sdk-download: "https://github.com/swiftwasm/swift/releases/download/swift-wasm-DEVELOPMENT-SNAPSHOT-2024-07-09-a/swift-wasm-DEVELOPMENT-SNAPSHOT-2024-07-09-a-wasm32-unknown-wasi.artifactbundle.zip"
10888
wasi-swift-sdk-id: DEVELOPMENT-SNAPSHOT-2024-07-09-a-wasm32-unknown-wasi
89+
test-args: "--enable-code-coverage"
90+
build-dev-dashboard: true
10991
- swift: "5.9-amazonlinux2"
11092
development-toolchain-download: "https://download.swift.org/development/amazonlinux2/swift-DEVELOPMENT-SNAPSHOT-2024-07-08-a/swift-DEVELOPMENT-SNAPSHOT-2024-07-08-a-amazonlinux2.tar.gz"
11193
wasi-swift-sdk-download: "https://github.com/swiftwasm/swift/releases/download/swift-wasm-DEVELOPMENT-SNAPSHOT-2024-07-09-a/swift-wasm-DEVELOPMENT-SNAPSHOT-2024-07-09-a-wasm32-unknown-wasi.artifactbundle.zip"
@@ -144,7 +126,26 @@ jobs:
144126
EOS
145127
- run: ./build-exec ./CI/install-wabt.sh
146128
- run: ./Vendor/checkout-dependency
147-
- run: ./build-exec swift test
129+
- run: ./build-exec swift test ${{ matrix.test-args }}
130+
131+
- if: matrix.build-dev-dashboard
132+
run: ./build-exec ./CI/build-dev-dashboard.sh
133+
- if: matrix.build-dev-dashboard
134+
id: deployment
135+
uses: actions/upload-pages-artifact@v3
136+
with:
137+
path: .build/html
138+
139+
deploy-dev-dashboard:
140+
environment:
141+
name: github-pages
142+
url: ${{ steps.deployment.outputs.page_url }}
143+
runs-on: ubuntu-latest
144+
if: ${{ github.event_name == 'push' && github.ref == 'refs/heads/main' }}
145+
needs: build-linux
146+
steps:
147+
- id: deployment
148+
uses: actions/deploy-pages@v4
148149

149150
build-musl:
150151
runs-on: ubuntu-22.04

0 commit comments

Comments
 (0)