Name | clidbs JSON |
Version |
4.26.0
JSON |
| download |
home_page | None |
Summary | A modern CLI tool for managing databases on VPS systems with SSL support |
upload_time | 2025-01-11 03:28:42 |
maintainer | None |
docs_url | None |
author | Andrew Wade |
requires_python | >=3.8 |
license | None |
keywords |
|
VCS |
|
bugtrack_url |
|
requirements |
No requirements were recorded.
|
Travis-CI |
No Travis.
|
coveralls test coverage |
No coveralls.
|
# CLIDB
> Tired of the database setup hassle? CLIDB is for developers who need instant databases for their projects. No more Docker compose files, no more configuration headaches - just one command and you're ready to code.
A powerful command-line tool for managing local development databases using Docker. Simplify your database management with features like automatic port allocation, backups, metrics monitoring, and more.
## Why CLIDB?
- 🚀 **Zero to Database in Seconds**
```bash
clidb create myproject-db
```
- 😌 **No More Setup Headaches**
- Forget about Docker compose files
- No manual port configuration
- Automatic credential management
- 💪 **Perfect for:**
- Rapid prototyping
- Multiple client projects
- Testing and development
- CI/CD environments
## Features
- 🗃️ **Multiple Database Support**
- PostgreSQL (versions 11-16)
- MySQL (8.0, 5.7)
- MariaDB (11.0, 10.11, 10.10)
- Redis (7.2, 7.0, 6.2)
- MongoDB (7.0, 6.0, 5.0)
- Neo4j (5, 4.4)
- 🔄 **Automatic Port Management**
- Smart port allocation for multiple instances
- Conflict resolution for occupied ports
- Public and private access modes
- 🔒 **Security Features**
- Automatic password generation
- SSL/TLS support with Let's Encrypt
- Secure credential storage
- 📊 **Monitoring & Metrics**
- Real-time performance monitoring
- CPU and memory usage
- Network and disk I/O stats
- Container health checks
- 💾 **Backup & Restore**
- Full database backups
- Point-in-time restoration
- Backup management with descriptions
- Automatic backup rotation
- 🔔 **Notifications**
- Discord integration
- Event notifications for:
- Database creation/deletion
- Start/stop events
- Backup operations
- Error alerts
## Prerequisites
- Python 3.8 or higher
- Docker (can be installed using `clidb install-docker`)
- pip (Python package installer)
## Installation
```bash
# Install using pip
pip install clidb
# Or install using pipx (recommended)
pipx install clidb
```
## Quick Start
```bash
# Install Docker if needed
clidb install-docker
# Create a PostgreSQL database
clidb create mydb --type postgres --version 16
# List all databases
clidb list
# View database info
clidb info mydb
```
## Usage Guide
### Database Management
```bash
# Create a database
clidb create mydb --type postgres --version 16
# Create with specific port and access
clidb create mydb --type mysql --port 3306 --access private
# List all databases
clidb list
# Get connection info
clidb info mydb
# Start/stop databases
clidb start mydb
clidb stop mydb
# Remove a database
clidb remove mydb
```
### Backup Operations
```bash
# Create a backup
clidb backup mydb --description "Pre-deployment backup"
# List all backups
clidb backups
# List backups for specific database
clidb backups --db mydb
# Restore from backup
clidb restore mydb 20240101_120000
# Delete old backup
clidb delete-backup mydb 20240101_120000
```
### Performance Monitoring
```bash
# View current metrics
clidb metrics mydb
# Watch metrics in real-time
clidb metrics mydb --watch
```
### SSL Configuration
```bash
# Setup SSL with automatic certificate
clidb ssl mydb example.com --email admin@example.com
# Remove SSL
clidb remove-ssl mydb example.com
# Verify domain configuration
clidb verify-domain example.com
```
### Discord Notifications
Enable notifications by providing a webhook URL:
```bash
# Via command line
clidb create mydb --discord-webhook "https://discord.com/api/webhooks/..."
# Or via environment variable
export CLIDB_DISCORD_WEBHOOK="https://discord.com/api/webhooks/..."
```
## Environment Variables
| Variable | Description | Default |
|----------|-------------|---------|
| `CLIDB_DISCORD_WEBHOOK` | Discord webhook URL for notifications | None |
| `CLIDB_HOST_IP` | Override auto-detected IP address | Auto-detected |
| `CLIDB_DEFAULT_DB` | Default database type | postgres |
| `CLIDB_DEFAULT_PORT` | Default starting port | Based on DB type |
## File Locations
- **Credentials**: `~/.config/clidb/credentials.json`
- **Backups**: `~/.config/clidb/backups/`
- **Backup Metadata**: `~/.config/clidb/backups/backup_metadata.json`
## Security Best Practices
1. **Access Control**
- Use private access mode for development
- Enable SSL for production environments
- Regularly rotate database passwords
2. **Backup Management**
- Regular backups with descriptive labels
- Test restore procedures periodically
- Keep backup metadata up to date
3. **SSL/TLS**
- Use valid email for Let's Encrypt notifications
- Keep certificates up to date
- Verify domain ownership before SSL setup
## Troubleshooting
1. **Port Conflicts**
- CLIDB automatically finds the next available port
- Use `--port` to specify a different port
- Check port availability with `netstat` or `lsof`
2. **Docker Issues**
- Run `clidb install-docker` to fix common problems
- Check Docker daemon status
- Verify user is in docker group
3. **Backup/Restore**
- Ensure sufficient disk space
- Check database connection before backup
- Verify backup file permissions
## Contributing
Contributions are welcome! Please feel free to submit a Pull Request. For major changes, please open an issue first to discuss what you would like to change.
## License
This project is licensed under the MIT License - see the LICENSE file for details.
## Support
- GitHub Issues: [Report a bug](https://github.com/awade12/clidbs/issues)
- Documentation: [Wiki](https://github.com/awade12/clidbs/wiki)
- Discussions: [Community](https://github.com/awade12/clidbs/discussions)
Raw data
{
"_id": null,
"home_page": null,
"name": "clidbs",
"maintainer": null,
"docs_url": null,
"requires_python": ">=3.8",
"maintainer_email": null,
"keywords": null,
"author": "Andrew Wade",
"author_email": null,
"download_url": "https://files.pythonhosted.org/packages/41/cc/df3a0fc19d1adcc1c142241985ac96982db02128f87538c3478b2cc34ee6/clidbs-4.26.0.tar.gz",
"platform": null,
"description": "# CLIDB\n\n> Tired of the database setup hassle? CLIDB is for developers who need instant databases for their projects. No more Docker compose files, no more configuration headaches - just one command and you're ready to code.\n\nA powerful command-line tool for managing local development databases using Docker. Simplify your database management with features like automatic port allocation, backups, metrics monitoring, and more.\n\n## Why CLIDB?\n\n- \ud83d\ude80 **Zero to Database in Seconds**\n ```bash\n clidb create myproject-db\n ```\n\n- \ud83d\ude0c **No More Setup Headaches**\n - Forget about Docker compose files\n - No manual port configuration\n - Automatic credential management\n\n- \ud83d\udcaa **Perfect for:**\n - Rapid prototyping\n - Multiple client projects\n - Testing and development\n - CI/CD environments\n\n## Features\n\n- \ud83d\uddc3\ufe0f **Multiple Database Support**\n - PostgreSQL (versions 11-16)\n - MySQL (8.0, 5.7)\n - MariaDB (11.0, 10.11, 10.10)\n - Redis (7.2, 7.0, 6.2)\n - MongoDB (7.0, 6.0, 5.0)\n - Neo4j (5, 4.4)\n\n- \ud83d\udd04 **Automatic Port Management**\n - Smart port allocation for multiple instances\n - Conflict resolution for occupied ports\n - Public and private access modes\n\n- \ud83d\udd12 **Security Features**\n - Automatic password generation\n - SSL/TLS support with Let's Encrypt\n - Secure credential storage\n\n- \ud83d\udcca **Monitoring & Metrics**\n - Real-time performance monitoring\n - CPU and memory usage\n - Network and disk I/O stats\n - Container health checks\n\n- \ud83d\udcbe **Backup & Restore**\n - Full database backups\n - Point-in-time restoration\n - Backup management with descriptions\n - Automatic backup rotation\n\n- \ud83d\udd14 **Notifications**\n - Discord integration\n - Event notifications for:\n - Database creation/deletion\n - Start/stop events\n - Backup operations\n - Error alerts\n\n## Prerequisites\n\n- Python 3.8 or higher\n- Docker (can be installed using `clidb install-docker`)\n- pip (Python package installer)\n\n## Installation\n\n```bash\n# Install using pip\npip install clidb\n\n# Or install using pipx (recommended)\npipx install clidb\n```\n\n## Quick Start\n\n```bash\n# Install Docker if needed\nclidb install-docker\n\n# Create a PostgreSQL database\nclidb create mydb --type postgres --version 16\n\n# List all databases\nclidb list\n\n# View database info\nclidb info mydb\n```\n\n## Usage Guide\n\n### Database Management\n\n```bash\n# Create a database\nclidb create mydb --type postgres --version 16\n\n# Create with specific port and access\nclidb create mydb --type mysql --port 3306 --access private\n\n# List all databases\nclidb list\n\n# Get connection info\nclidb info mydb\n\n# Start/stop databases\nclidb start mydb\nclidb stop mydb\n\n# Remove a database\nclidb remove mydb\n```\n\n### Backup Operations\n\n```bash\n# Create a backup\nclidb backup mydb --description \"Pre-deployment backup\"\n\n# List all backups\nclidb backups\n\n# List backups for specific database\nclidb backups --db mydb\n\n# Restore from backup\nclidb restore mydb 20240101_120000\n\n# Delete old backup\nclidb delete-backup mydb 20240101_120000\n```\n\n### Performance Monitoring\n\n```bash\n# View current metrics\nclidb metrics mydb\n\n# Watch metrics in real-time\nclidb metrics mydb --watch\n```\n\n### SSL Configuration\n\n```bash\n# Setup SSL with automatic certificate\nclidb ssl mydb example.com --email admin@example.com\n\n# Remove SSL\nclidb remove-ssl mydb example.com\n\n# Verify domain configuration\nclidb verify-domain example.com\n```\n\n### Discord Notifications\n\nEnable notifications by providing a webhook URL:\n\n```bash\n# Via command line\nclidb create mydb --discord-webhook \"https://discord.com/api/webhooks/...\"\n\n# Or via environment variable\nexport CLIDB_DISCORD_WEBHOOK=\"https://discord.com/api/webhooks/...\"\n```\n\n## Environment Variables\n\n| Variable | Description | Default |\n|----------|-------------|---------|\n| `CLIDB_DISCORD_WEBHOOK` | Discord webhook URL for notifications | None |\n| `CLIDB_HOST_IP` | Override auto-detected IP address | Auto-detected |\n| `CLIDB_DEFAULT_DB` | Default database type | postgres |\n| `CLIDB_DEFAULT_PORT` | Default starting port | Based on DB type |\n\n## File Locations\n\n- **Credentials**: `~/.config/clidb/credentials.json`\n- **Backups**: `~/.config/clidb/backups/`\n- **Backup Metadata**: `~/.config/clidb/backups/backup_metadata.json`\n\n## Security Best Practices\n\n1. **Access Control**\n - Use private access mode for development\n - Enable SSL for production environments\n - Regularly rotate database passwords\n\n2. **Backup Management**\n - Regular backups with descriptive labels\n - Test restore procedures periodically\n - Keep backup metadata up to date\n\n3. **SSL/TLS**\n - Use valid email for Let's Encrypt notifications\n - Keep certificates up to date\n - Verify domain ownership before SSL setup\n\n## Troubleshooting\n\n1. **Port Conflicts**\n - CLIDB automatically finds the next available port\n - Use `--port` to specify a different port\n - Check port availability with `netstat` or `lsof`\n\n2. **Docker Issues**\n - Run `clidb install-docker` to fix common problems\n - Check Docker daemon status\n - Verify user is in docker group\n\n3. **Backup/Restore**\n - Ensure sufficient disk space\n - Check database connection before backup\n - Verify backup file permissions\n\n## Contributing\n\nContributions are welcome! Please feel free to submit a Pull Request. For major changes, please open an issue first to discuss what you would like to change.\n\n## License\n\nThis project is licensed under the MIT License - see the LICENSE file for details.\n\n## Support\n\n- GitHub Issues: [Report a bug](https://github.com/awade12/clidbs/issues)\n- Documentation: [Wiki](https://github.com/awade12/clidbs/wiki)\n- Discussions: [Community](https://github.com/awade12/clidbs/discussions) ",
"bugtrack_url": null,
"license": null,
"summary": "A modern CLI tool for managing databases on VPS systems with SSL support",
"version": "4.26.0",
"project_urls": null,
"split_keywords": [],
"urls": [
{
"comment_text": "",
"digests": {
"blake2b_256": "4bb3a6d04ceb74271531c72effe96478463b041c117a00550c4eebd6a50ebaa6",
"md5": "6bc0aa6bafde0d5eea59a0ca2896a7b5",
"sha256": "747c4c99dccc6498b4002e387dc1b45a0d5210ace71dd49b7fa336446d3ddebc"
},
"downloads": -1,
"filename": "clidbs-4.26.0-py3-none-any.whl",
"has_sig": false,
"md5_digest": "6bc0aa6bafde0d5eea59a0ca2896a7b5",
"packagetype": "bdist_wheel",
"python_version": "py3",
"requires_python": ">=3.8",
"size": 40753,
"upload_time": "2025-01-11T03:28:41",
"upload_time_iso_8601": "2025-01-11T03:28:41.161457Z",
"url": "https://files.pythonhosted.org/packages/4b/b3/a6d04ceb74271531c72effe96478463b041c117a00550c4eebd6a50ebaa6/clidbs-4.26.0-py3-none-any.whl",
"yanked": false,
"yanked_reason": null
},
{
"comment_text": "",
"digests": {
"blake2b_256": "41ccdf3a0fc19d1adcc1c142241985ac96982db02128f87538c3478b2cc34ee6",
"md5": "eaf042b25f143ddaa0672cdb768375a2",
"sha256": "2d4d324838aeb8e417b10c1335f85031bf6f80c970904e759261f1874989d0b5"
},
"downloads": -1,
"filename": "clidbs-4.26.0.tar.gz",
"has_sig": false,
"md5_digest": "eaf042b25f143ddaa0672cdb768375a2",
"packagetype": "sdist",
"python_version": "source",
"requires_python": ">=3.8",
"size": 33642,
"upload_time": "2025-01-11T03:28:42",
"upload_time_iso_8601": "2025-01-11T03:28:42.514763Z",
"url": "https://files.pythonhosted.org/packages/41/cc/df3a0fc19d1adcc1c142241985ac96982db02128f87538c3478b2cc34ee6/clidbs-4.26.0.tar.gz",
"yanked": false,
"yanked_reason": null
}
],
"upload_time": "2025-01-11 03:28:42",
"github": false,
"gitlab": false,
"bitbucket": false,
"codeberg": false,
"lcname": "clidbs"
}