-
Notifications
You must be signed in to change notification settings - Fork 103
53 lines (51 loc) · 1.85 KB
/
valgrind.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
on:
workflow_call
jobs:
valgrind_tests:
runs-on: ubuntu-22.04
steps:
- name: Checkout
uses: actions/checkout@v4
with:
path: masterfiles
- name: Get Togethers
uses: cfengine/together-javascript-action@main
id: together
with:
myToken: ${{ secrets.GITHUB_TOKEN }}
- name: Checkout Core
uses: actions/checkout@v4
with:
repository: cfengine/core
path: core
ref: ${{steps.together.outputs.core || github.base_ref || github.ref}}
submodules: recursive
- name: Install dependencies
run: sudo apt-get update -y && sudo apt-get install -y libssl-dev libpam0g-dev liblmdb-dev byacc curl libyaml-dev valgrind
# - name: Install CFEngine with cf-remote
# run: |
# pip3 install cf-remote
# cf-remote --version master install --clients localhost
- name: build and install CFEngine core
run: |
./autogen.sh --enable-debug --with-systemd-service
make -j8 CFLAGS="-Werror -Wall"
sudo make install
working-directory: core
- name: Run autotools / configure
run: |
cd masterfiles
./autogen.sh --enable-debug
cd ..
- name: Install Masterfiles
run: sudo make -C masterfiles install
- name: Validate policy with cf-promises
run: |
INSTDIR=/var/cfengine
export INSTDIR
/var/cfengine/bin/cf-promises --version
/var/cfengine/bin/cf-promises -c -I -f $INSTDIR/masterfiles/update.cf
/var/cfengine/bin/cf-promises -c -I -f $INSTDIR/masterfiles/promises.cf
/var/cfengine/bin/cf-promises -c -I -f $INSTDIR/masterfiles/standalone_self_upgrade.cf
- name: Run valgrind.sh
run: sudo bash -x masterfiles/.github/workflows/valgrind.sh