Architecture Blueprint & Implementation Guide
Containerised delivery on a VPS
B2B application hosting
Overview
A DevOps infrastructure guide capturing an engineering pattern when an application requires reproducible environments, automated health checks, and verified recovery procedures.
Operational challenge
Production was a VM with files changed over SSH. Staging did not match production. TLS renewal was a calendar event. Backups existed as a zip in someone’s cloud drive. A dependency update required tribal knowledge.
Technical complexity
The application had local file uploads and a database that had never been restored. DNS and email were entangled with the same host. Downtime windows were short because staff used the app during business hours.
Requirements
- Repeatable Docker Compose stack for app, worker, and database
- Separate staging with anonymised data
- Automated TLS
- Off-site encrypted database backups and a restore drill
- Deploy from git via CI, with a rollback tag
Architectural solution
Package the application, put a reverse proxy in front, move secrets to environment files that are not in git, and make backups a tested job. Keep the same VPS if it is sufficient; do not migrate to a maze of managed services without a reason.
Component breakdown
01
Edge
Reverse proxy terminates TLS and routes to the app container. Health checks fail closed.
02
Runtime
App and worker containers share an internal network. The database has a named volume and a backup sidecar or host job.
03
Delivery
CI builds images, SSHs or uses a registry, and runs compose pull/up. Previous images remain until rollback is confirmed.
Technology stack
- Linux
- Docker Compose
- Nginx
- GitHub Actions or equivalent
- Off-site object storage
Implementation phases
- Photograph the current VM: cron, nginx, env files, disk usage
- Compose the app locally until tests pass
- Stand up staging on a second VM or namespace
- Restore a backup into staging before touching production
- Cut over DNS with a documented rollback
Expected production outcome
The operational objective is achieved when any engineer can trigger zero-downtime deploys and execute a full database restore in minutes with documented runbooks.
Related articles
Related tools
Related services
Next step
Planning a similar system architecture?
Discuss your technical constraints, throughput requirements, and integration dependencies with our engineering team.
