forked from GoogleContainerTools/distroless
-
Notifications
You must be signed in to change notification settings - Fork 1
28 lines (25 loc) · 802 Bytes
/
ci.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
name: CI
on:
workflow_dispatch: # Allow manual runs.
pull_request:
branches: [ 'main' ]
push:
branches: [ 'main' ]
jobs:
ci:
name: CI
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: bazelbuild/setup-bazelisk@v2
- name: Build and test
run: |
set -ex
for i in $(seq 5); do bazel fetch --loading_phase_threads=1 //... && break || sleep 20; done
bazel build --curses=no //...
bazel test --curses=no --test_output=errors //...
# Ignore experimental targets, which might not pass.
# TODO: Fix or remove these exceptions.
targets=$(bazel query 'attr("tags", "'amd64'", "//...")')
bazel build --curses=no ${targets}
bazel test --curses=no --test_output=errors ${targets}