capsulectl

command module
v0.0.0-...-7c019d2 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Aug 15, 2022 License: MIT Imports: 7 Imported by: 0

README

Capsule CLI: capsulectl aka cc

Publish a wasm file to the Capsule registry

CAPSULE_REGISTRY_ADMIN_TOKEN="AZERTYUIOP" \
./cc publish \
-wasmFile=./hey/hey.wasm -wasmInfo=wip \
-wasmOrg=k33g -wasmName=hey -wasmTag=0.0.0 \
-registryUrl=http://localhost:4999

Deploy a function (with a revision) to the worker

CAPSULE_WORKER_URL="http://localhost:9999" \
CAPSULE_REVERSE_PROXY_URL="http://localhost:8888" \
CAPSULE_BACKEND="memory" \
CAPSULE_WORKER_ADMIN_TOKEN="0987654321" \
./cc deploy \
-function=hey \
-revision=demo \
-downloadUrl=http://localhost:4999/k33g/hey/0.0.0/hey.wasm

🖐 if you deploy the same revision, you scale the function

Set an existing revision as the default revision

CAPSULE_WORKER_URL="http://localhost:9999" \
CAPSULE_REVERSE_PROXY_URL="http://localhost:8888" \
CAPSULE_BACKEND="memory" \
CAPSULE_WORKER_ADMIN_TOKEN="0987654321" \
./cc set-default \
-function=hello \
-revision=orange

Remove the default revision of a function

CAPSULE_WORKER_URL="http://localhost:9999" \
CAPSULE_REVERSE_PROXY_URL="http://localhost:8888" \
CAPSULE_BACKEND="memory" \
CAPSULE_WORKER_ADMIN_TOKEN="0987654321" \
./cc unset-default \
-function=hello

Un-deploy the revision of a function

CAPSULE_WORKER_URL="http://localhost:9999" \
CAPSULE_REVERSE_PROXY_URL="http://localhost:8888" \
CAPSULE_BACKEND="memory" \
CAPSULE_WORKER_ADMIN_TOKEN="0987654321" \
./cc un-deploy \
-function=hello \
-revision=green

Documentation

The Go Gopher

There is no documentation for this package.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL