> **New in 2026 — Managed VPS hosting**: DeployHQ now offers [Managed VPS Hosting](https://www.deployhq.com/hosting/managed-vps) — fully-managed Linux servers with built-in CI/CD. AdonisJS runs cleanly on Managed VPS with the same Node + PM2 setup as the BYO walkthrough below, which remains fully supported.

**Prerequisites:**

-   A hosted server with Node.js and npm installed.
-   An AdonisJS project

**DeployHQ Setup**

**Create a Project:**

Sign up and log in to DeployHQ.
Go to **Projects** > **New Project**.
Follow the wizard to connect your project repository.

**Server Configuration:**

Go to **Servers** > **New Server**.
Choose a name and select **SSH** as the protocol.
Enter your server's IP address and username (usually `deployhq`).
Enable **Use SSH key rather than password for authentication?**.

On your server, run the following commands (replace `deployhq` with your username if different):

```bash
sudo adduser deployhq
sudo usermod -a -G www-data deployhq
su - deployhq
mkdir ~/.ssh
chmod 700 ~/.ssh
nano ~/.ssh/authorized_keys
```
Paste DeployHQ's public key into the `nano` editor. Save (`Ctrl+X`,  `Y`, then `Enter`).

Set permissions:
```bash
chmod 600 ~/.ssh/authorized_keys
```

Set the **Deployment Path** to your project's directory (e.g.,  `/var/www/your-adonis-app`).
Enable **Perform zero-downtime deployments on this server** (optional).
Set the **Environment** to `production` and enable **Automatically deploy**.
Save the server configuration.

**Config Files (Optional):**

Go to **Config Files** and add any sensitive files (e.g.,  `.env`) that you don't want in your repository.

**SSH Commands:**

Go to **SSH Commands** and add new commands:
- **Install Dependencies:**  `cd %path% && npm ci`
- **Build Application:**  `cd %path% && node ace build --production`
- **Start Application:**  `cd %path%/build && npm run start:prod` 
  (Or use PM2: `cd %path%/build && pm2 start server.js`)

**Additional AdonisJS-Specific Considerations:**

- Ensure you have a production-ready `start:prod` script in your `package.json`:

```json
{
  "scripts": {
    "start:prod": "node ace start --watch"
  }
}
```

- If using PM2, install it globally on your server:

```bash
npm install -g pm2
```

**Deployment**

-   Click **Deploy Project** in the header.
-   Select your server and deployment options.
-   Click **Deploy** to start the deployment process.

**Congratulations!** You've automated deployments for your AdonisJS project with DeployHQ.

**Key Differences from Express:**

- Uses `node ace build` for production build
- Specific AdonisJS build and start commands
- Slightly different dependency and start process

**Notes:**

- Ensure your `.env.production` file is properly configured
- Use AdonisJS's built-in environment management
- Consider using PM2 for process management in production

If you've got any other projects you'd like to automate deployments for, we've written lots of [guides for deploying the most popular application frameworks and content management systems](/guides).