The push
command allows you to push content to a Structurizr workspace (the cloud service or an on-premises installation). The command operates as follows:
- Pull the existing workspace, OR parse the specified DSL file to create a new workspace.
- Clear existing documentation and decisions from the workspace.
- Import documentation and/or decisions into the workspace.
- Push the workspace.
- -id: The workspace ID (required)
- -key: The workspace API key (required)
- -secret: The workspace API secret (required)
- -workspace: The path to the workspace JSON file/DSL file(s) (required)
- -docs: The path to the directory containing Markdown/AsciiDoc files to be published (optional)
- -adrs: The path to the directory containing ADRs (optional)
- -url: The Structurizr API URL (optional; defaults to
https://api.structurizr.com
) - -passphrase: The passphrase to use (optional; only required if client-side encryption enabled on the workspace)
- -merge: Whether to merge layout information from the remote workspace (optional; defaults to
true
)
When the -docs
option is used, the push
command will import all Markdown and AsciiDoc files in this directory (and sub-directories), alphabetically according to the filename. Each file must represent a separate documentation section, and the second level heading (## Section Title
in Markdown and == Section Title
in AsciiDoc) will be used as the section name.
When the -adrs
option is used, the push
command will import all Markdown and AsciiDoc files in this directory. The files must have been created by adr-tools, or at least follow the same format.
To push a directory of Markdown and/or AsciiDoc files as documentation to an existing Structurizr workspace:
java -jar structurizr-cli-*.jar push -id 40120 -key 1a130d2b... -secret a9daaf3e... -docs docs
To push a directory of ADRs as decision records to an existing Structurizr workspace:
java -jar structurizr-cli-*.jar push -id 40120 -key 1a130d2b... -secret a9daaf3e... -adrs adrs