Skip to main content

arc deploy

arc deploy registers or publishes a blocklet: locally with the daemon for development, or to a DID Space (local or remote) for real publishing.

arc deploy deploys and manages blocklets, both local daemon registration (for development) and DID Space publishing (for real distribution). This is a different thing from arc blocklet deploy, which pushes to Cloudflare Pages, arc deploy is about the local daemon and DID Space.

bash
arc deploy <path> [options]

Global flags (see Overview): --json, --view, --instance / -i (which local ARC instance; omit for default), and --home (instance root; to pick which instance, use --instance).

  • path: local blocklet directory path, a git+https://… URL, or an https://…/archive.tar.gz URL — the latter two (remote sources) additionally require --publish, or the command fails fast with Remote sources (git+url / http-url) require --publish.

Options

  • --publish: publish blocklet code to the local developer DID Space instead of registering with the local daemon (zero network/auth); only local publishes are visible to arc deploy show/list --published
  • --server <url>: publish to a remote DID Space server instead of the local one, implies --publish; always requires auth (browser flow, cached credential, or --token), even against a loopback URL
  • --token <token>: bearer token for --server, otherwise an interactive browser auth flow is used. Declared and enforced: passing --token without --server fails fast rather than silently ignoring the token —Passing both together clears that check and moves on to the real work — it fails here only because the path doesn't exist, proving the check discriminates rather than rejecting everything:
  • --browser: open a browser for the auth flow when publishing to --server (default true); pass --no-browser with --token for unattended runs
  • --prerender: pre-render web pages into .web-cache/ before publishing, same as arc blocklet build's ARC_PRERENDER; on by default, pass --no-prerender or ARC_PRERENDER=0 to opt out
  • --dry-run: print the deploy plan without registering, publishing, or fetching

arc deploy <path> on its own registers and serves the blocklet for the current daemon session only — it does not survive a restart. There is no --persist flag on arc deploy itself; to make a blocklet source come back after arc service restart, record it on the instance instead:

bash
arc service start --blocklet /path/to/my-blocklet   # or: arc service restart --blocklet /path/to/my-blocklet

Examples (from arc deploy --help)

bash
arc deploy /path/to/my-blocklet                          # register and serve a local blocklet (hot-adds if the instance is running)
arc deploy /path/to/my-blocklet --dry-run                # preview a deploy without writing
arc service start --blocklet /path/to/my-blocklet        # record the source on the instance so it survives restart
arc deploy /path/to/my-blocklet --publish                # publish blocklet code to developer DID Space
arc deploy list                                          # list the default instance's registered blocklet sources
arc deploy list -i alice                                 # list only instance alice's registered sources
arc deploy list --home /path/to/instance                 # list sources of the instance registered at that home
arc deploy list --published                              # list blocklets published to DID Space
arc deploy show did:blocklet:z2x                         # read back files published to DID Space
arc deploy remove /path/to/my-blocklet                   # drop a source from the instance record; restart to apply

arc deploy list

List all extra-registered blocklet sources, or published DID Space blocklets.

Usage

bash
arc deploy list [options]
  • --published: list blocklets published to DID Space (blocklet-sources.json), instead of registered sources

Example

bash
$ arc deploy list
Registered blocklet sources (via instance default):
No extra blocklet sources registered.
Tip: arc service start --blocklet <path>

arc deploy remove

Drop one registered extra blocklet source from the instance record (arc#6061; not a hot-unplug — restart to apply).

Usage

bash
arc deploy remove <target> [options]
  • target (required): blocklet dir, or its parent extra-source dir, to drop

Example (accept path: target is actually registered)

bash
$ arc deploy remove /path/to/my-blocklet
Unregistered /path/to/my-blocklet from instance default.
Restart with `arc service restart` to apply.

Nothing registered to drop is a reject path, exit 1:

bash
$ arc deploy remove /path/to/my-blocklet
ERROR: Error: "/path/to/my-blocklet" is not a registered extra source on instance default.
Registered: (none)

arc deploy show

Read back the files published to the developer DID Space for a blocklet.

Usage

bash
arc deploy show <did> [subpath] [options]
  • did (required): blocklet DID, or bare id, to inspect
  • subpath: optional path inside the published tree