drown-cli
CLI tool for managing apps on Drown Platform - a self-hosted PaaS (Platform as a Service).
Deploy and manage containerized applications with simple commands, similar to Heroku CLI but for your own infrastructure.
Installation
pip install drown
Quick Start
# Login to your Drown Platform instance
# This also automatically sets up SSH keys for git push
drown login
# List your apps
drown apps
# Create a new app
drown create my-app
# Deploy your code (works automatically after login)
git push platform main
# Scale your app
drown scale my-app 3
# View logs
drown logs my-app
# Check metrics
drown metrics my-app
# Logout
drown logout
Commands
drown login
Authenticate with your Drown Platform instance. You'll be prompted for your username and password.
drown login
What happens during login:
- Authenticates with the platform API
- Generates an SSH key pair (if not already present) at
~/.drown/id_ed25519 - Registers the public key with the platform
- Updates
~/.ssh/configto use the key automatically for git operations - Saves credentials to
~/.drown/config.json
After a successful login, git push platform main works automatically with no additional SSH configuration needed.
Note: Requires OpenSSH or Git for Windows to be installed (for ssh-keygen).
drown logout
Remove saved credentials.
drown logout
drown apps
List all your deployed applications.
drown apps
Output:
NAME DOMAIN STATUS REPLICAS
my-app my-app.dr0wn.duckdns.org running 3
web-frontend web.dr0wn.duckdns.org running 1
drown create <app-name>
Create a new application.
drown create my-new-app
If run from a git repository, automatically adds a platform git remote using the SSH host alias configured during login. Then deploy with:
git push platform main
The SSH key setup from drown login ensures this works seamlessly without any manual SSH configuration.
drown scale <app-name> <count>
Scale the number of replicas for an application.
drown scale my-app 5
drown logs <app-name>
View application logs.
drown logs my-app
drown metrics <app-name>
View resource usage metrics (CPU, memory) for all replicas.
drown metrics my-app
Output:
REPLICA PORT STATUS CPU MEMORY
0 8001 running 2.1% 64MiB
1 8002 running 1.8% 62MiB
2 8003 running 2.4% 65MiB
Configuration
SSH Keys
The CLI automatically manages SSH keys for git operations:
- Private key:
~/.drown/id_ed25519 - Public key:
~/.drown/id_ed25519.pub - SSH config:
~/.ssh/config(automatically updated withHost drown-platformentry)
These are set up during drown login and registered with your platform account. The keys are ed25519 format with no passphrase for non-interactive git operations.
API URL
By default, the CLI connects to https://dashboard.dr0wn.duckdns.org.
To use a custom instance, set the DROWN_API_URL environment variable:
export DROWN_API_URL=https://your-instance.com
drown login
Config File
Authentication token and user info are stored in ~/.drown/config.json:
{
"token": "your-jwt-token",
"username": "your-username",
"api_base": "https://dashboard.dr0wn.duckdns.org"
}
Windows users: ~ resolves to C:\Users\<YourUsername>\, so config files are stored at:
C:\Users\<YourUsername>\.drown\config.jsonC:\Users\<YourUsername>\.drown\id_ed25519C:\Users\<YourUsername>\.ssh\config
Requirements
- Python 3.7+
- OpenSSH or Git for Windows (for SSH key generation and git operations)
- Git (optional, for
drown createauto-remote feature and deployment)
Development
git clone https://github.com/drownplatform/drown-cli.git
cd drown-cli
pip install -e .
License
MIT License - see LICENSE file for details.
Links
- Platform: dashboard.dr0wn.duckdns.org
- GitHub: github.com/drownplatform/drown-cli
- PyPI: pypi.org/project/drown-cli
Support
For issues or questions, please open an issue on GitHub.
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file drown-0.2.5.tar.gz.
File metadata
- Download URL: drown-0.2.5.tar.gz
- Upload date:
- Size: 12.1 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.10.6
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
18cef8d0fa3a91f25db7eec8ee61012f2016827a165f46a9cfdcdf55d8591a69
|
|
| MD5 |
074537f94b39c76c0ebdb9ef980858ed
|
|
| BLAKE2b-256 |
2ded8786a880108d84fe8442267aa7feb7e1e224ce4ae094189e5c2abad25a17
|
File details
Details for the file drown-0.2.5-py3-none-any.whl.
File metadata
- Download URL: drown-0.2.5-py3-none-any.whl
- Upload date:
- Size: 11.2 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.10.6
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
0014e1551829fc4ba7450da634a2145dcdd5a0d074e5b1379b85f74ec9ce7c5d
|
|
| MD5 |
11ebd24c417722bcfbb42deebe4b476e
|
|
| BLAKE2b-256 |
fd766a0a07d14c20509b5b6d2254359621df205d8c2c0797eb62e68b7e9ba2f1
|