Skip to main content

Requirements

  • Node.js installed locally (for development)
  • Account on Vertra Cloud
  • package.json file at project root

Project Structure

my-project/
├── src/
│   └── index.js
├── package.json
└── vertracloud.config  (optional)

Configuration

package.json

Make sure package.json has a start script defined:
{
  "name": "my-project",
  "version": "1.0.0",
  "main": "src/index.js",
  "scripts": {
    "start": "node src/index.js"
  },
  "dependencies": {
    // your dependencies
  }
}
The platform automatically runs npm install before starting your application. Do not include node_modules in the upload.

vertracloud.config (Optional)

MAIN=src/index.js
START=npm start
VERSION=recommended

Example: Simple HTTP Server

const http = require('http');

const port = process.env.PORT || 80;

const server = http.createServer((req, res) => {
  res.writeHead(200, { 'Content-Type': 'application/json' });
  res.end(JSON.stringify({ message: 'Hello from Vertra Cloud!' }));
});

server.listen(port, '0.0.0.0', () => {
  console.log(`Server running on port ${port}`);
});

Deploy

  1. Exclude node_modules and package-lock.json from the project
  2. Compress the project into a ZIP file
  3. Access Dashboard → New Project → Application
  4. Select “ZIP Upload” and drag the file
  5. Configure memory, Node.js version and subdomain
  6. Click “Create Application”

Available Versions

VersionStatusDescription
24.5.0LatestNode.js 24.5.0 (latest version)
22.18.0RecommendedNode.js 22.18.0 LTS (recommended for production)
20.18.0StableNode.js 20.18.0 with extended support

Notes

  • Dependencies are automatically installed via npm install
  • Environment variables can be configured in the dashboard or via API
  • Logs are available in real-time in the dashboard terminal
  • Auto-restart can be enabled to automatically restart on crash
  • Always listen on process.env.PORT and on host 0.0.0.0

Common Issues

Make sure all dependencies are listed in package.json. The platform only installs what is declared.
Your application might be trying to use a fixed port. Use process.env.PORT for the correct port.
Check the logs to identify the error. Syntax errors or missing dependencies are common causes. The crash loop detection system will pause auto-restart after 5 crashes in 10 minutes.