Architectural Walkthrough of Seelen on DigitalOcean

How we built a cloud-native platform on DigitalOcean capable of serving more than 40,000 daily active users while keeping operations simple and scalable.


Introduction

Seelen UI started as an open-source desktop customization project for Windows. As adoption accelerated, the project evolved into a complete ecosystem consisting of authentication services, synchronization APIs, licensing infrastructure, analytics systems, update delivery, and community services.

Over the last few months, Seelen UI has experienced substantial growth, reaching approximately 40,000 daily active users and more than 12,000 Discord community members.

Supporting that growth required infrastructure capable of scaling automatically while remaining manageable for a small development team.

To achieve this, we built our backend entirely on DigitalOcean using:

  • DigitalOcean Kubernetes (DOKS)
  • Managed MongoDB
  • Redis
  • nginx-ingress
  • cert-manager
  • Container Registry
  • Spaces Object Storage

This article provides a technical walkthrough of the architecture that powers Seelen today.


High-Level Architecture

At a high level, the platform follows a cloud-native microservice architecture.

                                Users
                                   │
                                   ▼
                        nginx-ingress Controller
                                   │
              ┌────────────────────┼────────────────────┐
              ▼                    ▼                    ▼
        Website API         Authentication        Product API
              │                    │                    │
              └────────────────────┼────────────────────┘
                                   │
                     ┌─────────────┴─────────────┐
                     ▼                           ▼
                  Redis                      MongoDB

Every service runs inside Kubernetes and is designed to remain stateless.

Persistent data lives outside application containers, allowing Kubernetes to freely scale workloads up and down without affecting user experience.


Kubernetes as the Core Platform

The entire backend infrastructure runs inside a DigitalOcean Kubernetes cluster.

Rather than managing virtual machines directly, every service is deployed as a Kubernetes Deployment.

This provides:

  • Self-healing infrastructure
  • Rolling deployments
  • Horizontal scaling
  • Service discovery
  • Simplified operations

The cluster itself is configured with autoscaling worker nodes.

min_nodes: 1
max_nodes: 5
auto_scale: true

During traffic spikes, additional worker nodes are automatically provisioned.

When traffic decreases, unused capacity is removed automatically, helping optimize infrastructure costs.


Stateless Services by Design

One of our most important architectural decisions was ensuring that services remain stateless.

Application containers do not store:

  • User sessions
  • Authentication state
  • Cached content
  • User preferences
  • Temporary application data

Instead, state is externalized to dedicated infrastructure components such as Redis and MongoDB.

This allows Kubernetes to terminate and recreate pods at any time without affecting active users.

Pod Terminated
       │
       ▼
New Pod Created
       │
       ▼
Reconnects to Redis and MongoDB
       │
       ▼
Continues Serving Requests

This design is fundamental for reliable autoscaling.


Real-World Deployment Configuration

Most Seelen services follow a consistent deployment pattern.

Each service typically consists of:

  • Kubernetes Deployment
  • ClusterIP Service
  • nginx Ingress
  • Automatic TLS certificates
  • Health probes
  • Shared secrets
  • Redis connectivity

A simplified example from our website deployment:

env:
  - name: REDIS_HOST
    value: redis.<NAMESPACE>.svc.cluster.local

  - name: REDIS_PORT
    value: "6379"

envFrom:
  - secretRef:
      name: shared-secret

Using Kubernetes service discovery allows services to communicate internally without relying on static IP addresses.

This significantly simplifies maintenance and scaling.


Horizontal Pod Autoscaling

One of the most important features of our platform is Horizontal Pod Autoscaling (HPA).

Rather than running a fixed number of application instances, Kubernetes automatically adjusts replica counts based on resource utilization.

A simplified configuration looks like:

apiVersion: autoscaling/v2
kind: HorizontalPodAutoscaler

spec:
  minReplicas: 2
  maxReplicas: 20

  metrics:
    - type: Resource
      resource:
        name: cpu
        target:
          type: Utilization
          averageUtilization: 70

When traffic increases:

2 Pods
  ↓
4 Pods
  ↓
8 Pods
  ↓
16 Pods

Additional replicas are created automatically without manual intervention.

This allows Seelen to absorb traffic spikes while maintaining response times.


Solving the Cache Problem

Autoscaling introduces an architectural challenge.

Traditional in-memory caching becomes ineffective when multiple replicas are running simultaneously.

For example:

Pod A Cache
Pod B Cache
Pod C Cache
Pod D Cache

Each pod maintains its own cache state.

As traffic moves between replicas, cache hit rates decrease and application behavior becomes inconsistent.

Many systems experience cache fragmentation when autoscaling because newly created replicas start with completely cold caches.

To solve this problem, we uses Redis as a centralized cache layer.


Redis as a Shared Cache Layer

Redis plays a critical role in our architecture.

Instead of storing cache data inside application containers, all replicas communicate with a centralized Redis instance.

Pod A ─┐
Pod B ─┼──► Redis
Pod C ─┤
Pod D ─┘

This provides several advantages:

  • Shared cache across all replicas
  • Consistent session state
  • Improved cache hit ratios
  • Reduced database load
  • Faster autoscaling

Because every instance uses the same Redis backend, newly created pods immediately benefit from existing cache entries.

This eliminates many of the cold-cache issues commonly associated with aggressive horizontal scaling.

Redis is deployed on dedicated infrastructure to ensure predictable latency and isolate cache workloads from application traffic.


Health Checks and Reliability

Every service exposes a dedicated health endpoint.

livenessProbe:
  httpGet:
    path: /api/health
    port: 3000

readinessProbe:
  httpGet:
    path: /api/health
    port: 3000

Readiness probes ensure traffic is only routed to fully initialized containers.

Liveness probes allow Kubernetes to automatically restart unhealthy workloads.

Combined with rolling deployments, this dramatically improves service reliability.


Zero-Downtime Deployments

All services are deployed using Kubernetes Rolling Updates.

strategy:
  type: RollingUpdate

  rollingUpdate:
    maxSurge: 1
    maxUnavailable: 0

This configuration guarantees that existing instances remain available while new versions are deployed.

Users continue to be served throughout the deployment process without interruption.

This has become one of the most valuable operational features of our infrastructure.


nginx-ingress as the Platform Gateway

All external traffic enters the cluster through nginx-ingress.

A typical ingress configuration looks like:

spec:
  ingressClassName: nginx

  rules:
    - host: api.seelen.io
      http:
        paths:
          - path: /
            pathType: Prefix

nginx-ingress provides:

  • Request routing
  • Load balancing
  • TLS termination
  • Service discovery abstraction
  • Centralized traffic management

Adding a new service typically requires only:

  1. Deploying the application
  2. Creating a Service
  3. Creating an Ingress resource
  4. Creating a DNS record

No additional load balancers need to be provisioned manually.


Automated HTTPS with cert-manager

Managing certificates manually becomes increasingly difficult as infrastructure grows.

To automate TLS management, we use cert-manager integrated with Let's Encrypt.

annotations:
  cert-manager.io/cluster-issuer: letsencrypt-issuer

Whenever a new service is deployed:

  • A certificate is requested automatically
  • Domain validation is performed
  • The certificate is stored as a Kubernetes Secret
  • Renewals occur automatically

This ensures HTTPS is enabled by default across the platform with virtually zero operational overhead.


Managed MongoDB

Persistent data is stored using DigitalOcean Managed MongoDB.

We maintain separate environments for production and staging.

Production

Stores:

  • User accounts
  • Synchronization data
  • User settings
  • Licensing information
  • Analytics metadata

Staging

Used for:

  • Release validation
  • Integration testing
  • Database migration testing

Maintaining separate environments significantly reduces deployment risk.


Continuous Delivery Pipeline

All deployments originate from GitHub.

Git Push
   ↓
GitHub Actions
   ↓
Docker Build
   ↓
DigitalOcean Container Registry
   ↓
Kubernetes Deployment
   ↓
Rolling Update

Every service is packaged into immutable container images.

This provides:

  • Consistent deployments
  • Version traceability
  • Rollback support
  • Reproducible environments

The entire process is automated through CI/CD pipelines.


Object Storage

Static content and large assets are stored using DigitalOcean Spaces.

Examples include:

  • Application downloads
  • Release artifacts
  • User-generated content
  • Static assets

This keeps application containers lightweight while improving scalability.


Looking Ahead

The current architecture was built to support continued growth.

As Seelen UI approaches the development of Version 3, the project is expected to expand beyond Windows and introduce Linux support, with potential macOS support in the future.

Moving toward a cross-platform ecosystem will increase both infrastructure requirements and architectural complexity.

Fortunately, the cloud-native foundation built on DigitalOcean already provides the scalability, automation, and operational flexibility needed to support that next phase.


Conclusion

DigitalOcean has enabled Seelen UI to evolve from a desktop customization project into a platform serving tens of thousands of users every day.

By combining Kubernetes, Horizontal Pod Autoscaling, Redis, Managed MongoDB, nginx-ingress, cert-manager, Spaces, and automated CI/CD pipelines, we have built an infrastructure that remains reliable, scalable, and relatively simple to operate.

As the project continues to grow and expand across platforms, this architecture provides the foundation needed to support the next generation of Seelen UI.