Self-host OpenResty with Levelrail
The OpenResty web platform, Nginx with LuaJIT, on the Alpine image with a persistent web root. It serves the default page until you add content or configuration.
- Authoropenresty
- LicenceBSD-2-Clause
- Memory128 MiB
- Services1
How to self-host OpenResty
-
Pull the images
One image is pulled on your server.
Show images
openresty/openresty:1.27.1.2-13-alpine-fat
-
Create the app
One service starts in a single Compose app, with 1 named volume mount for your data, on port 80.
-
Fill in the secrets
You do not have to fill in anything.
-
Open it
Without a domain the app gets an sslip.io address; add --domain SERVICE=HOST to use your own.
After the first start
- Open the public address to see the default page, then add content to the web root volume.
OpenResty requirements
- Memory
- About 128 MiB
- Architectures
- amd64 unknown, arm64 unknown
- Ports
- 80
- Domain
- Optional, an sslip.io address is used without one
- Settings
- none to fill in
- License
- BSD-2-Clause, permissive license
- Listed. It is in the catalog but not verified. Back up the data volume before changing an image tag.
Install Levelrail first
On a server with Levelrail running, run the command above, or open the dashboard: Apps, New app, Browse templates, then OpenResty. New to Levelrail? Install it on a fresh VPS first.
docker pull ghcr.io/glincker/levelrail:latest Then levelrail-cli login --device. See Getting started and the OpenResty docs page.
Deploy OpenResty your way
Every format below deploys the same pinned images. Pick the one that fits how you work.
Deploy OpenResty from the CLI
levelrail-cli templates deploy openresty --name my-openresty Deploy OpenResty with the API
curl -X POST -H "Authorization: Bearer $TOKEN" \
https://levelrail.example.com/api/v1/service-templates/openresty/deploy OpenResty configuration
OpenResty services
| Service | Image | Ports | Volumes |
|---|---|---|---|
| openresty | openresty/openresty:1.27.1.2-13-alpine-fat | 80 | openresty_html -> /usr/local/openresty/nginx/html |
OpenResty environment variables
The catalog lists no environment variables for this template.
Ports and volumes
- Ports
- 80
- Volumes
- 1 named mount: openresty_html -> /usr/local/openresty/nginx/html
OpenResty FAQ
How much memory does OpenResty need?
The catalog lists about 128 MiB of memory for OpenResty.
Does OpenResty run on arm64?
For OpenResty, arm64 support is not confirmed; amd64 is unknown.
What licence is OpenResty under?
OpenResty is licensed under BSD-2-Clause, which is permissive, with few conditions on reuse.
Does OpenResty need configuration before it starts?
No. The template fills in its own defaults.
Which ports does OpenResty use?
OpenResty listens on port 80 inside the stack.
Where does OpenResty keep its data?
In a named volume: openresty_html mounted at /usr/local/openresty/nginx/html.
Can I deploy OpenResty on Dokploy or Dokku?
The services and pinned images on this page can be run on any Docker host. The public Dokploy templates list we compared does not have an entry with the same id for OpenResty, so on Dokploy you would use a Docker Compose application with the file from this page. Dokku deploys container images with its own commands, so the pinned image openresty/openresty:1.27.1.2-13-alpine-fat is what you deploy there.