-
Notifications
You must be signed in to change notification settings - Fork 32
60 lines (54 loc) · 1.57 KB
/
smartsim.yaml
File metadata and controls
60 lines (54 loc) · 1.57 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
name: smartsim
defaults:
run:
shell: bash -o pipefail -i {0}
on:
push:
branches:
- main
- 'smartsim*'
- 'static_client'
- 'releases/**'
pull_request:
types: [opened, reopened]
workflow_dispatch:
inputs:
debug_enabled:
type: boolean
description: 'Tmate debugging session'
required: false
default: false
jobs:
build:
runs-on: ubuntu-22.04
container:
image: ghcr.io/foamscience/openfoam-smartsim:cpu
options: --user openfoam
env:
CATCH_TIMEOUT: 20
FOAM_FOAMUT: "/tmp/foamUT"
SSDB: "redis:6379"
services:
redis:
image: redislabs/redisai
steps:
- name: Checkout repository
uses: actions/checkout@v3
- name: Setup tmate session
uses: mxschmitt/action-tmate@v3
if: ${{ github.event_name == 'workflow_dispatch' && inputs.debug_enabled }}
with:
detached: true
- name: Compile and Test
run: |
cd 2023-01/smartsim
source /usr/lib/openfoam/openfoam2212/etc/bashrc
mkdir -p $FOAM_USER_LIBBIN
./Allwmake
git clone https://github.com/FoamScience/foamUT $FOAM_FOAMUT
sed -i 's/mpirun/mpirun --oversubscribe/g' $FOAM_FOAMUT/Alltest
ln -s "$PWD"/smartsim_function_object/smartSimFunctionObject "$FOAM_FOAMUT"/smartSimFunctionObject
ln -s "$PWD"/smartsim_function_object/tests "$FOAM_FOAMUT"/tests/smartSimFOTests
cd $FOAM_FOAMUT || exit 1
rm -rf tests/exampleTests
./Alltest "$@"