HOW-TO · SUP

How to deploy a production-grade PD like Hyperspace

advanced45 minBy Fredoline Eruo
Target environment
Ubuntu 24.04 · Ollama 0.4.x
PREREQUISITES

Docker, domain name, cloud or local server

What this does

Deploying a production-grade personal dashboard (PD) akin to Hyperspace provides a unified web interface for managing AI agents, monitoring inference workloads, and controlling deployed services. The deployment uses Docker Compose for container orchestration, Nginx as a reverse proxy, and Let's Encrypt for TLS certificates. The result is a secure, publicly accessible dashboard with authentication, persistent storage, and health monitoring.

Steps

Begin by cloning the repository: git clone https://github.com/example/hyperspace-pd && cd hyperspace-pd. Configure environment variables in .env—set DOMAIN=your-domain.com, [email protected], and generate a secure JWT_SECRET using openssl rand -hex 32. Review docker-compose.yml and adjust resource limits for the AI backend container. Start services with docker compose up -d. Run the TLS certificate generation script: ./scripts/setup-ssl.sh which uses Certbot to obtain Let's Encrypt certificates. Configure Nginx by copying nginx.conf.template to /etc/nginx/sites-available/hyperspace, symlinking it to sites-enabled, then reloading with nginx -t && systemctl reload nginx. Finally, run database migrations with docker compose exec api ./migrate.sh.

  • Record the local run evidence. Save the exact command, runtime or package version, model name if applicable, and observed output so the result can be reproduced later.

  • Confirm the local starting state. Print the active binary, package version, model name, or configuration path before changing the workflow.

  • Run the smallest complete path. Execute the minimum command or script that proves the guide works end to end on the local machine.

  • Compare against expected output. Check the final line, status code, generated artifact, or model response against the verification section before expanding the setup.

  • Record the local run evidence. Save the exact command, runtime or package version, model name if applicable, and observed output so the result can be reproduced later.

Verification

Navigate to https://your-domain.com and confirm the login page loads over HTTPS. Register an admin account and log in—the dashboard grid with CPU, memory, and inference widgets should render. Run docker compose ps and confirm all services show "healthy" status. Check SSL validity with curl -vI https://your-domain.com 2>&1 | grep "expire date". Test the health endpoint with curl https://your-domain.com/api/health which should return {"status":"ok","uptime":<seconds>}.

Common failures

Nginx 502 Bad Gateway: Verify the upstream API container is running with docker compose logs api and check port mappings in docker-compose.yml. SSL certificate not issued: Confirm port 80 is reachable with nc -zv your-domain.com 80 and check DNS propagation with dig your-domain.com. Database connection refused: Check that the database container is healthy with docker compose ps db and verify DATABASE_URL in .env. Docker daemon not running: Start it with sudo systemctl start docker and enable with sudo systemctl enable docker. Memory exhaustion: Reduce model workers in .env by setting MAX_WORKERS=1 and restart with docker compose restart api.

  • Version mismatch - The installed package or runtime differs from the command shown; check the version first and rerun the smallest verification command.
  • Local environment drift - Another service, virtual environment, model, or path is being used; print the active binary path and configuration before changing the guide steps.

Related guides

  • deploy-ai-kubernetes-gpu-nodes
  • setup-auto-scaling-llm-inference
  • build-multi-tenant-ai-serving