npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2025 – Pkg Stats / Ryan Hefner

dargo-cli

v0.0.8

Published

Lightning-fast Next.js deployment tool for VPS with automatic SSL

Readme

dargo-cli

npm version npm downloads GitHub stars License

Lightning-fast Next.js deployment to any VPS — One-command shipping with SSL, zero downtime, rollbacks, environment sync, and full autopilot server provisioning.

A powerful, production-grade deployment tool for Next.js applications targeting Debian-based VPS servers. Designed for builders who want modern DevOps capabilities without the DevOps overhead.


Key Features

One-command deployment — Ship instantly with dargo deploy
🔒 Automatic SSL — Full Let's Encrypt integration
🔥 Zero‑downtime — Atomic symlink switching with rollback safety
🚀 Ultra-fast deployments — pnpm-powered, optimized build flow
🛡️ Security-first — Automatic UFW firewall rules + key-based SSH
📦 Release management — Versioned releases with cleanup
🌍 Environment sync — Push/pull .env files seamlessly
📊 Observability — Logs, status, restart, and SSH built-in
🔧 Full provisioning — Node.js 24, Nginx, PM2, SSL, firewall
📁 Capistrano-style structure — Industry-standard deployment layout


Installation

npm install -g dargo-cli
# or
pnpm add -g dargo-cli

Quick Start

1. Create Config

dargo init

This generates dargo.config.json:

{
  "server": {
    "host": "your.server.ip",
    "port": 22,
    "user": "admin",
    "pem": "./keys/your.pem"
  },
  "app": {
    "name": "app.yourdomain.com",
    "deployPath": "/var/www/app.yourdomain.com",
    "pm2AppName": "app.yourdomain.com",
    "port": 3000,
    "email": "[email protected]"
  },
  "keepReleases": 3
}

2. Provision the VPS

dargo provision

Installs:

  • Node.js 24
  • PM2
  • pnpm
  • Nginx
  • SSL (Let's Encrypt)
  • UFW firewall
  • Deployment directory structure

3. Sync Environment Variables

dargo env push

4. Deploy

dargo deploy

Commands Overview

Core

| Command | Description | |--------|-------------| | dargo init | Create config | | dargo provision | Bootstrap the server | | dargo deploy | Build + deploy (supports --legacy-peer-deps) | | dargo rollback | Revert to a previous release |

Advanced Usage

Dependency Management

If you encounter issues with dependency installation (e.g., peer dependency conflicts), you have several options:

  1. Legacy Peer Deps (Local + Remote): Applies legacy behavior to both local build and remote server.

    dargo deploy --legacy-peer-deps
  2. Remote Only: Applies legacy behavior only to the remote server. Use this if your local build works fine but the server needs the flag.

    dargo deploy --remote-legacy-peer-deps
  3. Skip Local Install: If you have already installed dependencies locally and want to avoid Dargo reinstalling them (which might break things), use --no-install.

    dargo deploy --no-install
    # or combine with remote legacy flag
    dargo deploy --no-install --remote-legacy-peer-deps

Automatic Optimization

  • Memory Cleanup: Both provision and deploy commands now automatically clear system caches (RAM) and package manager caches to ensure optimal performance, especially on smaller instances.
  • Service Refresh: Redeployments automatically reload/restart Nginx to ensure configuration changes take effect immediately.

Management

| Command | Description | |--------|-------------| | dargo env push/pull | Manage .env.production files | | dargo logs | Stream PM2 logs | | dargo status | Check app status | | dargo restart | Restart app | | dargo ssh | SSH directly |


Server Architecture

/var/www/app/
├── current -> releases/app-v1.0.0-abc123/
├── releases/
│   ├── app-v1.0.0-abc123/
│   ├── app-v0.9.0-xyz789/
└── shared/
    ├── .env
    └── ecosystem.config.js

Why it’s stable:

  • Atomic symlink switches
  • Old version stays active until PM2 restart
  • Rollbacks are instant
  • Identical to patterns used by Capistrano, Laravel Forge, Deployer

Versioning

Release naming:

{name}-v{package.json version}-{randomId}.tar.gz

Example:

myapp-v1.2.3-x7z9q2.tar.gz

Requirements

Local

  • Node.js 18+
  • pnpm (recommended)
  • SSH key auth

Server

  • Debian / Ubuntu VPS
  • Root or sudo access

Troubleshooting

dargo logs
dargo status
dargo restart
dargo rollback
dargo provision --force

Contributing

Please read the Contributing Guide for contribution standards, issue templates, branching rules, and testing workflow.

Star the repo to support ongoing development.


Author

Salman Khan
dargo-cli by dragondevs