Repository navigation
64 lines (52 loc) · 1.73 KB
/
Copy pathci.yml
File metadata and controls
64 lines (52 loc) · 1.73 KB
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
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
name: CI
on:
push:
branches: [master]
pull_request:
branches: [master]
jobs:
test-args:
runs-on: [self-hosted, Linux, platform-builder-docker]
container:
image: eccr.ecmwf.int/ci-utils/ubuntu_rolling_fdb_build_env
credentials:
username: ${{ secrets.ECMWF_DOCKER_REGISTRY_USERNAME }}
password: ${{ secrets.ECMWF_DOCKER_REGISTRY_ACCESS_TOKEN }}
steps:
- name: Checkout
uses: actions/checkout@v4
- name: CLI argument tests
run: bash test_build_args.sh
build:
runs-on: [self-hosted, Linux, platform-builder-docker]
container:
image: eccr.ecmwf.int/ci-utils/ubuntu_rolling_fdb_build_env
credentials:
username: ${{ secrets.ECMWF_DOCKER_REGISTRY_USERNAME }}
password: ${{ secrets.ECMWF_DOCKER_REGISTRY_ACCESS_TOKEN }}
strategy:
fail-fast: false
matrix:
mode: [shell, cmake, bundle]
name: build (${{ matrix.mode }})
steps:
- name: Checkout
uses: actions/checkout@v4
with:
submodules: recursive
- name: Build (shell)
if: matrix.mode == 'shell'
run: ./build.sh --verbose --install-path /tmp/install --build-path /tmp/build
- name: Build (cmake)
if: matrix.mode == 'cmake'
run: cmake -S . -B /tmp/build
- name: Setup bundle directory
if: matrix.mode == 'bundle'
run: |
mkdir -p /tmp/bundle
git clone --depth 1 https://github.com/ecmwf/ecbuild.git /tmp/bundle/ecbuild
ln -s "$GITHUB_WORKSPACE" /tmp/bundle/stack-dependencies
cp test/bundle/CMakeLists.txt /tmp/bundle/
- name: Build (bundle)
if: matrix.mode == 'bundle'
run: cmake -S /tmp/bundle -B /tmp/build