Pastebin-like service in Lapis
Lua MoonScript Shell Nginx PHP
Switch branches/tags
Nothing to show
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Failed to load latest commit information.
src nginx-production: update RE of mobile browser UA Sep 2, 2016
LICENSE schema creation URL -> Lapis migrations Feb 18, 2016
pasta-dev-1.rockspec rockspec: add missing module show_password.lua Aug 6, 2016 fix reading from stdin Aug 13, 2016

pasta, Pastebin-like service in Lapis

How to use

  1. Install Lapis
  2. Install OpenResty
  3. Install LuaRocks
  4. Setup the database and change pasta/src/config.lua
  5. cd pasta && sudo luarocks make
  6. cd pasta/src && lapis migrate
  7. cd pasta/src && lapis server

If your Nginx has multiple workers, disable cache in config.lua.

You can also use it without OpenResty, but in Nginx with LuaJIT support. In Debian it can be installed with package nginx-extras. Copy file src/nginx.conf.compiled generated by lapis server production to /etc/nginx/sites-available/pasta and add a symlink to it in /etc/nginx/sites-enabled. Change it for your setup and add the following line after content_by_lua:

package.loaded.config = dofile "/path/to/your/config.lua"

See also Nginx configuration used for site src/nginx-production.