Guide Progress 0 / 7 steps completed
Account
CLI
Auth
Project
Deploy
DNS
Monitor
\n
0

Prerequisites

Before you begin, make sure you have the following:

🔧

Node.js 18+

Required for the CLI and local development tools.

📦

npm or pnpm

Package manager for installing the CloudNexus CLI.

🔐

Git

Version control for managing your deployment configs.

🌐

Domain Name

An optional custom domain for your applications.

1

Create Your Account

Head to the CloudNexus Console and sign up with your email or SSO provider. New accounts receive $200 in free credits to explore the platform.

ℹ️
Free Tier Included
Every account includes a free tier with 1 shared VPS, 50 GB storage, and 1 TB bandwidth per month — no credit card required.

After signing up, you'll be taken to your dashboard where you can manage projects, view billing, and access the API documentation.

2

Install the CLI

The CloudNexus CLI (cnx) is the fastest way to manage your infrastructure. Install it globally using npm:

Terminal
$ npm install -g @cloudnexus/cli

Or if you prefer pnpm:

Terminal
$ pnpm add -g @cloudnexus/cli

Verify the installation:

Terminal
$ cnx --version
CloudNexus CLI v2.8.4
💡
Tip: Use the Auto-Updater
The CLI auto-updates to the latest stable version. Run cnx update to manually check for updates.
3

Authenticate the CLI

Log in to your CloudNexus account from the terminal:

Terminal
$ cnx login
Opening browser for authentication...
✅ Successfully authenticated as alex@example.com

For CI/CD pipelines or server environments, use an API token instead:

Terminal
$ cnx login --token cnx_live_sk_abc123...
✅ Token authenticated successfully
⚠️
Security Notice
Never commit API tokens to version control. Use environment variables or a secrets manager. Read our security best practices for more guidance.

Generate an API Token

You can create tokens from the CLI or the Console:

Terminal
$ cnx token create --name "production-deploy" --scope "servers:write projects:read"
🔑 Token created: cnx_live_sk_x7k9m...
⚠️  Store this token securely. It cannot be viewed again.
4

Create Your First Project

Projects are the top-level container for all your resources. Each project gets its own billing, networking, and access controls.

1
Initialize a new project in your directory
2
Answer the prompts to configure your project
3
A cnx.config.json file will be created
Terminal
$ cnx init
? Project name: my-app
? Region: us-east-1 (Virginia)
? Environment: production
✅ Project "my-app" created (ID: prj_8x3kd9)

This generates a cnx.config.json file:

JSON
{
  "name": "my-app",
  "project_id": "prj_8x3kd9",
  "region": "us-east-1",
  "environment": "production",
  "servers": [ ],
  "cdn": {
    "enabled": false,
    "zones": [ ]
  },
  "databases": [ ],
  "auto_scale": false
}
5

Deploy Your First Server

Let's provision a virtual server with a single command. CloudNexus supports multiple operating systems and pre-configured images.

Terminal
$ cnx server create \\
  --name "web-server-01" \\
  --plan "professional" \\
  --image "ubuntu-22.04" \\
  --region "us-east-1"

⏳ Provisioning server "web-server-01"...
📡 Allocating IP: 198.51.100.42
🔑 Generating SSH keys...
✅ Server is online (took 23s)

────────────────────────────────────
Name:         web-server-01
ID:           srv_2m8xf1
Status:       running
IP Address:   198.51.100.42
Plan:         Professional (8 vCPU, 32 GB RAM)
Storage:      320 GB NVMe SSD
Region:       us-east-1
────────────────────────────────────

SSH into Your Server

Connect to your new server using the built-in SSH command:

Terminal
$ cnx ssh web-server-01
Connecting to 198.51.100.42...
Welcome to Ubuntu 22.04.3 LTS
cloudnexus@web-server-01:~$

Deploy Application from Git

For a faster workflow, deploy directly from a Git repository:

Terminal
$ cnx deploy --repo github.com/your-org/my-app \\
  --branch main \\
  --target web-server-01 \\
  --build "npm install && npm run build" \\
  --start "npm start"

⏳ Cloning repository...
🔨 Building application...
🚀 Starting services...
✅ Deployed successfully (took 1m 42s)
🌐 Available at: https://web-server-01.cnx.app
💡
Auto-Build Detection
CloudNexus automatically detects your framework (Node.js, Python, Go, Ruby, etc.) and sets up the optimal build and runtime environment. You can override this with the --buildpack flag.
6

Configure DNS & Domain

Point your custom domain to your deployment. CloudNexus provides automatic SSL certificate provisioning via Let's Encrypt.

Using CloudNexus DNS

If you manage your DNS with CloudNexus, add a CNAME record:

Terminal
$ cnx dns add --type CNAME \\
  --name "www.yourdomain.com" \\
  --value "web-server-01.cnx.app"

✅ CNAME record created
🔒 SSL certificate provisioning initiated
⏳ Certificate will be active within 2 minutes

Using External DNS Provider

Add a CNAME record pointing to web-server-01.cnx.app in your DNS provider's dashboard. The SSL certificate will auto-provision once DNS propagation completes.

ℹ️
SSL Certificate Status
Check certificate status with cnx dns cert-status yourdomain.com. Certificates auto-renew 30 days before expiration.
7

Set Up Monitoring

Enable real-time monitoring and alerts for your infrastructure. CloudNexus provides built-in metrics, logs, and tracing.

Enable Server Monitoring

Terminal
$ cnx monitor enable --server web-server-01

✅ Monitoring agent installed
📊 Metrics: CPU, Memory, Disk, Network
📝 Logs: System + Application (auto-detected)
🔔 Alerts: Configured default thresholds

Configure Alerts

Terminal
$ cnx alert create \\
  --name "High CPU" \\
  --condition "cpu.usage > 85" \\
  --duration "5m" \\
  --notify "slack" "email"

✅ Alert "High CPU" created (ID: alt_9f2kp3)

View Real-Time Metrics

Terminal
$ cnx metrics live --server web-server-01

═══════════════════════════════════════
  Server: web-server-01 • Live Metrics
═══════════════════════════════════════
  CPU:     ████████░░░░  34% (4/8 cores)
  Memory:  ████████████░  62% (20/32 GB)
  Disk I/O: ████░░░░░░░  12% (45 MB/s)
  Network: ████░░░░░░░  1.2 Gbps in / 0.8 Gbps out
  Uptime:  4d 12h 33m
═══════════════════════════════════════
ℹ️
Dashboard Access
For a full interactive dashboard, visit console.cloudnexus.com/monitoring. You can create custom dashboards, set up Grafana integrations, and configure PagerDuty alerts.

Configuration Reference

Here's a complete example of a cnx.config.json with all available options:

JSON
{
  "name": "my-app",
  "project_id": "prj_8x3kd9",
  "region": "us-east-1",
  "environment": "production",
  "servers": [
    {
      "name": "web-server-01",
      "plan": "professional",
      "image": "ubuntu-22.04",
      "firewall": ["80/tcp", "443/tcp", "22/tcp"],
      "backups": true,
      "auto_upgrade": true
    }
  ],
  "cdn": {
    "enabled": true,
    "zones": [
      {
        "domain": "www.yourdomain.com",
        "origin": "web-server-01.cnx.app",
        "ssl": "automatic",
        "cache_ttl": 3600
      }
    ]
  },
  "databases": [
    {
      "engine": "postgresql",
      "version": "16",
      "plan": "standard",
      "backups": true,
      "read_replicas": 1
    }
  ],
  "auto_scale": true,
  "scaling": {
    "min_instances": 1,
    "max_instances": 10,
    "target_cpu": 70
  }
}

API Quick Reference

Manage your infrastructure programmatically using the REST API. All API requests require an API token in the Authorization header.

Method Endpoint Description
POST /v2/servers Create a new virtual server
GET /v2/servers/{id} Get server details
PUT /v2/servers/{id} Update server configuration
DELETE /v2/servers/{id} Destroy a server
POST /v2/servers/{id}/restart Restart a server
GET /v2/projects List all projects
POST /v2/deployments Create a new deployment
GET /v2/metrics Query metrics data

Example: Create Server via API

cURL
$ curl -X POST https://api.cloudnexus.com/v2/servers \\
  -H "Authorization: Bearer cnx_live_sk_abc123..." \\
  -H "Content-Type: application/json" \\
  -d '{
    "name": "api-server-01",
    "plan": "professional",
    "image": "ubuntu-22.04",
    "region": "us-east-1"
  }'

Example: Response

JSON
{
  "id": "srv_4n7wx2",
  "name": "api-server-01",
  "status": "provisioning",
  "ip_address": "198.51.100.78",
  "plan": "professional",
  "region": "us-east-1",
  "created_at": "2025-12-15T10:30:00Z",
  "estimated_ready": "2025-12-15T10:30:30Z"
}

What's Next?

🎉

Congratulations!

You've successfully deployed your first CloudNexus server. Here are some recommended next steps:

  • Set up auto-scaling — Configure automatic scaling rules to handle traffic spikes: cnx scale configure
  • Enable CDN caching — Speed up content delivery with edge caching across 300+ locations
  • Provision a managed database — Add PostgreSQL or MySQL with automatic backups: cnx db create
  • Configure CI/CD — Integrate with GitHub Actions, GitLab CI, or your pipeline of choice
  • Set up team access — Invite team members with role-based access control: cnx team invite
  • Explore monitoring — Set up custom dashboards and alerting rules in the console
💡
Need Help?
Check out our full documentation, join the community Discord, or contact support for enterprise assistance.