A developer created a Neovim plugin that serves HTTP requests directly from editor buffers using pure Lua. The plugin leverages Neovim's libuv bindings for asynchronous I/O and surprisingly outperforms Nginx in benchmarks due to LuaJIT's efficiency and NaN tagging optimization. The implementation serves a static website from nine buffers on a 2012 ThinkPad, with security measures including Docker containerization, AppArmor profiles, and restricted system calls. The setup demonstrates how text editors can be repurposed for unconventional tasks while maintaining good performance.

10m read timeFrom vim.gabornyeki.com
Post cover image
Table of contents
ContentsThis must be slowDeploying on an old ThinkPadIs this even safe?
3 Comments

Sort: