Prerequisites
- Docker and Docker Compose installed
- Network connectivity to the UAE KYC backend (via VPN/tunnel or public IP whitelisting)
Docker Compose File
Obtain the custom nginx Docker image from the Nexus repository provided by the UAE KYC team.Replace
your-registry.com/uaekyc-nginx:latest in the file below with the actual Nexus registry URL provided by the UAE KYC team.docker-compose.yml in your project directory:
docker-compose.yml
Quick Start
# Your proxy domains
API_DOMAIN=uaekyc-api.yourbank.ae
DASH_DOMAIN=uaekyc-dash.yourbank.ae
SDK_DOMAIN=uaekyc-sdk.yourbank.ae
# Backend addresses (see Backend Connectivity below)
BACKEND_API_ADDR=https://api.example.com
BACKEND_DASH_ADDR=https://dash.example.com
BACKEND_API_HOST=api.example.com
BACKEND_DASH_HOST=dash.example.com
Environment Variables
Copy.env.example to .env and customize. All variables are listed below.
Required
| Variable | Description | Example |
|---|---|---|
API_DOMAIN | Your public API domain | uaekyc-api.yourbank.ae |
DASH_DOMAIN | Your dashboard domain | uaekyc-dash.yourbank.ae |
SDK_DOMAIN | Your SDK domain | uaekyc-sdk.yourbank.ae |
BACKEND_API_ADDR | Backend API address (IP or URL) | https://api.example.com |
BACKEND_DASH_ADDR | Backend dashboard address (IP or URL) | https://dash.example.com |
BACKEND_API_HOST | Host header for API backend | api.example.com |
BACKEND_DASH_HOST | Host header for dashboard backend | dash.example.com |
Optional
| Variable | Default | Description |
|---|---|---|
ENABLE_SSL | false | Enable HTTPS |
SSL_PROTOCOLS | TLSv1.3 | Allowed SSL/TLS protocols |
RATELIMIT_API_DOMAIN | 20r/s | API domain rate limit |
RATELIMIT_DASH_DOMAIN | 20r/s | Dashboard domain rate limit |
RATELIMIT_SDK_DOMAIN | 20r/s | SDK domain rate limit |
RATELIMIT_GENERAL | 60r/s | Global rate limit |
RATELIMIT_API | 20r/s | API-specific rate limit |
RATELIMIT_HEALTH | 1r/s | Health endpoint rate limit |
RATELIMIT_STRICT | 1r/s | Strict rate limit |
CLIENT_MAX_BODY_SIZE_API_DOMAIN | 10M | API max request body size |
CLIENT_MAX_BODY_SIZE_DASH_DOMAIN | 10M | Dashboard max request body size |
CLIENT_MAX_BODY_SIZE_SDK_DOMAIN | 10M | SDK max request body size |
CLIENT_MAX_BODY_SIZE_GLOBAL | 100M | Global max request body size |
WORKER_PROCESSES | auto | Nginx worker processes |
WORKER_CONNECTIONS | 1024 | Connections per worker |
GZIP_COMP_LEVEL | 6 | Gzip compression level (1–9) |
PROXY_CONNECT_TIMEOUT | 60s | Proxy connect timeout |
PROXY_SEND_TIMEOUT | 60s | Proxy send timeout |
PROXY_READ_TIMEOUT | 300s | Proxy read timeout |
CACHE_MAX_SIZE | 1g | Proxy cache max size |
CACHE_INACTIVE | 60m | Cache inactive expiry |
ERROR_LOG_LEVEL | error | Nginx error log level |
Backend Connectivity
The proxy supports two connectivity modes depending on your network setup.- Public IP Whitelisting (DNS)
- VPN / Tunnel (Private IP)
Use this when there is no tunnel. The backend domains are publicly reachable and your client IP has been whitelisted by the UAE KYC team.
| Variable | Purpose |
|---|---|
BACKEND_API_ADDR | Resolves to the real backend IP via public DNS |
BACKEND_API_HOST | Sets the correct Host header (same as the domain in this case) |
SSL / HTTPS
Controlled by a single variable:ENABLE_SSL=true, place your certificate files in the ssl/ directory. The target paths inside the container are fixed — only the source paths on your host change:
TLSv1.3, configurable via:
Optional Configuration
Rate Limiting
Rate Limiting
{number}r/{s|m|h|d} where s=second, m=minute, h=hour, d=day.Upload Size Limits
Upload Size Limits
Performance Tuning
Performance Tuning
Proxy Timeouts
Proxy Timeouts
Cache
Cache
Custom Nginx Directives
For advanced use cases (extra headers, rewrites, upstream tweaks), custom nginx directives can be injected per-service via volume mounts. All four files are pre-created empty inside the image and are completely optional. Uncomment the relevant lines indocker-compose.yml:
