Deploy Strategies
DeployShip auto-detects your project type and selects the appropriate deploy strategy. You can override this in project settings.
SIMPLE (default for most projects)
DeployShip runs your build command, then starts or restarts your application using PM2. Suitable for Node.js, Python, PHP, Go, Ruby, and static frontends.
Auto-detection covers:
| Stack | Detected by | Build command | Start mechanism |
|---|---|---|---|
| Next.js | next.config.* | npm run build | PM2 + next binary |
| Vite / React | vite.config.* | npm run build | PM2 + built-in static server |
| CRA | public/index.html | npm run build | PM2 + built-in static server |
| Angular | angular.json | npm run build | PM2 + built-in static server |
| Express / Fastify / NestJS | package.json | npm run build | PM2 + npm start |
| Django | manage.py | pip install | Gunicorn |
| FastAPI | main.py | pip install | Uvicorn |
| Flask | app.py | pip install | Gunicorn |
| Laravel | artisan | composer install | artisan serve |
| Go | go.mod | go build | binary execution |
| Rust | Cargo.toml | cargo build | binary execution |
| Static HTML | index.html | — | PM2 + built-in static server |
COMPOSE
If your repository contains a docker-compose.yml file, DeployShip uses
Docker Compose to build and run all services. Dependencies like PostgreSQL,
Redis, or any other service defined in your compose file are managed
automatically by Docker.
# What DeployShip runs
docker compose build --no-cache
docker compose up -d --remove-orphans
Use this strategy if your project has external dependencies (database, cache, queue workers, etc.) that you want to manage alongside your app.
Note: For Compose projects, you declare the port your application
container exposes. DeployShip uses this port to configure the reverse proxy.
DeployShip does not inject PORT into Compose deployments.
SCRIPT
If your repository contains a deployship.sh file in the root, DeployShip
executes it directly. You have full control over the deploy process.
#!/bin/bash
set -e
git pull origin main
npm install
npm run build
pm2 restart myapp
Use this for complex setups, monorepos, or any case where the auto-detection does not cover your workflow.
Was this page helpful?