-
Notifications
You must be signed in to change notification settings - Fork 2.5k
97 lines (95 loc) · 2.9 KB
/
test-ntls.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
94
95
96
97
name: test tengine ntls
on:
push:
branches: [ master ]
pull_request:
branches: [ master ]
jobs:
build-and-test:
runs-on: "ubuntu-20.04"
strategy:
fail-fast: false
matrix:
compiler:
- { compiler: GNU, CC: gcc, CXX: g++}
- { compiler: LLVM, CC: clang, CXX: clang++}
steps:
- uses: actions/checkout@v3
with:
path: tengine
- name: 'checkout luajit2'
uses: actions/checkout@v3
with:
repository: openresty/luajit2
path: luajit2
- name: 'build luajit2'
working-directory: luajit2
run: |
make
sudo make install
- name: 'checkout lua-resty-lrucache'
uses: actions/checkout@v3
with:
repository: openresty/lua-resty-lrucache
path: lua-resty-lrucache
- name: 'build lua-resty-lrucache'
working-directory: lua-resty-lrucache
run: |
sudo make install
- name: 'checkout lua-resty-core'
uses: actions/checkout@v3
with:
repository: openresty/lua-resty-core
path: lua-resty-core
- name: 'build lua-resty-core'
working-directory: lua-resty-core
run: |
sudo make install
- name: checkout Tongsuo
uses: actions/checkout@v3
with:
repository: Tongsuo-Project/Tongsuo
path: Tongsuo
- name: build Tongsuo
working-directory: Tongsuo
env:
CC: ${{ matrix.compiler.CC }}
run: |
./config --prefix=${RUNNER_TEMP}/tongsuo enable-ntls no-shared
make -s -j4
make install_sw
make clean
- name: build Tengine
working-directory: tengine
env:
CC: ${{ matrix.compiler.CC }}
CXX: ${{ matrix.compiler.CXX }}
LUAJIT_LIB: /usr/local/lib
LUAJIT_INC: /usr/local/include/luajit-2.1
run: |
./configure \
--with-ld-opt="-Wl,-lpcre,-rpath,/usr/local/lib" \
--with-pcre \
--add-module=modules/ngx_tongsuo_ntls \
--add-module=modules/ngx_http_lua_module \
--with-openssl=../Tongsuo \
--with-openssl-opt="--api=1.1.1 enable-ntls" \
--with-http_ssl_module \
--with-http_v2_module \
--with-stream \
--with-stream_ssl_module \
--with-stream_sni
make -j2
sudo make install
- name: run test cases
working-directory: tengine
env:
TEST_OPENSSL_BINARY: ${{ runner.temp }}/tongsuo/bin/tongsuo
TEST_NGINX_BINARY: /usr/local/nginx/sbin/nginx
TEST_NGINX_LEAVE: 1
run: |
prove -Itests/nginx-tests/nginx-tests/lib/ modules/ngx_tongsuo_ntls/t
- name: debug
if: ${{ failure() }}
run: |
for file in `ls /tmp/nginx-test-*/error.log`; do cat $file; done