Production-ready Docker image for Resource Management Frontend (React + Nginx)
382
A production-ready, reusable frontend Docker image for the Resource Management application.
This image is designed to be generic and environment-agnostic:
Browser
β
Nginx (Frontend Container)
β /api/*
Backend API (Any Host / Any Env)
/api/* requests are reverse-proxied to the backendnginx:1.25-alpineenvsubst (from gettext)80docker pull riteshatri/resource-management-frontend:latest
docker run -d \
-p 80:80 \
-e BACKEND_HOST=10.0.0.5 \
-e BACKEND_PORT=8000 \
--name frontend \
riteshatri/resource-management-frontend:latest
πΉ Replace BACKEND_HOST and BACKEND_PORT with your backend details.
| Variable | Description | Example |
|---|---|---|
BACKEND_HOST | Backend server hostname or IP | backend, 10.0.0.5 |
BACKEND_PORT | Backend service port | 8000 |
β These are required at runtime. Without them, Nginx will not start correctly.
curl http://localhost/health
Expected response:
healthy
version: "3.9"
services:
backend:
image: backend-app
ports:
- "8000:8000"
frontend:
image: riteshatri/resource-management-frontend:latest
ports:
- "80:80"
environment:
BACKEND_HOST: backend
BACKEND_PORT: 8000
depends_on:
- backend
Run:
docker compose up -d
BACKEND_HOST / BACKEND_PORTenv: in Deploymentstdout / stderrexec nginx)Ritesh Sharma
DevOps Engineer | Cloud | Docker | Azure | CI/CD
If this image helped you:
Content type
Image
Digest
sha256:79c64929aβ¦
Size
20.8 MB
Last updated
9 months ago
docker pull riteshatri/resource-management-frontend