Skip to main content
  1. All Posts/

cli

Tools TypeScript

โ„๏ธ Self-hosted now deployments

Enjoy effortless deployments with a clone of now on a cloud of your choosing.

Features

  • โšก๏ธ Deploy docker images via snow (or snow deploy)
  • ๐Ÿ”’ Auto-configured SSL
  • ๐Ÿ”ƒ Auto-scaling

This is Magic ๐Ÿ”ฎ

No, it isnโ€™t. This CLI abstracts away the complexities of using Kubernetes, cert-manager, Kaniko, and a private Docker Registry together, replicating the functionality provided by now.

Getting started

> npm i -g @snowjs/cli

# Install CLI tools
> snow install

# Create your kubernetes cluster (GCP)
> snow create

# Get your deployment's IP address
# And create a DNS 'A' record (e.g., myapp.com A 1.2.3.4)
> snow ip

# Deploy
> snow

Supported commands

Detailed descriptions of supported commands at docs/commands.md.

Support
Command
Description

โœ…

Deploy

โœ…
alias [ls]
List aliases

โœ…
alias set <deployment> <alias>
Create alias

โœ…
alias rm <alias>
Remove alias

โœ…
certs [ls]
List SSL Certificates

โœ…
certs issue <cn> [<cn>]
Issue certificate

โœ…
certs rm <cn>
Remove a certificate

๐Ÿ†•
create
Create Kubernetes cluster

โœ…
deploy
Deploy

โœ…
domains [ls]
List domains

โœ…
domains add <domain>
Add domain

โ›”
domains buy <domain>
Buy domain

โœ…
domains rm <domain>
Remove domain

โœ…
login
Login

โœ…
logout
Logout

โœ…
ls
List deployments

๐Ÿ†•
install
Install CLI tools (via brew)

๐Ÿ†•
ip
Get IP Address of deployments

โœ…
rm <name>
Remove deployment

โœ…
scale <deployment> <min> [<max>]
Scale deployment

โœ…
secrets [ls]
List secrets

โœ…
secrets add <key> <value>
Create secret

โœ…
secrets rename <old-key> <new-key>
Rename secret

โœ…
secrets rm <key>
Remove secret

Tell me more

The essential CLI commands to understand are snow create and snow deploy.

Dependencies

The following CLI tools (installable via snow install) are necessary to orchestrate the entire end-to-end process, from Kubernetes cluster creation to managing your deployments:

  • kubectl (for managing deployments, secrets)
  • helm (for installing [tiller], cert-manager, and ingress-nginx on your cluster)
  • CLI tool for your cloud provider (e.g., gcloud).

If running Kubernetes locally on Minikube, you will additionally need these cli tools:

  • docker (for running local registry)
  • minikube (for running Kubernetes locally)
  • virtualbox (for creating docker images)