Levelrail
Skip to content

Self-host Nginx Reverse Proxy (Multi-Backend) with Docker ​

One Nginx entrypoint routing to two independent backend services, demonstrating depends_on across three services.

This page describes the Levelrail template for Nginx Reverse Proxy (Multi-Backend) (Starter Kits). It deploys the services below as one Docker Compose app on your own server.

Project site: https://nginx.org/en/docs/http/ngx_http_proxy_module.html.

Recommended memory: about 192 MiB.

Services, ports and volumes ​

ServiceImageContainer portsVolumes
ordersnode:22-alpinenonenone
paymentsnode:22-alpinenonenone
proxynginx:1.27-alpine80none

Environment variables ​

ServiceVariableValue
ordersNODE_ENVPreset in the template
paymentsNODE_ENVPreset in the template

Passwords and keys marked as generated are created for you when the app is deployed and stored as secrets. Values are not shown here.

Deploy Nginx Reverse Proxy (Multi-Backend) with Levelrail ​

In the dashboard, open Apps, choose New app, then Browse templates, and select Nginx Reverse Proxy (Multi-Backend). Review the Compose body and deploy.

With the CLI:

levelrail-cli templates deploy nginx-multi-backend-starter --name my-nginx-multi-backend-starter

See Service template catalog for how templates work, and Getting started if you have not installed Levelrail yet.

More Starter Kits templates ​

All templates are listed in the self-host gallery.

Released under the Apache 2.0 License.