Skip to main content

init

Initialize a Chain project.

Arguments

PATH
Path to a new or empty directory for the Chain. Defaults to the current directory if omitted.

Options

humanfriendly | W | WARNING | I | INFO | D | DEBUG
default:"humanfriendly"
Logging verbosity. humanfriendly (default) is pretty-printed; INFO, DEBUG, WARNING produce structured logs.
Disable interactive prompts. Use in CI/automated contexts where stdin isn’t a TTY.
Example: To create a new Chain project in a directory called my-chain, use the following:

push

Deploy a Chain.

Arguments

PATH
required
Path to a Python file that contains the entrypoint chainlet.
TEXT
Class name of the entrypoint chainlet. If omitted, the chainlet tagged with @chains.mark_entrypoint is used.

Options

TEXT
Name of the Chain to deploy. If not given, the entrypoint name is used.
deprecated
Published deployments are now the default. Use --watch for development deployments instead.
Promote newly deployed chainlets into production.
TEXT
Deploy the Chain as a published deployment to the specified environment. When specified, publish is implied and --promote is ignored.
Wait until all chainlets are ready (or deployment fails).
Watch the Chains source code and apply live patches. Implies --wait — the command waits for the Chain to be deployed before starting to watch for changes. Requires a development deployment.
Produce only generated files; don’t deploy anything.
TEXT
Name of the remote in .trussrc to push to.
TEXT
Run watch, but only apply patches to specified chainlets. Pass a comma-separated list of chainlet display names. Faster dev loops, but may lead to inconsistent deployments. Use with caution and refer to the chain watch documentation.
Attach git versioning info (sha, branch, tag) to deployments made from within a git repo. Can also be set permanently in .trussrc.
Disable downloading of pushed Chain source code from the UI.
TEXT
Name of the deployment created by the push. Can be used with --promote.
TEXT
Name of the team to deploy to. If not specified, Truss infers the team based on your team membership and existing chains, or prompts for selection when ambiguous.
The --team flag is only available if your organization has teams enabled. Contact us to enable teams, or see Teams for more information.
BOOLEAN
default:"true"
Keep development chainlet models warm by preventing scale-to-zero while watching. Requires —watch.
humanfriendly | W | WARNING | I | INFO | D | DEBUG
default:"humanfriendly"
Logging verbosity. humanfriendly (default) is pretty-printed; INFO, DEBUG, WARNING produce structured logs.
Disable interactive prompts. Use in CI/automated contexts where stdin isn’t a TTY.
Example: To deploy a Chain as a published deployment:
To create a development deployment and start watching for changes:
To deploy and promote to production:
To deploy to a specific team:

watch

Live reload development.

Arguments

PATH
required
Path to a Python file containing the entrypoint chainlet.
TEXT
Class name of the entrypoint chainlet. If omitted, the chainlet tagged with @chains.mark_entrypoint is used.

Options

TEXT
Name of the Chain to watch. If not given, the entrypoint name is used.
TEXT
Name of the remote in .trussrc to push to.
TEXT
Run watch, but only apply patches to specified chainlets. Pass a comma-separated list of chainlet display names. Faster dev loops, but may lead to inconsistent deployments. Use with caution and refer to the chain watch documentation.
TEXT
Name of the team for the Chain to watch. If not specified, Truss infers the team based on your team membership and existing chains, or prompts for selection when ambiguous.
The --team flag is only available if your organization has teams enabled. Contact us to enable teams, or see Teams for more information.
BOOLEAN
default:"true"
Keep development chainlet models warm by preventing scale-to-zero while watching.
humanfriendly | W | WARNING | I | INFO | D | DEBUG
default:"humanfriendly"
Logging verbosity. humanfriendly (default) is pretty-printed; INFO, DEBUG, WARNING produce structured logs.
Disable interactive prompts. Use in CI/automated contexts where stdin isn’t a TTY.
Example: To watch a Chain for live reload during development, use the following:
By default, watch keeps development Chainlets warm (--no-sleep is on) so they don’t scale to zero while you iterate. To let idle Chainlets scale to zero, opt out: