Command Line

unfurl

unfurl [OPTIONS] COMMAND [ARGS]...

Options

--home <home>

Path to .unfurl_home

--runtime <runtime>

use this runtime

--no-runtime

ignore runtime settings

-v, --verbose

verbose mode (-vvv for more)

-q, --quiet

Only output errors to the stdout

--logfile <logfile>

Log messages to file (at DEBUG level)

--tmp <tmp>

Directory for saving temporary files

--loglevel <loglevel>

log level (overrides -v)

--version-check <version_check>

Abort if the runtime’s Unfurl is older than the given version

--no-version-check

Skip the Unfurl version check when invoking the runtime.

--skip-upstream-check

Skip pulling latest upstream changes from existing repositories.

Environment variables

UNFURL_HOME

Provide a default for --home

UNFURL_RUNTIME

Provide a default for --runtime

UNFURL_NORUNTIME

Provide a default for --no-runtime

UNFURL_LOGFILE

Provide a default for --logfile

UNFURL_TMPDIR

Provide a default for --tmp

UNFURL_LOGGING

Provide a default for --loglevel

UNFURL_VERSION_CHECK

Provide a default for --version-check

UNFURL_SKIP_UPSTREAM_CHECK

Provide a default for --skip-upstream-check

check

Check and update the status of the ensemble’s instances

unfurl check [OPTIONS] [ENSEMBLE]

Options

--var <var>

name/value pair to pass to job (multiple times ok).

--use-environment <use_environment>

Run this job in the given environment.

--force

(Re)run operation regardless of instance’s status or state

--starttime <starttime>

Set the start time of the job.

--output <output>

How to print summary of job run

Options

text | json | none

--trace <trace>

Set the query’s trace level

--query <query>

Run the given expression upon job completion

--instance <instance>

instance name to target

--template <template>

TOSCA template to target

--change-detection <change_detection>

How to detect configuration changes to existing instances. (Default: evaluate)

Options

skip | spec | evaluate

--skip-new

Don’t create instance for new templates.

--jobexitcode <jobexitcode>

Set exit code to 64 if job ends at given status. (Default: never)

Options

error | degraded | never

-m, --message <message>

commit message to use

--dirty <dirty>

Action if there are uncommitted changes before run. (Default: auto)

Options

abort | ok | auto

--push

Push after committing. (Default: false)

--commit

Commit modified files to the ensemble repository. (Default: false)

--dryrun

Do not modify anything, just do a dry run.

Arguments

ENSEMBLE

Optional argument

clone

Create a new ensemble or project from a service template or an existing ensemble or project.

SOURCE Path or git url to a project, ensemble, or service template

DEST Path to the new project or ensemble

unfurl clone [OPTIONS] SOURCE [DEST]

Options

--mono

Create one repository for the project.

--existing

Add project to nearest existing repository.

--empty

Don’t create a default ensemble.

--design

Set up project for blueprint development.

--use-environment <use_environment>

Associate the given environment with the ensemble.

--skeleton <skeleton>

Path to a directory of project skeleton templates.

--overwrite

Create ensemble in the given directory even if it exists.

--use-deployment-blueprint <use_deployment_blueprint>

Use this deployment blueprint.

--var <var>

name/value pair to pass to skeleton (multiple times ok).

Arguments

SOURCE

Required argument

DEST

Optional argument

cloudmap

Manage a cloud map.

[CLOUDMAP] is either a named cloudmap, a git url, or a local path. (Default: “cloudmap”)

unfurl cloudmap [OPTIONS] [CLOUDMAP]

Options

--sync <sync>

Sync the given repository host (“local”, name, or url).

--import <import>

Update the cloudmap with the given repository host (“local”, name, or url).

--export <export>

Update the given repository host (“local”, name, or url) with the local repositories recorded in the cloudmap.

--namespace <namespace>

Limit sync to repositories in this folder or group.

--repository <repository>

Limit sync to this one repository (matches key).

--clone-root <clone_root>

Directory to clone repositories to.

--visibility <visibility>

Only filter projects by visibility (overrides config).

Options

public | any

--project <project>

Unfurl project to use. (Default: “.”)

--skip-analysis

Don’t analyze files in repositories

--force

Force push to repository host

--dryrun

Do not modify the repository host, just do a dry run.

Arguments

CLOUDMAP

Optional argument

commit

Commit any changes to the given project or ensemble.

unfurl commit [OPTIONS] [PROJECT_OR_ENSEMBLE_PATH]

Options

-m, --message <message>

commit message to use

--no-edit

Use default message instead of invoking the editor

--skip-add

Don’t add files for committing (user must add using git)

--all-repositories

Commit all repositories the ensemble accesses

--use-environment <use_environment>

Use this environment.

Arguments

PROJECT_OR_ENSEMBLE_PATH

Optional argument

deploy

Deploy the given ensemble

unfurl deploy [OPTIONS] [ENSEMBLE]

Options

--var <var>

name/value pair to pass to job (multiple times ok).

--use-environment <use_environment>

Run this job in the given environment.

--force

(Re)run operation regardless of instance’s status or state

--starttime <starttime>

Set the start time of the job.

--output <output>

How to print summary of job run

Options

text | json | none

--trace <trace>

Set the query’s trace level

--query <query>

Run the given expression upon job completion

--instance <instance>

instance name to target

--template <template>

TOSCA template to target

--check

check if new instances exist before deploying

--destroyunmanaged

include unmanaged instances for consideration when destroying

--prune

destroy instances that are no longer used

--upgrade

Apply major versions changes.

--repair <repair>

Re-run operations on instances that are in an error or degraded state. (Default: error)

Options

error | degraded | none

--change-detection <change_detection>

How to detect configuration changes to existing instances. (Default: evaluate)

Options

skip | spec | evaluate

--skip-new

Don’t create instance for new templates.

-a, --approve

Don’t prompt for approval to apply changes.

--jobexitcode <jobexitcode>

Set exit code to 64 if job ends at given status. (Default: never)

Options

error | degraded | never

-m, --message <message>

commit message to use

--dirty <dirty>

Action if there are uncommitted changes before run. (Default: auto)

Options

abort | ok | auto

--push

Push after committing. (Default: false)

--commit

Commit modified files to the ensemble repository. (Default: false)

--dryrun

Do not modify anything, just do a dry run.

Arguments

ENSEMBLE

Optional argument

Environment variables

UNFURL_APPROVE

Provide a default for -a

discover

Run the “discover” workflow which updates the ensemble’s spec by probing its live instances.

unfurl discover [OPTIONS] [ENSEMBLE]

Options

--var <var>

name/value pair to pass to job (multiple times ok).

--use-environment <use_environment>

Run this job in the given environment.

--force

(Re)run operation regardless of instance’s status or state

--starttime <starttime>

Set the start time of the job.

--output <output>

How to print summary of job run

Options

text | json | none

--trace <trace>

Set the query’s trace level

--query <query>

Run the given expression upon job completion

--instance <instance>

instance name to target

--template <template>

TOSCA template to target

-a, --approve

Don’t prompt for approval to apply changes.

--jobexitcode <jobexitcode>

Set exit code to 64 if job ends at given status. (Default: never)

Options

error | degraded | never

-m, --message <message>

commit message to use

--dirty <dirty>

Action if there are uncommitted changes before run. (Default: auto)

Options

abort | ok | auto

--push

Push after committing. (Default: false)

--commit

Commit modified files to the ensemble repository. (Default: false)

--dryrun

Do not modify anything, just do a dry run.

Arguments

ENSEMBLE

Optional argument

Environment variables

UNFURL_APPROVE

Provide a default for -a

export

If path to an Unfurl project or ensemble, export ensemble in a simplified json format or as Python source. If a Python file, export to YAML.

unfurl export [OPTIONS] [PATH]

Options

--format <format>

Default: deployment

Options

python | blueprint | environments | deployment | deployments

--use-environment <use_environment>

Export using this environment.

--file <file>

Write json export to this file instead of the console.

--overwrite <overwrite>

Overwrite existing files (Default: auto)

Options

older | never | always | auto

--python-target <python_target>

Python version to target when –format python (Default: current version)

Options

3.7 | 3.8 | 3.9 | 3.10

Arguments

PATH

Optional argument

Environment variables

UNFURL_OVERWRITE_POLICY

Provide a default for --overwrite

git

unfurl git [git command] [git command arguments]: Run the given git command on each project repository.

unfurl git [OPTIONS] [GITARGS]...

Options

--dir <dir>

Path to project or ensemble (default: “.”)

Arguments

GITARGS

Optional argument(s)

git-status

Show the git status for paths relevant to the given project or ensemble.

unfurl git-status [OPTIONS] [PROJECT_OR_ENSEMBLE_PATH]

Options

--dirty

Only show repositories with uncommitted changes

--use-environment <use_environment>

Use this environment.

Arguments

PROJECT_OR_ENSEMBLE_PATH

Optional argument

help

Get help on a command

unfurl help [OPTIONS] [CMD]

Arguments

CMD

Optional argument

home

If no options are set, display the location of current unfurl home. To create a new home project use –init and the global –home option.

unfurl home [OPTIONS]

Options

--render

Generate files only (don’t create repository)

--init

Create a new home project

--replace

Replace (and backup) current home project

init

Create a new project or, if [project_dir] exists or is inside a project, create a new ensemble. If [ensemble_name] is omitted, use a default name.

unfurl init [OPTIONS] [PROJECTDIR] [ENSEMBLE_NAME]

Options

--mono

Don’t create a separate ensemble repository.

--existing

Add project to nearest existing repository.

--submodule

Set the ensemble repository as a git submodule.

--empty

Don’t create a default ensemble.

--skeleton <skeleton>

Absolute path to a directory of project skeleton templates.

--create-environment

Create (if missing) a environment with the same name and set this as the default repository for ensembles that use this environment.

--use-environment <use_environment>

Associate the given environment with this ensemble.

--shared-repository <shared_repository>

Create the ensemble in an repository outside the project.

--overwrite <overwrite>

Create ensemble in the given directory even if it exists.

--render

Generate files only (don’t commit them).

--use-deployment-blueprint <use_deployment_blueprint>

Use this deployment blueprint.

--var <var>

name/value pair to pass to skeleton (multiple times ok).

Arguments

PROJECTDIR

Optional argument

ENSEMBLE_NAME

Optional argument

plan

Print the given deployment plan

unfurl plan [OPTIONS] [ENSEMBLE]

Options

--var <var>

name/value pair to pass to job (multiple times ok).

--use-environment <use_environment>

Run this job in the given environment.

--force

(Re)run operation regardless of instance’s status or state

--starttime <starttime>

Set the start time of the job.

--output <output>

How to print summary of job run

Options

text | json | none

--trace <trace>

Set the query’s trace level

--query <query>

Run the given expression upon job completion

--instance <instance>

instance name to target

--template <template>

TOSCA template to target

--check

check if new instances exist before deploying

--destroyunmanaged

include unmanaged instances for consideration when destroying

--prune

destroy instances that are no longer used

--upgrade

Apply major versions changes.

--repair <repair>

Re-run operations on instances that are in an error or degraded state. (Default: error)

Options

error | degraded | none

--change-detection <change_detection>

How to detect configuration changes to existing instances. (Default: evaluate)

Options

skip | spec | evaluate

--skip-new

Don’t create instance for new templates.

--workflow <workflow>

plan workflow (default: deploy)

Arguments

ENSEMBLE

Optional argument

run

Run an ad-hoc command in the context of the given ensemble. Use “–” to separate the given command line, for example:

> unfurl run – echo ‘hello!’

If –host or –module is set, the ansible configurator will be used. e.g.:

> unfurl run –host=example.com – echo ‘hello!’

unfurl run [OPTIONS] [CMDLINE]...

Options

--ensemble <ensemble>
-a, --approve

Don’t prompt for approval to apply changes.

--jobexitcode <jobexitcode>

Set exit code to 64 if job ends at given status. (Default: never)

Options

error | degraded | never

-m, --message <message>

commit message to use

--dirty <dirty>

Action if there are uncommitted changes before run. (Default: auto)

Options

abort | ok | auto

--push

Push after committing. (Default: false)

--commit

Commit modified files to the ensemble repository. (Default: false)

--dryrun

Do not modify anything, just do a dry run.

--var <var>

name/value pair to pass to job (multiple times ok).

--use-environment <use_environment>

Run this job in the given environment.

--force

(Re)run operation regardless of instance’s status or state

--starttime <starttime>

Set the start time of the job.

--output <output>

How to print summary of job run

Options

text | json | none

--trace <trace>

Set the query’s trace level

--query <query>

Run the given expression upon job completion

--instance <instance>

instance name to target

--template <template>

TOSCA template to target

--host <host>

host to run the command on

--operation <operation>

TOSCA operation to run

--module <module>

ansible module to run (default: command)

Arguments

CMDLINE

Optional argument(s)

Environment variables

UNFURL_APPROVE

Provide a default for -a

runtime

If no options are set, display the runtime currently used by the project. To create a new runtime in the project root use –init and the global –runtime option.

unfurl runtime [OPTIONS] [PROJECT_FOLDER]

Options

--init

Create a new runtime

--update

Update Python requirements to match this instance of Unfurl.

Arguments

PROJECT_FOLDER

Optional argument

serve

Run unfurl as a server.

unfurl serve [OPTIONS] [PROJECT_OR_ENSEMBLE_PATH]

Options

--port <port>

Port to listen on (default: 8081)

--address <address>

Host to listen on (0.0.0.0 for external connections) (default: localhost)

--secret <secret>

Secret required to access the server

--clone-root <clone_root>

Where to clone repositories (default: ./repos)

--cloud-server <cloud_server>

Unfurl Cloud server URL to connect to.

--cors <cors>

enable CORS with origin (e.g. “*”)

Arguments

PROJECT_OR_ENSEMBLE_PATH

Optional argument

Environment variables

UNFURL_SERVE_PATH

Provide a default for PROJECT_OR_ENSEMBLE_PATH

UNFURL_SERVE_SECRET

Provide a default for --secret

UNFURL_CLONE_ROOT

Provide a default for --clone-root

UNFURL_CLOUD_SERVER

Provide a default for --cloud-server

UNFURL_SERVE_CORS

Provide a default for --cors

status

Show the status of deployed resources in the given ensemble.

(Use global -v for verbose display.)

unfurl status [OPTIONS] [ENSEMBLE]

Options

--query <query>

Run the given expression

--trace <trace>

Set the query’s trace level

--use-environment <use_environment>

Use this environment.

Arguments

ENSEMBLE

Optional argument

stop

Stop running instances.

unfurl stop [OPTIONS] [ENSEMBLE]

Options

--var <var>

name/value pair to pass to job (multiple times ok).

--use-environment <use_environment>

Run this job in the given environment.

--force

(Re)run operation regardless of instance’s status or state

--starttime <starttime>

Set the start time of the job.

--output <output>

How to print summary of job run

Options

text | json | none

--trace <trace>

Set the query’s trace level

--query <query>

Run the given expression upon job completion

--instance <instance>

instance name to target

--template <template>

TOSCA template to target

-a, --approve

Don’t prompt for approval to apply changes.

--jobexitcode <jobexitcode>

Set exit code to 64 if job ends at given status. (Default: never)

Options

error | degraded | never

-m, --message <message>

commit message to use

--dirty <dirty>

Action if there are uncommitted changes before run. (Default: auto)

Options

abort | ok | auto

--push

Push after committing. (Default: false)

--commit

Commit modified files to the ensemble repository. (Default: false)

--dryrun

Do not modify anything, just do a dry run.

Arguments

ENSEMBLE

Optional argument

Environment variables

UNFURL_APPROVE

Provide a default for -a

undeploy

Destroy what was deployed.

unfurl undeploy [OPTIONS] [ENSEMBLE]

Options

--var <var>

name/value pair to pass to job (multiple times ok).

--use-environment <use_environment>

Run this job in the given environment.

--force

(Re)run operation regardless of instance’s status or state

--starttime <starttime>

Set the start time of the job.

--output <output>

How to print summary of job run

Options

text | json | none

--trace <trace>

Set the query’s trace level

--query <query>

Run the given expression upon job completion

--instance <instance>

instance name to target

--template <template>

TOSCA template to target

-a, --approve

Don’t prompt for approval to apply changes.

--jobexitcode <jobexitcode>

Set exit code to 64 if job ends at given status. (Default: never)

Options

error | degraded | never

-m, --message <message>

commit message to use

--dirty <dirty>

Action if there are uncommitted changes before run. (Default: auto)

Options

abort | ok | auto

--push

Push after committing. (Default: false)

--commit

Commit modified files to the ensemble repository. (Default: false)

--dryrun

Do not modify anything, just do a dry run.

--destroyunmanaged

include unmanaged instances for consideration when destroying

Arguments

ENSEMBLE

Optional argument

Environment variables

UNFURL_APPROVE

Provide a default for -a

validate

Validate the given ensemble.

unfurl validate [OPTIONS] [ENSEMBLE]

Arguments

ENSEMBLE

Optional argument

version

Print the current version

unfurl version [OPTIONS]

Options

--semver

Print only the semantic version

--remote

Also print the version installed in the current runtime.