doctor

Diagnose configuration issues and verify your Redenv setup.

The doctor command runs a health check on your Redenv configuration to identify common issues.

Usage#

redenv doctor

What It Checks#

CheckDescription
Global configVerifies Upstash credentials exist and are valid
Redis connectionTests connectivity to your Upstash Redis database
Local project configChecks for redenv.config.ts in current directory
Project sync statusVerifies local environment exists in remote project

Example Output#

Healthy Setup#

$ redenv doctor

🩺 Running redenv doctor...
 Checking global configuration...
 Global config found at ~/.config/redenv/config.json
 Connecting to Redis...
 Redis connection successful
 Checking for local project configuration...
 Local project config found
  - Project: my-app
  - Environment: development
 Checking project sync status...
 Local environment is in sync with remote.

🩺 All checks passed! Your setup is looking healthy.

With Issues#

$ redenv doctor

🩺 Running redenv doctor...
 Checking global configuration...
 Global config not found at ~/.config/redenv/config.json
  Run `redenv setup` to create it.

🩺 Doctor finished with errors.

Common Issues#

IssueSolution
Global config not foundRun redenv setup to configure Upstash credentials
Redis connection failedCheck your Upstash URL and token in global config
Local config not foundRun redenv register <project> in your project directory
Environment not in syncThe local environment doesn't exist remotely yet

Info

Run redenv doctor after setup or when commands fail unexpectedly to quickly identify configuration issues.