name;
include fastcgi_params;
}
2) I start fastcgi using:
spawn-fcgi -F 4 -U nginx -p 8000 -P /tmp/wsapi-fcgi.pid -- /usr/lib/lua/wsapi/wsapi.fcgi
3) I copy all unpacked sputnik "lua" data to /usr/share/nginx/html, and rename sputnik.cgi to sputnik.lua
it's:
#! /usr/bin/lua
pcall(require, "luarocks.require")
require('sputnik.wsapi_app')
local my_app = sputnik.wsapi_app.new{
VERSIUM_PARAMS = { '/usr/share/nginx/html/wiki-data/' },
BASE_URL = '/sputnik.lua',
PASSWORD_SALT = 'mekCbtB9JMwrktsyHQazLN5yJOTlgVMtZWV1gm0P',
TOKEN_SALT = 'Ym69Gpxe5xDGbz5KdOVjzyDpkogrB66pi3oPiLTd',
SHOW_STACK_TRACE = true,
}
--require("wsapi.cgi")
--wsapi.cgi.run(my_app)
return my_app
when I put URL is
http://localhost/sputnik.lua, I got below error:
Sputnik ran but failed due to an unexpected error.
Error details:
/usr/share/lua/5.1//coxpcall.lua:41: attempt to call upvalue 'f' (a nil value)
stack traceback:
/usr/share/lua/5.1//coxpcall.lua:41: in function </usr/share/lua/5.1//coxpcall.lua:41>
Can anyone give some suggestion for this error? Or it's a bug of sputnik?