Usage
Subcommands
install
Install a plugin from the registry or a local directory.Flags
| Flag | Type | Default | Description |
|---|---|---|---|
--version | string | latest | Plugin version |
--global | bool | false | Install globally (~/.dokrypt/plugins/) |
./plugins/ in the project directory. Use --global to install to ~/.dokrypt/plugins/ for use across all projects.
Examples
uninstall
Remove an installed plugin.list
List all installed plugins with details.Example Output
search
Search for plugins in the registry and locally.Example Output
update
Update a plugin to a new version.Flags
| Flag | Type | Default | Description |
|---|---|---|---|
--version | string | latest | Target version |
Examples
create
Scaffold a new plugin directory with boilerplate.Created Files
| File | Description |
|---|---|
plugin.yaml | Plugin manifest |
Dockerfile | Container image definition (Alpine 3.19) |
README.md | Usage documentation |
plugin.yaml format
Plugin Types
| Type | Description |
|---|---|
container | Runs as a Docker container alongside your services |
binary | Runs as a native binary on the host |
Plugin Hooks
Plugins can subscribe to lifecycle hooks:| Hook | Triggered When |
|---|---|
on_init | Dokrypt initializes |
on_up | Environment starts (dokrypt up) |
on_down | Environment stops (dokrypt down) |
on_transaction | A transaction is executed |
on_block_mined | A new block is mined |
on_contract_deployed | A contract is deployed |
on_test_end | Test suite completes |
Examples
publish
Publish a plugin to the registry.plugin.yaml in the current directory with: name, version, description, type (must be container or binary).
Requires DOKRYPT_REGISTRY_TOKEN environment variable.