Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

I've always wanted to use nginx to build web apps in Lua .. does anyone know/can recommend any great tutorials with this in mind? It'd be nice if I could learn how to use nginx+lua to build a blog, and so on .. I'll use google, but on the off chance someone on HN knows of something already, I'm all ears ..


You might be interested to know that NginX can even embed Lua internally as a scripting language in the configuration[1].

As for your goals of connecting NginX to serve your Lua project, well that's quite simple really. Unlike Apache or Lighttpd, NginX is not an application server. NginX is only a reverse proxying HTTP server that speaks HTTP, FastCGI, and UWSGI. To connect your Lua application to NginX, your Lua application will either need to speak HTTP, FastCGI, or UWSGI. I don't know anything about Lua so I can't really help you figure out which is best, but in terms of setting up with NginX, it mostly just changes which flavor of pass you will use.

[1]- http://wiki.nginx.org/HttpLuaModule


Thanks for the reply - I am definitely learning a lot from this feedback, and appreciate the effort.


Check out Lapis - http://leafo.net/lapis/ and OpenResty which is what lapis is built upon http://openresty.org/


Looks like I'll be studying Lapis for the next few days - great stuff, thanks for the recommendation!


There is an intro talk and slides from London Lua here http://www.londonlua.org/scripting_nginx_with_lua/index.html

It is pretty easy once you get started...


Great - that looks like exactly what I need to get myself educated on the subject - really appreciate the great response, thank you!




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: