Skip to content

Deployment

Overview of deployment procedures for the Sartiq platform.


Deployment Overview

Component Platform Method
Web Application Vercel Automatic (GitHub)
Backend API GCP Compute Engine Docker Compose
Compute Server GCP Compute Engine Docker Compose

Frontend Deployment (Vercel)

The web application is deployed automatically via Vercel.

Automatic Deployments

  • Preview deployments — Created for every pull request
  • Production deployments — Triggered on merge to main
  • Staging deployments — Triggered on merge to staging

Environment Configuration

Environment Branch URL
Preview PR branches *.vercel.app
Staging staging staging-app.sartiq.com
Production main app.sartiq.com

Backend & Compute Deployment (GCP)

Backend and Compute services are deployed via Docker Compose on GCP VMs. Container images are pulled from GitHub Container Registry (ghcr.io/shootify-io/).

Image Tags by Environment

Environment Backend Image Tag Compute Image Tag
Development dev dev
Staging staging staging
Production latest latest

Deployment Process

  1. Build — Docker image built in CI (GitHub Actions)
  2. Push — Image pushed to ghcr.io/shootify-io/
  3. Deploy — SSH into target VM, pull new image, restart services
  4. Verify — Health checks confirm successful deployment

Deploy Commands

# SSH into the target VM
ssh ubuntu@<vm-external-ip>

# Backend VM
cd /home/ubuntu/services/shootify-deploy
docker compose pull
docker compose up -d

# Compute VM
cd /home/ubuntu/services/shootify-deploy/compute
docker compose pull
docker compose up -d

Configuration files (.env, docker-compose.yml, Caddyfile) are symlinked from /data/config/ to the deploy path.

Staging → Production Promotion

flowchart LR
    Dev[Development] --> Staging
    Staging --> |"Manual promotion"| Production
  1. Deploy changes to Staging environment
  2. Verify functionality in Staging
  3. Manually promote to Production

Rollback Procedure

If issues are detected after deployment:

  1. Identify the previous working image tag/digest
  2. Pull and restart the previous container version
  3. Verify service health
  4. Investigate and fix the issue

Service URLs

Production

Service URL
Web App app.sartiq.com
Backend API api.sartiq.com
Compute API compute-api.sartiq.com

Staging

Service URL
Web App staging-app.sartiq.com
Backend API staging-api.sartiq.com
Compute API compute-api-staging.sartiq.com

Development

Service URL
Backend API dev-api.sartiq.com
Compute API compute-api-dev.sartiq.com

Health Checks

Each service exposes health check endpoints:

Service Endpoint Expected Response
Backend /api/v1/utils/health-check/ 200 OK
Compute /health 200 OK