deployship
Docs
Deploy Strategies

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:

StackDetected byBuild commandStart mechanism
Next.jsnext.config.*npm run buildPM2 + next binary
Vite / Reactvite.config.*npm run buildPM2 + built-in static server
CRApublic/index.htmlnpm run buildPM2 + built-in static server
Angularangular.jsonnpm run buildPM2 + built-in static server
Express / Fastify / NestJSpackage.jsonnpm run buildPM2 + npm start
Djangomanage.pypip installGunicorn
FastAPImain.pypip installUvicorn
Flaskapp.pypip installGunicorn
Laravelartisancomposer installartisan serve
Gogo.modgo buildbinary execution
RustCargo.tomlcargo buildbinary execution
Static HTMLindex.htmlPM2 + 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?