Package Details: nginx-mainline-mod-njs 0.6.1-1

Git Clone URL: (read-only, click to copy)
Package Base: nginx-mainline-mod-njs
Description: nginScript module for mainline nginx
Upstream URL:
Licenses: custom
Submitter: mtorromeo
Maintainer: mtorromeo
Last Packager: mtorromeo
Votes: 3
Popularity: 0.000036
First Submitted: 2017-04-06 09:43
Last Updated: 2021-06-30 08:15

Dependencies (2)

Required by (0)

Sources (1)

Latest Comments

Taijian commented on 2020-03-09 11:18

Hi there!

Just a small request: The PKGBUILD for this package states that it is only compatible with x86 architectures. However, I'm running it just fine on armv7h. So maybe add the various arm architectures to the PKGBUILD as well?

Thank you!

diraria commented on 2017-04-17 16:52

Yes, you are right, thank you a lot!
It is very strange, that in nginScript documentation (at js_run exists.

mtorromeo commented on 2017-04-17 08:38

The js_run directive doesn't exist.
ngx_http_js_module only has 3 directives: js_include, js_content and js_set

I suggest you read the module documentation:

diraria commented on 2017-04-17 07:33

Thank you for answer! Can you, please, help me. I do:
1) Install nginx-mainline
2) Install nginx-mainline-mod-njs
3) Reboot

3) Add location with js_run to server block in /etc/nginx/nginx.conf
location /hello {
js_run "function hello(req, res) {
res.contentType = 'text/plain';
res.status = 200;

res.send( 'Hello, world!' );

4) Run "nginx -s reload"
It gives me error 'unknown directive "js_run"'.

Also I tried to add lines
load_module /usr/lib/nginx/modules/;
load_module /usr/lib/nginx/modules/;
to the beginning of /etc/nginx/nginx.conf, and it didn't help. Thank you!

mtorromeo commented on 2017-04-17 00:39

No, these modules are compiled to work WITH nginx-mainline so you should not remove it.

diraria commented on 2017-04-16 11:31

Hello, thank you for this package! Could you say, please, if I have already installed nginx-mainline, should I delete ngonx-mainline before install your package? Thank you!