forked from DUNE-DAQ/detdataformats
-
Notifications
You must be signed in to change notification settings - Fork 0
93 lines (81 loc) · 2.85 KB
/
dunedaq-develop-cpp-ci.yml
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
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
name: build-develop
# Controls when the action will run. Workflow runs when manually triggered using the UI
# or API.
on:
push:
branches:
- develop
- patch/*
paths-ignore:
- 'docs/**'
- '.github/**'
pull_request:
branches: [ develop ]
schedule:
- cron: "0 7 * * *"
workflow_dispatch:
jobs:
Build_against_dev_release:
name: build_against_dev_on_${{ matrix.os_name }}
# The type of runner that the job will run on
runs-on: ubuntu-latest
strategy:
matrix:
include:
- image: "dunedaq/sl7-minimal:dev"
os_name: "c7"
link: "last_successful"
- image: "dunedaq/c8-minimal:dev"
os_name: "c8"
link: "last_successful_cs8"
container:
image: ${{ matrix.image }}
defaults:
run:
shell: bash
env:
DBT_AREA_FILE: "dbt-settings"
# Steps represent a sequence of tasks that will be executed as part of the job
steps:
# Runs a single command using the runners shell
- name: Checkout daq-release
uses: actions/checkout@v3
with:
repository: DUNE-DAQ/daq-release
path: daq-release
- name: setup dev area
run: |
source /cvmfs/dunedaq.opensciencegrid.org/setup_dunedaq.sh
setup_dbt latest || true
dbt-create.py -c -n ${{ matrix.link }} dev-${{ matrix.os_name }}
- name: checkout package for CI
uses: actions/checkout@v3
with:
path: ${{ github.repository }}
- name: setup build env, build and lint the repo against the development release
run: |
export REPO=$(echo '${{ github.repository }}' | awk -F '/' '{print $2}')
cd $GITHUB_WORKSPACE/dev-${{ matrix.os_name }}
source dbt-env.sh
dbt-workarea-env || true
setup_repo_env="SETUP_$REPO"
[[ -z ${!setup_env_repo+x} ]] || unsetup $REPO
cp -pr $GITHUB_WORKSPACE/DUNE-DAQ/$REPO $GITHUB_WORKSPACE/dev-${{ matrix.os_name }}/sourcecode
dbt-build.py
dbt-build.py --lint
$GITHUB_WORKSPACE/daq-release/scripts/upsify-daq-pkgs.py -w $GITHUB_WORKSPACE/dev-${{ matrix.os_name }} -c ${{ matrix.os_name }} -o /tarballs-${{ matrix.os_name }}
- name: upload UPS tarball and log file
uses: actions/upload-artifact@v2
with:
name: ups_package_${{ matrix.os_name }}
path: /tarballs-${{ matrix.os_name }}
- name: upload build log file
uses: actions/upload-artifact@v2
with:
name: build_log_${{ matrix.os_name }}
path: ${{ github.workspace }}/dev-${{ matrix.os_name }}/log/build*.log
- name: upload linter output file
uses: actions/upload-artifact@v2
with:
name: linting_log_${{ matrix.os_name }}
path: ${{ github.workspace }}/dev-${{ matrix.os_name }}/log/linting*.log