Build & Run Commands — Support Monorepos, Turborepo and Custom Setups

Skyversal lets you customize build and run commands for Next.js, Node.js, Nuxt, or custom Docker setups. Monorepo, Turborepo, and Nx support included.

Avg. Time
4 minutes
Support
All Frameworks
Extra Cost
No (Free)

What will you learn in this guide?

  • How to customize your project's compilation behavior in your CI/CD pipeline
  • How to start your application by defining custom run commands
  • Configuring scenarios like Next.js custom build command and Node.js production run script

Skyversal analyzes your project's source code to automatically configure the best build and run commands suited to its language. However, if you have a Laravel Octane deploy process or use a non-standard startup script, you can override the automatic detection and define your own custom commands.

🛠️ 1. Editing Custom Commands

Follow these steps sequentially to define custom build and run commands for your project:

Open Project
Settings
Build & Run
Enter Commands

🏗️ 2. What is a Build Command?

The build command is the compilation and preparation stage executed in an isolated container before your project is exposed to internet traffic. It is used to minify CSS/JS files, optimize source codes, or compile TypeScript files.

Framework / Library
Package Manager
Example Build Command
React / Vite
npm / pnpm
npm run build or pnpm run build
Vue / Nuxt
npm
npm run build
SvelteKit
npm
npm run build
Laravel (Modern Stack)
composer & npm
composer install --no-dev --prefer-dist --optimize-autoloader && npm install && npm run build
Angular
Angular CLI / npm
npm run build
💡 Tip: Multiple Commands (Pipeline)

You can execute multiple commands sequentially using the && operator. If the first command completes successfully, the next one automatically starts.

npm install --frozen-lockfile && npm run build

🚀 3. Run Command: Starting Long-running Processes

The run command is the main command that boots up your application after the build process finishes successfully, and it keeps running. As long as this command is active, your application provides uninterrupted service over our global network.

Framework / Environment
Technology
Example Run Command
Node.js (Express/NestJS)
npm / Bun
npm start or bun run start
Python (Flask / Django)
Gunicorn
gunicorn app:app or gunicorn core.wsgi
Laravel / PHP
Octane / Nginx
php artisan octane:start or Nginx + PHP-FPM
Go / Rust
Compiled Binary
./main or ./release/server

Crucial Warning: Port Binding

When your Run command executes, ensure it broadcasts over the 0.0.0.0 IP and uses the port Skyversal expects. Developers often bind to localhost or 127.0.0.1 and encounter "App not accessible" errors. The exact port your app needs to bind to is automatically passed by the system as the $PORT environment variable.

❓ 4. Common Problems and Solutions

❌ "Command not found" or "Script Missing" Error

Make sure the command you are using is defined under the `scripts` object in your project's `package.json` file. If you use pnpm or yarn, verify that your lock files are present in the repository.

❌ My application constantly falls into "Crashed" state

The command you entered in the Run field must start a long-running web server or process. One-off scripts are a common cause of this error. For example:

❌ Incorrect
php artisan migrate

The job finishes. The container closes and the system assumes the application crashed.

✅ Correct
npm start

Or gunicorn app:app. Runs continuously, listens for requests.

Remember: Re-deploy After Changes!

Simply clicking "Save" on your Build and Run commands does not instantly apply them. For the new commands to take effect in the live environment, you must navigate to the Deployments tab and click the Re-deploy button.

🎉 Everything is Ready!

You have fully customized your build and run behaviors. Your application will now compile and deploy entirely according to your rules.

In the next guide, you can learn how to monitor the outputs generated by your application in real-time while it is running in the background.

👉 Live Deploy Logs
Last updated on July 27, 2026
Edit this page on GitHub