Skip to content

Commit 2ddce97

Browse files
committed
[ci] Wrap all the build steps for the rbe build into one step
1 parent 46da039 commit 2ddce97

File tree

2 files changed

+20
-22
lines changed

2 files changed

+20
-22
lines changed

.github/workflows/ci-rbe.yml

Lines changed: 2 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -5,30 +5,10 @@ on:
55
workflow_dispatch:
66

77
jobs:
8-
set-ruby-version:
9-
name: Set Ruby version
10-
uses: ./.github/workflows/bazel.yml
11-
with:
12-
run: echo 'RUBY_VERSION = "jruby-9.4.2.0"' >rb/ruby_version.bzl
13-
14-
# The NPM repository rule wants to write to the HOME directory
15-
# but that's configured for the remote build machines, so run
16-
# that repository rule first so that the subsequent remote
17-
# build runs successfully.
18-
warm-cache:
19-
name: Warm repository rule cache
20-
uses: ./.github/workflows/bazel.yml
21-
needs: set-ruby-version
22-
with:
23-
name: Cache
24-
cache-key: rbe
25-
run: bazel query @npm//:all
26-
27-
rbe-tests:
8+
test:
289
name: Test
2910
uses: ./.github/workflows/bazel.yml
30-
needs: warm-cache
3111
with:
3212
name: Cache
3313
cache-key: rbe
34-
run: bazel test --config=remote --keep_going //java/...
14+
run: ./scripts/github-actions/ci-build.sh

scripts/github-actions/ci-build.sh

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
#!/usr/bin/env bash
2+
3+
set -eufo pipefail
4+
# We want to see what's going on
5+
set -x
6+
7+
# We want to use a pre-built Ruby version
8+
echo 'RUBY_VERSION = "jruby-9.4.2.0"' >rb/ruby_version.bzl
9+
10+
# The NPM repository rule wants to write to the HOME directory
11+
# but that's configured for the remote build machines, so run
12+
# that repository rule first so that the subsequent remote
13+
# build runs successfully.
14+
bazel query @npm//:all
15+
16+
# Now run the tests. The engflow build uses pinned browsers
17+
# so this should be fine
18+
bazel test --config=remote --keep_going //java/...

0 commit comments

Comments
 (0)