---
title: "oz0 plugin pack"
description: "Usage and flags for oz0 plugin pack."
canonical_url: "https://docs.oz0.ai/reference/cli/oz0/plugin/pack"
---
# oz0 plugin pack

> Usage and flags for oz0 plugin pack.

For: Operators and developers looking up a command.

Pack a plugin's folder into a bundle and check the bundle as `plugin lint` checks a folder: a gzipped tar with oz0-plugin.yaml at its root, the artifact format the edge builds from a Git commit. The bundle is deterministic: entries are sorted and their times, owners and modes fixed, so the same tree always gives the same SHA-256, which identifies the version instead of a commit.

Version control (.git folders and files), virtual environments, caches, build output, .env files and whatever the .gitignore files of the folder's Git repository ignore stay out; your global Git excludes and .git/info/exclude do not count, so a laptop and CI pack one checkout to the same digest. Install it with `plugin install <file>`, or publish it with `plugin push <file> oci://...`.

The bundle carries tools.listing.json when the folder has one: --list-tools first starts the plugin's servers on a dev server and node, as `plugin test` does, and writes what they list there, so `plugin inspect` and the hub show the tools and their token costs. It fails, packing nothing, when the listing shows an agent or the plugin over its tool-size budget, as `plugin lint` does.

Pack also writes sbom.cdx.json, the plugin's CycloneDX SBOM of the packages its uv.lock and package-lock.json pin, into the folder and the bundle; commit it with the lockfiles.

Like lint, it fails on a README past the hub page's limits (64 KiB, 20 images of at most 1 MiB and 4,096 pixels a side, 5 MiB of images, 10 Mermaid diagrams, no SVG) and on a licence file that reads as another licence than license: declares, and warns without a licence file; the docs page Plugin limits explains each.

## Usage

```bash
oz0 plugin pack [dir] [flags]
```

## Flags

<table>
<thead>
  <tr>
    <th>
      Flag
    </th>
    
    <th>
      Type
    </th>
    
    <th>
      Default
    </th>
    
    <th>
      Description
    </th>
  </tr>
</thead>

<tbody>
  <tr>
    <td>
      <code>
        --cache-dir
      </code>
    </td>
    
    <td>
      string
    </td>
    
    <td>
      
    </td>
    
    <td>
      with --list-tools: where the test node keeps uv, Python and Node.js between runs
    </td>
  </tr>
  
  <tr>
    <td>
      <code>
        --json
      </code>
    </td>
    
    <td>
      bool
    </td>
    
    <td>
      
    </td>
    
    <td>
      print JSON instead of a table
    </td>
  </tr>
  
  <tr>
    <td>
      <code>
        --list-tools
      </code>
    </td>
    
    <td>
      bool
    </td>
    
    <td>
      
    </td>
    
    <td>
      first start the plugin's servers on a dev server and node, as plugin test does, and write what they list into tools.listing.json
    </td>
  </tr>
  
  <tr>
    <td>
      <code>
        --node-binary
      </code>
    </td>
    
    <td>
      string
    </td>
    
    <td>
      <code>
        next to this binary, else on PATH
      </code>
    </td>
    
    <td>
      with --list-tools: orchestrator-zero-node to run
    </td>
  </tr>
  
  <tr>
    <td>
      <code>
        --out
      </code>
      
       (<code>
        -o
      </code>
      
      )
    </td>
    
    <td>
      string
    </td>
    
    <td>
      <code>
        &lt;name>-&lt;version>.tar.gz
      </code>
    </td>
    
    <td>
      the bundle file to write
    </td>
  </tr>
  
  <tr>
    <td>
      <code>
        --runtime-bundle
      </code>
    </td>
    
    <td>
      string
    </td>
    
    <td>
      <code>
        $OZ0_RUNTIME_BUNDLE, else the newest in ./dist/runtime
      </code>
    </td>
    
    <td>
      with --list-tools: runtime bundle directory
    </td>
  </tr>
</tbody>
</table>

## Inherited flags

<table>
<thead>
  <tr>
    <th>
      Flag
    </th>
    
    <th>
      Type
    </th>
    
    <th>
      Default
    </th>
    
    <th>
      Description
    </th>
  </tr>
</thead>

<tbody>
  <tr>
    <td>
      <code>
        --context
      </code>
    </td>
    
    <td>
      string
    </td>
    
    <td>
      <code>
        $OZ0_CONTEXT or &lt;config dir>/orchestrator-zero/context.json
      </code>
    </td>
    
    <td>
      CLI context file written by server init
    </td>
  </tr>
  
  <tr>
    <td>
      <code>
        --log-level
      </code>
    </td>
    
    <td>
      string
    </td>
    
    <td>
      <code>
        info
      </code>
    </td>
    
    <td>
      log level: debug, info, warn or error
    </td>
  </tr>
</tbody>
</table>

See [all `oz0` commands](https://docs.oz0.ai/reference/cli/oz0) and the [global flags](https://docs.oz0.ai/reference/cli/oz0#global-flags).


## Sitemap

See the full [sitemap](https://docs.oz0.ai/sitemap.md) for all pages.
