Sign inSign up

kalmars/ingress-default-backend

By kalmars

•Updated 12 months ago

Custom NGINX Ingress default backend for Kubernetes

Image
Networking
Developer tools
1

536

kalmars/ingress-default-backend repository overview

⁠Custom Default Backend for NGINX Ingress Controller

A lightweight, customizable default backend service for NGINX Ingress Controller in Kubernetes clusters. This Docker image provides a simple NGINX server that handles various HTTP status codes with custom error pages, perfect for improving user experience when services are unavailable or return errors.

⁠Key Features

  • Dark Theme Design: Modern dark theme with orange color accents
  • Animated 404 Page: Custom SVG animations with floating balloon design
  • Lightweight: Minimal Docker image based on NGINX Alpine
  • Customizable: Easy to modify HTML templates and styling
  • Status Code Support: Handles 400, 401, 403, 404, 500, 502, 503, and 504 status codes
  • Production Ready: Optimized for Kubernetes environments
  • Easy Integration: Simple Helm chart configuration

⁠Visual Design

The error pages feature a modern dark theme with:

  • Dark gradient background (#1a1a1a to #2d1b0e)
  • Orange accent colors (#ff8c42, #ff6b1a)
  • Animated 404 page with floating balloon
  • Glowing text effects
  • Floating particle animations

⁠Quick Start

⁠Using Helm
defaultBackend:
  enabled: true
  image:
    repository: kalmars/ingress-default-backend
    tag: "main"
    pullPolicy: Always
  port: 8080
⁠Manual Deployment
apiVersion: apps/v1
kind: Deployment
metadata:
  name: default-backend
spec:
  replicas: 1
  selector:
    matchLabels:
      app: default-backend
  template:
    metadata:
      labels:
        app: default-backend
    spec:
      containers:
      - name: default-backend
        image: kalmars/ingress-default-backend:main
        ports:
        - containerPort: 8080

⁠Customization

⁠Basic HTML Customization

To customize the error pages, fork this repository and modify the HTML files in the content/ directory. You can update:

  • CSS styling for better visual appearance
  • Text content and messaging
  • Branding and logos
  • Color schemes and layouts
⁠Building Custom Images

After making your customizations:

  1. Build the Docker image:

    docker build -t kalmars/ingress-default-backend:main .
    
  2. Push to your container registry:

    docker push kalmars/ingress-default-backend:main
    

⁠Configuration

⁠Environment Variables
  • NGINX_WORKER_PROCESSES: Number of NGINX worker processes (default: auto)
  • NGINX_WORKER_CONNECTIONS: Maximum number of connections per worker (default: 1024)
⁠NGINX Configuration

The default NGINX configuration is optimized for Kubernetes environments and includes:

  • Gzip compression
  • Security headers
  • Proper error page handling
  • Health check endpoint

⁠🔧 Technical Details

  • Base Image: nginx:alpine
  • Size: ~15MB
  • Architecture: Multi-arch (amd64, arm64)
  • Port: 8080
  • Health Check: Available at /health

⁠📄 License

This project is licensed under the MIT License - see the LICENSE⁠ file for details.

⁠🤝 Contributing

We welcome contributions! Please feel free to submit issues and pull requests.

⁠📞 Support

For support and questions, please open an issue in the GitHub repository⁠.


Made with ❤️ by Kalmars Group

Tag summary

Content type

Image

Digest

sha256:b88cbb4a1…

Size

21.6 MB

Last updated

12 months ago

docker pull kalmars/ingress-default-backend:main