Deployment
Environments
| Env | Branch | URL | Purpose |
|---|---|---|---|
| Development | develop | https://dev.sellub.com | Active development, auto-deploys on merge |
| Staging | staging | https://staging.sellub.com | Pre-prod QA |
| Production | main | https://sellub.com | Live |
Storefronts (Netlify)
Each storefront app and the docs site is a separate Netlify site, auto-deploying on push.
| Site | Repo path | Production branch |
|---|---|---|
| Marketplace storefront | apps/sellub/sellub-storefront | main |
| Branded storefronts | (per-seller, dynamic) | main |
| Docs (this site) | apps/sellub-docs | develop for now, main when stable |
The Netlify config lives in each app’s netlify.toml.
Backend (self-hosted)
The Vendure server runs on a dedicated VM. See docs/SWARM-INFRASTRUCTURE-GUIDE.md and docs/VM-PROVISIONING-GUIDE.md.
Deploy steps (production)
Merge to main
PR from develop (or staging) to main after QA sign-off.
CI builds the image
GitHub Actions builds the Docker image and pushes to the registry.
Pull & restart on the prod VM
SSH to prod, run:
cd /opt/sellub
docker compose pull sellub-server sellub-worker
docker compose up -d sellub-server sellub-workerRun pending migrations
docker compose exec sellub-server pnpm migration:runSync admin config
If admins.json changed:
docker compose exec sellub-server pnpm sync-admins --env=productionSmoke test
https://dashboard.sellub.comloads and signs in.- A Shop API health query succeeds.
- A test order goes through end-to-end on a sandbox channel.
⚠️
Migrations are not auto-run. Always migration:run deliberately and have a rollback plan. Test on staging first.
Rollback
docker compose pull sellub-server:<previous-tag>
docker compose up -d sellub-serverFor migration rollback, use pnpm migration:revert — but prefer forward-fixes over reverts for any non-trivial change.
Secrets management
- Production secrets live in the VM’s
.env(root-owned, 600). - Rotate quarterly.
- Never commit secrets. CI uses GitHub Actions secrets.