Skip to content

Commit f89e531

Browse files
authored
testing workflow (#38)
1 parent 4b97c3b commit f89e531

File tree

4 files changed

+87
-56
lines changed

4 files changed

+87
-56
lines changed

.github/prepare_ubuntu.sh

Lines changed: 0 additions & 7 deletions
This file was deleted.

.github/requirements.txt

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
snmpsim-data-lextudio
2+
snmpsim-lextudio

.github/workflows/build.yml

Lines changed: 85 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,85 @@
1+
name: Build check_interfaces
2+
3+
on:
4+
pull_request:
5+
branches: ["*"]
6+
7+
jobs:
8+
build:
9+
runs-on: ubuntu-latest
10+
env:
11+
CFLAGS: "-Wall"
12+
13+
steps:
14+
- uses: actions/checkout@v4
15+
16+
- uses: actions/setup-python@v5
17+
with:
18+
python-version: '3.x'
19+
cache: pip
20+
21+
- name: Install pip packages
22+
run: pip install -r .github/requirements.txt
23+
24+
- name: Install dependencies
25+
run: sudo apt-get update && sudo apt-get install -y libsnmp-dev
26+
27+
- name: Configure
28+
run: |
29+
autoreconf
30+
./configure
31+
32+
- name: Make
33+
run: make
34+
35+
- name: Start simmulation
36+
run: |
37+
setup-snmpsim-data /tmp/data
38+
snmpsim-command-responder --daemonize --pid-file /tmp/snmp --data-dir=/tmp/data/network/switch --agent-udpv4-endpoint=127.0.0.1:1611
39+
40+
- name: Sleep
41+
run: sleep 30s
42+
shell: bash
43+
44+
- name: check_interfaces
45+
run: ./check_interfaces -h 127.0.0.1 --port=1611 -c cisco-c3560 -d
46+
47+
clang-build:
48+
runs-on: ubuntu-latest
49+
env:
50+
CC: clang
51+
CFLAGS: "-Wall"
52+
53+
steps:
54+
- uses: actions/checkout@v4
55+
56+
- uses: actions/setup-python@v5
57+
with:
58+
python-version: '3.x'
59+
cache: pip
60+
61+
- name: Install pip packages
62+
run: pip install -r .github/requirements.txt
63+
64+
- name: Install dependencies
65+
run: sudo apt-get update && sudo apt-get install -y libsnmp-dev
66+
67+
- name: Configure
68+
run: |
69+
autoreconf
70+
./configure
71+
72+
- name: Make
73+
run: make
74+
75+
- name: Start simmulation
76+
run: |
77+
setup-snmpsim-data /tmp/data
78+
snmpsim-command-responder --daemonize --pid-file /tmp/snmp --data-dir=/tmp/data/network/switch --agent-udpv4-endpoint=127.0.0.1:1611
79+
80+
- name: Sleep
81+
run: sleep 30s
82+
shell: bash
83+
84+
- name: check_interfaces
85+
run: ./check_interfaces -h 127.0.0.1 --port=1611 -c cisco-c3560 -d

.github/workflows/makefile.yml

Lines changed: 0 additions & 49 deletions
This file was deleted.

0 commit comments

Comments
 (0)