Skip to content

Environment Variables

Environment variables for configuring RemoteJuggler.

Configuration Variables

NO_COLOR

Disable colored output (follows no-color.org standard).

export NO_COLOR=1

CLI Configuration Flags

These are Chapel config const flags set via the command line, not environment variables:

remote-juggler --configPath=/path/to/config.json list   # Override config path
remote-juggler --verbose status                         # Enable debug output

Binary Path Overrides

Override paths to external tool binaries:

Variable Default Description
REMOTE_JUGGLER_KDBX_PATH ~/.remotejuggler/keys.kdbx KeePassXC database path
REMOTE_JUGGLER_YKMAN_PATH ykman YubiKey Manager binary
REMOTE_JUGGLER_SOPS_PATH sops Mozilla SOPS binary
REMOTE_JUGGLER_AGE_PATH age age encryption binary
REMOTE_JUGGLER_AGE_KEYGEN_PATH age-keygen age key generation binary

Token Variables

Provider-Specific Tokens

Variable Provider Description
GITLAB_TOKEN GitLab GitLab personal access token
GITHUB_TOKEN GitHub GitHub personal access token
BITBUCKET_TOKEN Bitbucket Bitbucket app password

Identity-Specific Tokens

Configure per-identity tokens via tokenEnvVar in config:

{
  "identities": {
    "work": {
      "tokenEnvVar": "GITLAB_WORK_TOKEN"
    }
  }
}

Then set:

export GITLAB_WORK_TOKEN="glpat-xxxxxxxxxxxx"

Credential Resolution Order

RemoteJuggler resolves credentials in this order:

  1. KeePassXC Store (if ~/.remotejuggler/keys.kdbx exists and is unlockable)
  2. macOS Keychain (if useKeychain: true and on macOS)
  3. Identity-specific environment variable (if tokenEnvVar configured)
  4. Provider environment variable (GITLAB_TOKEN, etc.)
  5. CLI authentication (glab/gh stored credentials)
  6. SSH-only mode (if fallbackToSSH: true)

Shell Configuration

Bash

Add to ~/.bashrc:

# RemoteJuggler configuration
export PATH="$PATH:$HOME/.local/bin"

# Optional: Per-identity tokens
export GITLAB_WORK_TOKEN="glpat-work-token"
export GITLAB_PERSONAL_TOKEN="glpat-personal-token"
export GITHUB_TOKEN="ghp-github-token"

# Optional: Verbose mode
# export REMOTE_JUGGLER_VERBOSE=1

Zsh

Add to ~/.zshrc:

# RemoteJuggler configuration
path+=("$HOME/.local/bin")

# Optional: Per-identity tokens
export GITLAB_WORK_TOKEN="glpat-work-token"
export GITLAB_PERSONAL_TOKEN="glpat-personal-token"
export GITHUB_TOKEN="ghp-github-token"

Fish

Add to ~/.config/fish/config.fish:

# RemoteJuggler configuration
fish_add_path ~/.local/bin

# Optional: Per-identity tokens
set -gx GITLAB_WORK_TOKEN "glpat-work-token"
set -gx GITLAB_PERSONAL_TOKEN "glpat-personal-token"
set -gx GITHUB_TOKEN "ghp-github-token"

CI/CD Variables

GitLab CI

Set as protected/masked variables:

variables:
  GITLAB_TOKEN: $CI_JOB_TOKEN  # Built-in
  # Or use custom variable from CI/CD settings

GitHub Actions

Set as repository secrets:

env:
  GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

MCP Server Environment

When running as MCP server, environment is inherited from parent process.

Claude Code

Ensure variables are set before starting Claude Code:

export GITLAB_TOKEN="glpat-xxxx"
code .

JetBrains

Configure in acp.json:

{
  "agent_servers": {
    "RemoteJuggler": {
      "command": "remote-juggler",
      "args": ["--mode=acp"],
      "env": {
        "REMOTE_JUGGLER_VERBOSE": "1"
      }
    }
  }
}

XDG Base Directory

RemoteJuggler follows XDG Base Directory specification:

Variable Default Usage
XDG_CONFIG_HOME ~/.config Configuration directory

Configuration path:

${XDG_CONFIG_HOME:-$HOME/.config}/remote-juggler/config.json

Debugging

List Relevant Variables

env | grep -E 'REMOTE_JUGGLER|GITLAB|GITHUB|BITBUCKET|XDG'

Test Token Availability

# Check if token is set
[ -n "$GITLAB_TOKEN" ] && echo "GITLAB_TOKEN is set" || echo "GITLAB_TOKEN not set"

Verify Credential Resolution

remote-juggler --verbose token verify

Shows which credential source is used for each identity.