Providers

Zerops

Deploy Nitro apps to Zerops.

Preset: zerops

Read more in zerops.io.
🚧 This preset is currently experimental.

Zerops supports deploying both static and server-side rendered apps with a simple configuration file in your project root.

Starter templates

If you want to quckly get started with zerops and nitro you can use repositories zeropsio/recipe-nitro-nodejs and zeropsio/recipe-nitro-static starter templates.

Project setup

Projects and services can be added either through project add wizard or imported using zerops-project-import.yml.

project:
  name: nitro-app

services:
  - hostname: app
    type: nodejs@20

Then create a zerops.yml config in your project root:

zerops:
  - setup: app
    build:
      base: nodejs@20
      envVariables:
        SERVER_PRESET: zerops
      buildCommands:
        - pnpm i
        - pnpm run build
      deployFiles:
        - .output
        - package.json
        - node_modules
    run:
      base: nodejs@20
      ports:
        - port: 3000
          httpSupport: true
      start: node .output/server/index.mjs

Now you can trigger the build & deploy pipeline using the Zerops CLI or by connecting the app service with your GitHub / GitLab repository from inside the service detail.

Build and deploy

Open Settings > Access Token Management in the Zerops app and generate a new access token.

Log in using your access token with the following command:

npx @zerops/zcli login <token>

Navigate to the root of your app (where zerops.yml is located) and run the following command to trigger the deploy:

npx @zerops/zcli push

Your code can be deployed automatically on each commit or a new tag by connecting the service with your GitHub / GitLab repository. This connection can be set up in the service detail.

Read more in Zerops Documentation.