redisctl
A unified command-line interface for managing Redis deployments across Cloud and Enterprise.
Overview
redisctl
is a comprehensive CLI and Rust library that unifies management of both Redis Cloud and Redis Enterprise deployments. It automatically detects which API to use based on your configuration profile or explicit command selection, providing a consistent interface for all Redis management tasks.
Features
Core Capabilities
- Unified Interface - Single CLI for both Redis Cloud and Enterprise
- Smart Command Routing - Automatically routes commands based on deployment type
- Profile Management - Save and switch between multiple Redis deployments
- Multiple Output Formats - JSON, YAML, and Table output with JMESPath queries
- Type-Safe Rust Libraries - Build custom tools with our async Rust client libraries
- Comprehensive API Coverage - Full implementation of both Cloud and Enterprise REST APIs
Advanced Features
- Cluster Initialization - Bootstrap and configure new Enterprise clusters
- Backup & Restore - Automated backup management and recovery
- VPC Peering & Transit Gateway - Complete networking management for Cloud
- ACL Management - Database access control and security rules
- Docker Integration - Easy local testing with Redis Enterprise
- Raw API Access - Direct access to any API endpoint
Installation
CLI Tool (Recommended for most users)
# Install the CLI tool
Rust Libraries (For developers building custom tools)
This project also provides comprehensive Rust client libraries for both Redis Cloud and Enterprise REST APIs:
# Add to your Cargo.toml
[]
= "0.1.0" # Full Redis Cloud REST API client
= "0.1.0" # Full Redis Enterprise REST API client
These libraries offer:
- 100% API coverage - Every documented endpoint implemented
- Full type safety - Strongly typed request/response structures
- Async/await - Modern async Rust with Tokio
- Builder patterns - Ergonomic client configuration
- Comprehensive testing - Battle-tested with 500+ tests
Perfect for building custom automation, integrations, or management tools.
From Source
# Clone and build
# Install to PATH
# Or use the binary directly
Platform-Specific Binaries
# Build Cloud-only binary (smaller size)
# Build Enterprise-only binary (smaller size)
# Build unified binary (default, includes both)
Using Docker Hub Image
The official Docker images are available on Docker Hub at joshrotenberg/redisctl:
Available Tags
latest
- Latest stable releasev0.1.0
,v0.2.0
, etc. - Specific version tagsmain
- Latest development build from main branch
# Pull the latest image
# Or pull a specific version
# Run a command directly
# Use with environment variables for Redis Cloud
# Use with environment variables for Redis Enterprise
# Run interactively with a shell
Local Development with Docker Compose
# Start Redis Enterprise cluster with initialization
# Check cluster status
# Watch logs
# Clean up
Quick Start
1. Configure Authentication
Option 1: Interactive Setup Wizard (Recommended)
# Launch guided setup for any deployment type
# Test your authentication
The interactive setup wizard will:
- Guide you through credential collection
- Test authentication during setup
- Create and save working profiles
- Set up your first profile as default
Option 2: Manual Profile Creation
Redis Cloud
# Create a Cloud profile manually
# Set as default profile
Redis Enterprise
# Create an Enterprise profile manually
Option 3: Environment Variables
# Redis Cloud
# Redis Enterprise
# Test authentication works
2. Verify Your Setup
# Test authentication for any profile or environment vars
# View your configuration
# Validate all profiles
# Find your config file location
3. Basic Usage
# List all profiles
# Set default profile
# Explicit deployment commands
# Smart routing (auto-detects based on profile)
# Query and format output
|
4. Common Workflows
# Initialize a new Enterprise cluster
# Create a database
# Cloud-specific workflows
# Enterprise workflows
Architecture
Workspace Structure
redisctl/
├── crates/
│ ├── redis-cloud/ # Cloud API client library
│ ├── redis-enterprise/ # Enterprise API client library
│ └── redisctl/ # Unified CLI application
├── docs/ # Documentation (mdBook)
├── tests/ # Integration tests
└── examples/ # Usage examples
Key Components
Libraries
-
redis-cloud - Complete Redis Cloud REST API client
- All Cloud API endpoints implemented
- Async/await with Tokio
- Full type safety with Rust
-
redis-enterprise - Complete Redis Enterprise REST API client
- All Enterprise API endpoints implemented
- Support for cluster management, CRDB, modules
- Bootstrap and initialization workflows
CLI Application
- redisctl - Unified command-line interface
- Smart command routing
- Profile-based configuration
- High-level workflows
- Interactive mode (planned)
Development
Building
# Run tests
# Run with all features
# Check formatting
# Run clippy
Documentation
# Build documentation
&&
# Serve documentation locally
&&
# Generate API docs
# Pre-commit hooks (recommended)
Contributing
Please see our Contributing Guide for details on:
- Code style and standards
- Testing requirements
- Pull request process
- Issue reporting
API Coverage
Redis Cloud API (95%+ Coverage)
- ✅ Core Operations: Subscriptions, Databases, Users, Payment Methods
- ✅ Security: ACLs, API Keys, Redis Rules, SSO/SAML Integration
- ✅ Networking: VPC Peering, Transit Gateway, Private Service Connect
- ✅ Data Management: Backup/Restore, Import/Export, Active-Active (CRDB)
- ✅ Monitoring: Metrics, Logs, Tasks, Alerts
- ✅ Cloud Integration: AWS, GCP, Azure Cloud Accounts
- ✅ Billing: Invoices, Payment Methods, Cost Analysis
- ✅ 21 Handler Modules with 200+ API endpoints implemented
Redis Enterprise API (100% Coverage)
- ✅ Cluster Operations: Bootstrap, Join, Management, Recovery
- ✅ Database Management: Full BDB lifecycle, Actions, Stats, Shards
- ✅ Security: Users, Roles, LDAP, Redis ACLs, OCSP
- ✅ Active-Active: CRDB management, Tasks, Multi-region
- ✅ Monitoring: Alerts, Stats, Logs, Diagnostics
- ✅ Advanced Features: Modules, Proxies, Services, Migrations
- ✅ 29 Handler Modules covering all documented REST API endpoints
Roadmap
See our GitHub Issues for the complete roadmap.
✅ Phase 1 - Raw API Access (Complete)
- Redis Cloud API coverage (95%+)
- Redis Enterprise API coverage (100%)
- Comprehensive test suite (500+ tests)
- CI/CD automation with pre-commit hooks
- Published to crates.io as v0.1.0
✅ Phase 2 - Human-Friendly Commands (Complete)
- Enhanced command interface with smart routing
- Consistent --force flags and output formatting
- JMESPath queries and multiple output formats
- Major Cloud API categories now supported
🚧 Phase 3 - Workflow Commands (In Progress)
- High-level operations for complex multi-step tasks
- Migration tools (Cloud ↔ Enterprise)
- Cluster initialization workflows
- Disaster recovery automation
🔮 Phase 4 - Advanced Features (Planned)
- Interactive TUI mode
- Plugin system
- Terraform provider integration
- Kubernetes operator
Rust Library Usage
For developers who want to build their own tools, our libraries provide complete, type-safe access to Redis Cloud and Enterprise APIs:
Add to your Cargo.toml
:
[]
= "0.1.0" # For Cloud API
= "0.1.0" # For Enterprise API
Quick Example
use CloudClient;
use EnterpriseClient;
async
Library Features
- Comprehensive handlers for all API endpoints (subscriptions, databases, users, ACLs, etc.)
- Builder patterns for complex request construction
- Error handling with detailed context and retry logic
- Both typed and untyped responses (use
.raw()
methods forserde_json::Value
) - Extensive documentation on docs.rs and docs.rs
Support
- Issues: GitHub Issues
- Documentation: docs.rs/redisctl
- Examples: See the examples/ directory
- Crates.io: crates.io/crates/redisctl
License
Licensed under either of:
- Apache License, Version 2.0 (LICENSE-APACHE or http://www.apache.org/licenses/LICENSE-2.0)
- MIT license (LICENSE-MIT or http://opensource.org/licenses/MIT)
at your option.
Contribution
Unless you explicitly state otherwise, any contribution intentionally submitted for inclusion in the work by you, as defined in the Apache-2.0 license, shall be dual licensed as above, without any additional terms or conditions.