Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ci: support freenginx #303

Merged
merged 1 commit into from
Oct 28, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
29 changes: 29 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,11 @@ jobs:
with:
repository: nginx/nginx
path: nginx
- name: 'checkout freenginx'
uses: actions/checkout@v3
with:
repository: freenginx/nginx
path: freenginx
- name: 'checkout luajit2'
uses: actions/checkout@v3
with:
Expand Down Expand Up @@ -68,6 +73,10 @@ jobs:
working-directory: nginx
run: |
patch -p1 < /home/runner/work/nginx-module-vts/nginx-module-vts/nginx_upstream_check/check_1.20.1+.patch
- name: 'patch upstream_check for freenginx'
working-directory: freenginx
run: |
patch -p1 < /home/runner/work/nginx-module-vts/nginx-module-vts/nginx_upstream_check/check_1.20.1+.patch
- name: 'build nginx'
working-directory: nginx
run: |
Expand All @@ -78,6 +87,16 @@ jobs:
env:
LUAJIT_LIB: /usr/local/lib
LUAJIT_INC: /usr/local/include/luajit-2.1
- name: 'build freenginx'
working-directory: freenginx
run: |
./auto/configure --prefix=/usr/local/freenginx --with-ld-opt="-Wl,-rpath,/usr/local/lib" --without-pcre2 --add-module=/home/runner/work/nginx-module-vts/nginx-module-vts/ngx_devel_kit --add-module=/home/runner/work/nginx-module-vts/nginx-module-vts/lua-nginx-module --add-module=/home/runner/work/nginx-module-vts/nginx-module-vts/nginx-module-vts --add-module=/home/runner/work/nginx-module-vts/nginx-module-vts/nginx_upstream_check
make
sudo make install
/usr/local/freenginx/sbin/nginx -V
env:
LUAJIT_LIB: /usr/local/lib
LUAJIT_INC: /usr/local/include/luajit-2.1
- name: 'prepare cpanm'
run: |
sudo apt install -y cpanminus
Expand All @@ -98,3 +117,13 @@ jobs:
run: |
echo "/usr/local/nginx/sbin/" >> $GITHUB_PATH
sudo TEST_UPSTREAM_CHECK=1 TEST_NGINX_SLEEP=1 PATH=/usr/local/nginx/sbin:$PATH prove t/024.upstream_check.t
- name: 'test freenginx'
working-directory: nginx-module-vts
run: |
echo "/usr/local/freenginx/sbin/" >> $GITHUB_PATH
sudo PATH=/usr/local/freenginx/sbin:$PATH prove -r t
- name: 'test upstream check for freenginx'
working-directory: nginx-module-vts
run: |
echo "/usr/local/freenginx/sbin/" >> $GITHUB_PATH
sudo TEST_UPSTREAM_CHECK=1 TEST_NGINX_SLEEP=1 PATH=/usr/local/freenginx/sbin:$PATH prove t/024.upstream_check.t
Loading