Browse Source

Added files to build mod-http-tnt as dynamic module within *.deb package in Debian-based system

master
annelin 1 month ago
parent
commit
dffb1270b0

+ 3
- 0
.gitmodules View File

@@ -4,3 +4,6 @@
[submodule "third_party/msgpuck"]
path = third_party/msgpuck
url = https://github.com/rtsisyk/msgpuck.git
[submodule "debian/modules/nginx-tnt"]
path = debian/modules/nginx-tnt
url = https://dev.narayana.im/narayana/tarantool-nginx

+ 12
- 0
README.md View File

@@ -29,6 +29,18 @@ https://hub.docker.com/r/tarantool/tarantool-nginx
Tarantool:
https://hub.docker.com/r/tarantool/tarantool
## Building *.deb package with dynamic module in Debian
----------------
```bash
apt build-dep nginx
apt source nginx
cd nginx-*/
cp -r <debian directory from repository> .
patch debian/control control.patch
patch debian/rules rules.patch
debuild -us -uc
```
## Status
---------
* v0.1.4 - Production ready.

+ 25
- 0
debian/control.patch View File

@@ -0,0 +1,25 @@
--- debian/control~ 2019-10-19 09:54:53.813081943 +0300
+++ debian/control 2019-10-19 09:52:52.000000000 +0300
@@ -16,6 +16,8 @@
libhiredis-dev,
liblua5.1-0-dev [!i386 !amd64 !kfreebsd-i386 !armel !armhf !powerpc !powerpcspe !mips !mipsel],
libluajit-5.1-dev [i386 amd64 kfreebsd-i386 armel armhf powerpc powerpcspe mips mipsel],
+ libmsgpuck-dev (>= 2.0),
+ libyajl-dev (>= 2.0),
libmhash-dev,
libpam0g-dev,
libpcre3-dev,
@@ -259,6 +261,13 @@
The module uses PAM as a backend for simple http authentication. It
also allows setting the pam service name to allow more fine grained control.
+Package: libnginx-mod-http-tnt
+Architecture: any
+Depends: libyajl2,
+ ${misc:Depends},
+ ${shlibs:Depends}
+Description: Tarantool backend module for Nginx
+
Package: libnginx-mod-http-lua
Architecture: any
Depends: libnginx-mod-http-ndk (= ${binary:Version}),

+ 13
- 0
debian/libnginx-mod-http-tnt.nginx View File

@@ -0,0 +1,13 @@
#!/usr/bin/perl -w

use File::Basename;

# Guess module name
$module = basename($0, '.nginx');
$module =~ s/^libnginx-mod-//;

$modulepath = $module;
$modulepath =~ s/-/_/g;

print "mod debian/build-extras/objs/ngx_${modulepath}_module.so\n";
print "mod debian/libnginx-mod.conf/mod-${module}.conf\n";

+ 1
- 0
debian/libnginx-mod.conf/mod-http-tnt.conf View File

@@ -0,0 +1 @@
load_module modules/ngx_http_tnt_module.so;

+ 1
- 0
debian/modules/nginx-tnt

@@ -0,0 +1 @@
Subproject commit d189012628c4c96b062575b8e75ca2a1beb577ab

+ 18
- 0
debian/rules.patch View File

@@ -0,0 +1,18 @@
--- debian/rules~ 2019-10-19 09:54:37.272873112 +0300
+++ debian/rules 2019-10-19 09:52:47.000000000 +0300
@@ -21,6 +21,7 @@
http-headers-more-filter \
http-image-filter \
http-lua \
+ http-tnt \
http-ndk \
http-perl \
http-subs-filter \
@@ -135,6 +136,7 @@
--add-dynamic-module=$(MODULESDIR)/ngx-fancyindex \
--add-dynamic-module=$(MODULESDIR)/nchan \
--add-dynamic-module=$(MODULESDIR)/nginx-lua \
+ --add-dynamic-module=$(MODULESDIR)/nginx-tnt \
--add-dynamic-module=$(MODULESDIR)/nginx-upload-progress \
--add-dynamic-module=$(MODULESDIR)/nginx-upstream-fair \
--add-dynamic-module=$(MODULESDIR)/ngx_http_substitutions_filter_module

Loading…
Cancel
Save