Install the CLI

velixir is the canonical way to ship code to velixir. It packages your project source, uploads it to object storage, and waits while the platform builds it and rolls it out, all from a single command. There is no local build step: you do not need the .NET SDK, tar, or any language toolchain on your machine to deploy, because the CLI packs your source in-process and the build runs on the platform.

Install

The velixir CLI is a standalone, self-contained binary. On macOS or Linux, install it in one line, no toolchain required:

curl -fsSL https://velixir.net/install.sh | sh

That drops velixir into ~/.velixir/bin (add it to your PATH if the installer says so). Pin a version with VELIXIR_VERSION=2.0.5 before sh.

If you already have the .NET SDK, or you are on Windows, you can install it as a .NET global tool instead:

dotnet tool install --global Velixir.Cli

With the tool install, make sure ~/.dotnet/tools is on your PATH on macOS / Linux. On Windows the installer does this for you.

Check it worked with velixir version, which prints the installed version.

Sign in

velixir login

This opens your browser to approve the sign-in, then saves a key to ~/.velixir/config.json (readable only by you on macOS and Linux). On a machine without a browser, run velixir login --no-browser and paste a key, or pass one with velixir login --key <key>. In CI, set VELIXIR_API_KEY instead of logging in. Keys are covered on the API keys page.

To sign out, run velixir logout.

Common commands

Command What it does
velixir login / logout Sign in through your browser, or clear the saved key.
velixir apps List the apps your key's team can see, with their IDs.
velixir init Create an app for the current directory, or link an existing one with --app <id> (writes .velixir.json).
velixir deploy Package the current directory's source, upload it, build it on the platform, and deploy.
velixir deploy --slot staging Same, but to a specific deployment slot.
velixir status Show the current app's recent deployments per slot.
velixir templates List the starter templates.
velixir deploy --template <slug> Create an app from a template and deploy it (see Templates).
velixir db <sub> / velixir cache <sub> Create, list, connect to, bind, and delete managed Postgres and Valkey. Run velixir db for the sub-commands.
velixir volume <sub> Add, resize, snapshot and restore the app's volume (see Volumes).
velixir env <sub> List, set and unset environment variables, or import a .env file (see Environment variables).
velixir db connect <id> --external Print a database's public connection string, for psql, pg_dump and pg_restore from your machine.
velixir access-logs List the requests the app served; -f to follow them live (see Access logs).
velixir doctor Check your key, the API connection, and the detected project.
velixir version Print the installed version.

Flags worth knowing

  • --app <id> - Target an app by ID, overriding .velixir.json. An ID that isn't valid is an error, never skipped.
  • --source-dir <path> (-d) - Package source from a different directory instead of the current one.
  • --slot <name> - Deploy to a named slot (defaults to production).
  • --no-tail - Exit as soon as the deploy is queued instead of waiting for it to go healthy.

What gets uploaded

velixir deploy uploads everything in the source directory except dependency and build folders, which the platform rebuilds anyway: .git, node_modules, bin, obj, target, dist, build, vendor, .venv and venv, __pycache__, .next, .nuxt, .gradle, and editor folders like .idea and .vscode. It doesn't read .gitignore, so other files are included, dotfiles too. Keep secrets such as a local .env out of the folder you deploy, and set them as environment variables instead.

In CI

The CLI never asks questions when the CI variable is set or input isn't a terminal. A deploy with no app named stops with an error rather than creating one, and every failure exits non-zero, including a failed build or rollout. For GitHub Actions, see Deploying.

What about logs and rollback?

Streaming logs and rollback are in the dashboard, one click away in the app's tabs. Environment variables are in both: the dashboard's Environment tab, and velixir env.