2025-08-18 03:14:49 +00:00
# @serve.zone/cli 🚀
2024-10-28 21:49:43 +01:00
2025-08-18 03:14:49 +00:00
**Command-line interface for Cloudly. ** Manage your multi-cloud infrastructure from the terminal with powerful, intuitive commands.
2024-10-28 21:49:43 +01:00
2025-08-18 03:14:49 +00:00
## 🎯 What is @serve.zone/cli?
2024-10-28 21:49:43 +01:00
2025-08-18 03:14:49 +00:00
The Cloudly CLI brings the full power of the Cloudly platform to your terminal. Whether you're automating deployments, managing secrets, or monitoring services, the CLI provides a streamlined interface for all your cloud operations.
## ✨ Features
- **⚡ Fast & Efficient** - Optimized for speed and minimal resource usage
- **🔐 Secure Authentication** - Token-based authentication with secure storage
- **📝 Intuitive Commands** - Clear, consistent command structure
- **🎨 Formatted Output** - Beautiful, readable output with color coding
- **🔄 Scriptable** - Perfect for CI/CD pipelines and automation
- **📊 Comprehensive** - Access to all Cloudly features from the terminal
## 🚀 Installation
### Global Installation (Recommended)
2024-10-28 21:49:43 +01:00
``` bash
2025-08-18 03:14:49 +00:00
pnpm add -g @serve.zone/cli
2024-10-28 21:49:43 +01:00
```
2025-08-18 03:14:49 +00:00
### Local Installation
``` bash
pnpm add @serve.zone/cli
```
## 🎬 Quick Start
``` bash
# Configure your Cloudly instance
servezone config --url https://cloudly.example.com
2024-10-28 21:49:43 +01:00
2025-08-18 03:14:49 +00:00
# Login with your service token
servezone login --token your-service-token
2024-10-28 21:49:43 +01:00
2025-08-18 03:14:49 +00:00
# List your clusters
servezone clusters list
2024-10-28 21:49:43 +01:00
2025-08-18 03:14:49 +00:00
# Deploy a service
servezone deploy --cluster production --image myapp:latest
```
2024-10-28 21:49:43 +01:00
2025-08-18 03:14:49 +00:00
## 🔑 Authentication
2024-10-28 21:49:43 +01:00
2025-08-18 03:14:49 +00:00
### Initial Setup
2024-10-28 21:49:43 +01:00
2025-08-18 03:14:49 +00:00
``` bash
# Set your Cloudly instance URL
servezone config --url https://cloudly.example.com
2024-10-28 21:49:43 +01:00
2025-08-18 03:14:49 +00:00
# Authenticate with a service token
servezone login --token YOUR_SERVICE_TOKEN
# Or use environment variables
export CLOUDLY_URL = https://cloudly.example.com
export CLOUDLY_TOKEN = YOUR_SERVICE_TOKEN
```
2024-10-28 21:49:43 +01:00
2025-08-18 03:14:49 +00:00
### Managing Profiles
2024-10-28 21:49:43 +01:00
2025-08-18 03:14:49 +00:00
``` bash
# Create a profile for different environments
servezone profile create production --url https://prod.cloudly.com
servezone profile create staging --url https://stage.cloudly.com
# Switch between profiles
servezone profile use production
# List all profiles
servezone profile list
2024-10-28 21:49:43 +01:00
```
2025-08-18 03:14:49 +00:00
## 📚 Core Commands
### 🌐 Cluster Management
``` bash
# List all clusters
servezone clusters list
# Get cluster details
servezone clusters info production-cluster
# Create a new cluster
servezone clusters create \
--name production-cluster \
--region eu-central \
--nodes 3
# Scale a cluster
servezone clusters scale production-cluster --nodes 5
# Delete a cluster
servezone clusters delete staging-cluster
```
### 🐳 Service Deployment
``` bash
# Deploy a service
servezone deploy \
--cluster production \
--name api-service \
--image myapp:2.0.0 \
--replicas 3 \
--port 80:3000
# Update a service
servezone service update api-service \
--image myapp:2.1.0 \
--replicas 5
# Scale a service
servezone service scale api-service --replicas 10
# Remove a service
servezone service remove api-service
```
### 🔐 Secret Management
``` bash
# Create a secret
servezone secrets create \
--name database-url \
--value "postgres://user:pass@host/db"
# Create a secret group
servezone secrets create-group \
--name api-secrets \
--secret DATABASE_URL = postgres://... \
--secret REDIS_URL = redis://...
# List secrets
servezone secrets list
# Get secret value
servezone secrets get database-url
# Delete a secret
servezone secrets delete old-secret
2024-10-28 21:49:43 +01:00
```
2025-08-18 03:14:49 +00:00
### 📦 Image Management
``` bash
# List images
servezone images list
# Push a new image
servezone images push \
--name myapp \
--version 2.0.0 \
--file ./myapp.tar
# Tag an image
servezone images tag myapp:2.0.0 myapp:latest
# Delete an image
servezone images delete myapp:1.0.0
2024-10-28 21:49:43 +01:00
```
2025-08-18 03:14:49 +00:00
### 📊 Monitoring & Logs
``` bash
# View service logs
servezone logs api-service
# Follow logs in real-time
servezone logs api-service --follow
2024-10-28 21:49:43 +01:00
2025-08-18 03:14:49 +00:00
# Filter logs
servezone logs api-service --since 1h --grep ERROR
2024-10-28 21:49:43 +01:00
2025-08-18 03:14:49 +00:00
# Get service status
servezone service status api-service
2024-10-28 21:49:43 +01:00
2025-08-18 03:14:49 +00:00
# Monitor cluster health
servezone clusters health production-cluster
```
2024-10-28 21:49:43 +01:00
2025-08-18 03:14:49 +00:00
### 🔧 DNS Management
2024-10-28 21:49:43 +01:00
2025-08-18 03:14:49 +00:00
``` bash
# List DNS records
servezone dns list --domain example.com
2024-10-28 21:49:43 +01:00
2025-08-18 03:14:49 +00:00
# Create a DNS record
servezone dns create \
--domain example.com \
--name api \
--type A \
--value 192.168.1.1
2024-10-28 21:49:43 +01:00
2025-08-18 03:14:49 +00:00
# Update a DNS record
servezone dns update api.example.com --value 192.168.1.2
# Delete a DNS record
servezone dns delete old.example.com
2024-10-28 21:49:43 +01:00
```
2025-08-18 03:14:49 +00:00
## 🎯 Advanced Usage
2024-10-28 21:49:43 +01:00
2025-08-18 03:14:49 +00:00
### Environment Variables
2024-10-28 21:49:43 +01:00
2025-08-18 03:14:49 +00:00
``` bash
# Set environment variables for a service
servezone deploy \
--name api-service \
--env NODE_ENV = production \
--env PORT = 3000 \
--env DATABASE_URL = @secret:database-url
```
2024-10-28 21:49:43 +01:00
2025-08-18 03:14:49 +00:00
### Configuration Files
Create a `cloudly.yaml` file:
``` yaml
cluster : production
service :
name : api-service
image : myapp:latest
replicas : 3
ports :
- 80 : 3000
environment :
NODE_ENV : production
DATABASE_URL : "@secret:database-url"
```
2024-10-28 21:49:43 +01:00
2025-08-18 03:14:49 +00:00
Deploy using the config file:
2024-10-28 21:49:43 +01:00
2025-08-18 03:14:49 +00:00
``` bash
servezone deploy --config cloudly.yaml
2024-10-28 21:49:43 +01:00
```
2025-08-18 03:14:49 +00:00
### Batch Operations
2024-10-28 21:49:43 +01:00
2025-08-18 03:14:49 +00:00
``` bash
# Deploy multiple services
servezone deploy --config services/*.yaml
2024-10-28 21:49:43 +01:00
2025-08-18 03:14:49 +00:00
# Update all services in a namespace
servezone service update --namespace api --image-tag v2.0.0
2024-10-28 21:49:43 +01:00
2025-08-18 03:14:49 +00:00
# Delete all staging resources
servezone cleanup --environment staging
```
## 🔄 CI/CD Integration
2024-10-28 21:49:43 +01:00
2025-08-18 03:14:49 +00:00
### GitHub Actions
2024-10-28 21:49:43 +01:00
2025-08-18 03:14:49 +00:00
``` yaml
- name : Deploy to Cloudly
run : |
servezone config --url ${{ secrets.CLOUDLY_URL }}
servezone login --token ${{ secrets.CLOUDLY_TOKEN }}
servezone deploy \
--cluster production \
--name api-service \
--image myapp:${{ github.sha }}
```
2024-10-28 21:49:43 +01:00
2025-08-18 03:14:49 +00:00
### GitLab CI
2024-10-28 21:49:43 +01:00
2025-08-18 03:14:49 +00:00
``` yaml
deploy :
script :
- servezone config --url $CLOUDLY_URL
- servezone login --token $CLOUDLY_TOKEN
- servezone deploy --config cloudly.yaml
2024-10-28 21:49:43 +01:00
```
2025-08-18 03:14:49 +00:00
## 🎨 Output Formats
2024-10-28 21:49:43 +01:00
2025-08-18 03:14:49 +00:00
``` bash
# JSON output for scripting
servezone clusters list --output json
2024-10-28 21:49:43 +01:00
2025-08-18 03:14:49 +00:00
# YAML output
servezone service info api-service --output yaml
2024-10-28 21:49:43 +01:00
2025-08-18 03:14:49 +00:00
# Table output (default)
servezone images list --output table
2024-10-28 21:49:43 +01:00
2025-08-18 03:14:49 +00:00
# Quiet mode (IDs only)
servezone clusters list --quiet
```
2024-10-28 21:49:43 +01:00
2025-08-18 03:14:49 +00:00
## 🛠️ Troubleshooting
2024-10-28 21:49:43 +01:00
2025-08-18 03:14:49 +00:00
``` bash
# Enable debug output
servezone --debug clusters list
# Check CLI version
servezone version
2024-10-28 21:49:43 +01:00
2025-08-18 03:14:49 +00:00
# Test connection
servezone ping
2024-10-28 21:49:43 +01:00
2025-08-18 03:14:49 +00:00
# View configuration
servezone config show
# Clear cache and credentials
servezone logout --clear-cache
2024-10-28 21:49:43 +01:00
```
2025-08-18 03:14:49 +00:00
## 📝 Command Reference
2024-10-28 21:49:43 +01:00
2025-08-18 03:14:49 +00:00
``` bash
servezone --help # Show all commands
servezone <command> --help # Show command-specific help
servezone clusters --help # Show cluster commands
servezone service --help # Show service commands
servezone secrets --help # Show secret commands
```
## 🔌 Shell Completion
Enable tab completion for your shell:
``` bash
# Bash
servezone completion bash > /etc/bash_completion.d/servezone
# Zsh
servezone completion zsh > ~/.zsh/completions/_servezone
# Fish
servezone completion fish > ~/.config/fish/completions/servezone.fish
```
2024-10-28 21:49:43 +01:00
## License and Legal Information
This repository contains open-source code that is licensed under the MIT License. A copy of the MIT License can be found in the [license ](license ) file within this repository.
**Please note: ** The MIT License does not grant permission to use the trade names, trademarks, service marks, or product names of the project, except as required for reasonable and customary use in describing the origin of the work and reproducing the content of the NOTICE file.
### Trademarks
This project is owned and maintained by Task Venture Capital GmbH. The names and logos associated with Task Venture Capital GmbH and any related products or services are trademarks of Task Venture Capital GmbH and are not included within the scope of the MIT license granted herein. Use of these trademarks must comply with Task Venture Capital GmbH's Trademark Guidelines, and any usage must be approved in writing by Task Venture Capital GmbH.
### Company Information
Task Venture Capital GmbH
Registered at District court Bremen HRB 35230 HB, Germany
For any legal inquiries or if you require further information, please contact us via email at hello@task .vc.
2025-08-18 03:14:49 +00:00
By using this repository, you acknowledge that you have read this section, agree to comply with its terms, and understand that the licensing of the code does not imply endorsement by Task Venture Capital GmbH of any derivative works.