LuaDB is a web service platform written in C. User application code is written in Lua and access is provided via a convenient HTTP API, routed through an existing web server (such as nginx or Apache).
To get started, clone this repository on your local computer:
git clone github.com/chrisrink10/luadb
You'll need a copy of CMake 3.1 to generate the appropriate makefiles for your system.
Follow the steps laid out below for your System.
Follow these steps to compile LuaDB:
- Open a command prompt (such as
Terminal
for OS X) to your project build location. - Enter the command
cmake .
. - Enter the command
make
.
For now, Windows is not a target platform for LuaDB. As such, we will make no guarantees that it will compile successfully under Windows. That said, you are welcome to try.
Windows will require mingw64 in
order to compile for Windows. Note that you may need to add the MinGW bin
directory to your environment variable %path%
.
Once you have installed MinGW, follow the steps below:
- Generate MinGW Makefiles with CMake GUI.
- Open
cmd
to the project build location specified in CMake. - Type
mingw32-make
.
LuaDB environment configuration is specified via configuration files
written in - unsurprisingly - Lua format. For UNIX-like operating systems,
that configuration file will be located at /etc/luadb/config.lua
. For
Windows, it will be %installdir%\config.lua
.
The configuration file contains comments explaining the meaning of each setting. If you make any changes while LuaDB is running, you will need to terminate the instance for your changes to take effect.
In addition to LuaDB configuration, you will need to specify appropriate configuration to pass FastCGI requests on to the LuaDB application.
LuaDB provides a number of specialized Lua APIs for application code. This
is documented in the API file in the doc
folder in the project root.
MIT License - see LICENSE file provided in the project root for more details of the licenses of bundled code.
- Lua - detailed documentation of C and Lua APIs
- Lua-Users.org - excellent Wiki and mailing lists
- Symas LMDB - key-value store used by LuaDB
- CCAN - source of JSON module used in LuaDB
- FastCGI - source of FastCGI C module
- Linenoise - line editing library
- mingw64 - GCC for Windows
- CMake - cross-platform make specification tool