forked from sogou/workflow
-
Notifications
You must be signed in to change notification settings - Fork 0
57 lines (52 loc) · 1.42 KB
/
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
name: ci build
on:
push:
branches: [ master ]
pull_request:
branches: [ master ]
jobs:
build:
name: ubuntu
runs-on: ubuntu-latest
steps:
- name: setup
run: |
sudo apt-get update
sudo apt-get install cmake g++ libgtest-dev make libssl-dev
sudo apt-get install redis valgrind
- uses: actions/checkout@v2
- name: make
run: make
- name: make check
run: make check
- name: make tutorial
run: make tutorial
test:
name: fedora
runs-on: ubuntu-latest
steps:
- name: Setup Podman
run: |
sudo apt update
sudo apt-get -y install podman
podman pull fedora:rawhide
- name: Get source
uses: actions/checkout@v3
with:
path: 'workflow'
- name: Create container and run tests
run: |
{
echo 'FROM fedora:rawhide'
echo 'RUN dnf -y update'
echo 'RUN dnf -y install cmake gcc-c++ gtest-devel make'
echo 'RUN dnf -y install openssl-devel redis valgrind'
echo 'RUN dnf clean all'
echo 'COPY workflow workflow'
echo 'WORKDIR /workflow'
echo "RUN cmake"
echo "RUN make"
echo "RUN make check"
echo "RUN make tutorial"
} > podmanfile
podman build --tag fedorarawhide -f ./podmanfile