services: nginx: restart: unless-stopped build: context: . container_name: imgproxy_gateway security_opt: - no-new-privileges:true
ports:
- "80:80"
volumes:
- ${DEPLOY_DIR:-.}/www:/home:ro
- ${DEPLOY_DIR:-.}/cache:/var/cache/nginx/imgproxy
- ${DEPLOY_DIR:-.}/logs:/var/log/nginx
- ${DEPLOY_DIR:-.}/nginx/nginx.conf:/etc/nginx/nginx.conf:ro
- ${DEPLOY_DIR:-.}/nginx/conf.d/imgproxy.stg.conf:/etc/nginx/conf.d/imgproxy.conf:ro
- ${DEPLOY_DIR:-.}/nginx/conf.d/origins.conf:/etc/nginx/conf.d/origins.conf:ro
- ${DEPLOY_DIR:-.}/nginx/conf.d/security.conf:/etc/nginx/conf.d/security.conf:ro
- ${DEPLOY_DIR:-.}/certbot/www:/var/www/certbot:ro
depends_on:
imgproxy:
condition: service_healthy
healthcheck:
test: ["CMD", "wget", "--spider", "-q", "http://127.0.0.1"]
interval: 30s
timeout: 5s
retries: 3
start_period: 10s
ulimits:
nofile:
soft: 65535
hard: 65535
environment:
NGINX_ENTRYPOINT_QUIET_LOGS: 1
networks:
- imgproxy_network
imgproxy: restart: unless-stopped image: darthsim/imgproxy:${IMGPROXY_TAG:-latest} container_name: imgproxy_app
security_opt:
- no-new-privileges:true
expose:
- "8080"
volumes:
- ${DEPLOY_DIR:-.}/www:/home:ro
healthcheck:
test: ["CMD", "imgproxy", "health"]
interval: 30s
timeout: 5s
retries: 3
start_period: 20s
environment:
IMGPROXY_BIND: ":8080"
IMGPROXY_LOG_LEVEL: "warn"
IMGPROXY_ENABLE_DEBUG_HEADERS: "false"
IMGPROXY_DEVELOPMENT_ERRORS_MODE: "false"
IMGPROXY_REPORT_DOWNLOADING_ERRORS: "false"
IMGPROXY_FALLBACK_IMAGE_URL: "local:///no-img-gc/no_img_S1.jpg"
IMGPROXY_FALLBACK_IMAGE_HTTP_CODE: 200
IMGPROXY_READ_TIMEOUT: 10
IMGPROXY_WRITE_TIMEOUT: 10
IMGPROXY_DOWNLOAD_TIMEOUT: 10
IMGPROXY_KEEP_ALIVE_TIMEOUT: 300
IMGPROXY_MAX_SRC_FILE_SIZE: 33554432
IMGPROXY_MAX_SRC_RESOLUTION: 50
IMGPROXY_TTL: 2592000
IMGPROXY_USE_ETAG: "true"
IMGPROXY_SO_REUSEPORT: "true"
IMGPROXY_IGNORE_SSL_VERIFICATION: "false"
IMGPROXY_LOCAL_FILESYSTEM_ROOT: /home
IMGPROXY_SKIP_PROCESSING_FORMATS: "svg"
IMGPROXY_AUTO_ROTATE: "true"
IMGPROXY_STRIP_METADATA: "true"
IMGPROXY_STRIP_COLOR_PROFILE: "true"
IMGPROXY_FORMAT_QUALITY: jpeg=82,webp=75,avif=55
IMGPROXY_JPEG_PROGRESSIVE: "true"
IMGPROXY_PNG_INTERLACED: "false"
IMGPROXY_PNG_QUANTIZATION_COLORS: 128
IMGPROXY_PNG_QUANTIZE: "false"
IMGPROXY_MAX_ANIMATION_FRAMES: 64
IMGPROXY_GZIP_COMPRESSION: 0
IMGPROXY_AVIF_SPEED: 8
IMGPROXY_REQUESTS_QUEUE_SIZE: 100
IMGPROXY_WORKER_TIMEOUT: 30
IMGPROXY_CONCURRENCY: 4
networks:
- imgproxy_network
logrotate: image: blacklabelops/logrotate:1.3 container_name: logrotate restart: unless-stopped
volumes:
- ./logs:/logs
- ./logs/old:/logs/old
environment:
LOG_FILE_ENDINGS: "log"
LOGROTATE_COMPRESSION: "compress"
LOGROTATE_COPIES: "30"
LOGROTATE_DATEFORMAT: "-%Y%m%d"
LOGROTATE_INTERVAL: "daily"
LOGROTATE_LOGFILE: "/logs/logrotate.log"
LOGROTATE_OLDDIR: "/logs/old"
LOGROTATE_PARAMETERS: "f"
LOGROTATE_SIZE: "50M"
LOGROTATE_STATUSFILE: "/logs/logrotate-status.log"
LOGS_DIRECTORIES: "/logs"
networks: imgproxy_network: driver: bridge
Content type
Image
Digest
sha256:48bf96b18…
Size
24.9 MB
Last updated
4 months ago
docker pull vannhatcd/imgproxy-gateway