Skip to content

Latest commit

 

History

History
160 lines (109 loc) · 4.18 KB

File metadata and controls

160 lines (109 loc) · 4.18 KB
title Installation
description How to install and set up the Sentry CLI

import PackageManagerCode from "../../components/PackageManagerCode.astro";

Installation

Install Script

Install the latest stable release:

curl https://cli.sentry.dev/install -fsS | bash

Install the nightly build (built from main, updated on every commit):

curl https://cli.sentry.dev/install -fsS | bash -s -- --version nightly

You can also use the SENTRY_VERSION environment variable to pin a version, which is especially useful in CI/CD pipelines and Dockerfiles:

# Pin to a specific stable version
SENTRY_VERSION=0.19.0 curl https://cli.sentry.dev/install -fsS | bash

# Pin to nightly
SENTRY_VERSION=nightly curl https://cli.sentry.dev/install -fsS | bash

The --version flag takes precedence over SENTRY_VERSION if both are set. The chosen channel is persisted so that sentry cli upgrade automatically tracks the same channel on future updates.

Install Script Options

The install script accepts these flags (passed after --):

# Skip PATH modification (e.g., in CI where PATH is managed externally)
curl https://cli.sentry.dev/install -fsS | bash -s -- --no-modify-path

# Skip shell completion installation
curl https://cli.sentry.dev/install -fsS | bash -s -- --no-completions

# Skip agent skill installation (for Claude Code, Cursor, etc.)
curl https://cli.sentry.dev/install -fsS | bash -s -- --no-agent-skills

Environment variables:

Variable Description
SENTRY_VERSION Pin version (e.g., 0.19.0) or channel (nightly)
SENTRY_INSTALL_DIR Override binary install directory (default: ~/.sentry/bin)
SENTRY_INIT Set to 1 to run sentry init after install

Supported Platforms

{/* GENERATED:START platform-support */}

OS Architectures Notes
macOS x64, arm64 (Apple Silicon)
Linux x64, arm64 glibc and musl (Alpine)
Windows x64 Via Git Bash, MSYS2, or WSL
{/* GENERATED:END platform-support */}

Homebrew

brew install getsentry/tools/sentry

Package Managers

Install globally with your preferred package manager:

Or run directly without installing:

Authentication

OAuth Device Flow (Recommended)

The easiest way to authenticate is via OAuth device flow:

sentry auth login

You'll be given a URL and a code to enter. Once you authorize the application in your browser, the CLI will automatically receive your token.

API Token

Alternatively, you can use an API token directly:

sentry auth login --token YOUR_SENTRY_API_TOKEN

You can create API tokens in your Sentry account settings.

Check Auth Status

Verify your authentication status:

sentry auth status

Logout

To remove stored credentials:

sentry auth logout

Self-Hosted Sentry

Using a self-hosted Sentry instance? Set SENTRY_URL to point at it:

SENTRY_URL=https://sentry.example.com sentry auth login

See the Self-Hosted guide for full setup details.

Configuration

Credentials are stored in a SQLite database at ~/.sentry/ with restricted file permissions (mode 600) for security. See Configuration for environment variables and customization options.

Next Steps

Once authenticated, you can start using the CLI: