VarisDocs
Dashboard

varis publish

Publish the services in your project to Varis with one command.

varis publish is the only command you need. It signs you in, sets up your project, builds your services, and publishes them.

Publish every service

From your project folder, run:

varis publish

The CLI does the following, skipping anything that's already done:

  1. Runs varis init, which signs you in, if the project has no varis.json.
  2. Runs varis build. If the build fails, it stops before it publishes anything.
  3. Publishes each service in varis.json, one at a time.

For each service, the CLI prints one of the following:

ResultMeaning
createdThe slug is new, and the service is now live.
updatedThe service existed, and Varis saved your changes.
unchangedNothing changed, so Varis did nothing.
An errorWhy Varis rejected the service. The CLI moves on to the next service, unless the error is with your sign-in, in which case it stops.

If any service fails, the CLI exits with a non-zero code.

Publish one service

To publish only one service, pass its slug:

varis publish convert-currency

This is the fastest way to republish a service after you fix it.

What publishing does to a service

Publishing replaces the whole service with what's in varis.json. If you remove a field from define, publishing resets it to its default. For more information, see Update a service.

Who publishes

Every publish records the owner the project belongs to and you, the person who's signed in. Publishing needs a signed-in person, so you can't publish from CI yet.

What's next