Install and Use the Codiac CLI
Learn how to install and use the Codiac command-line interface (CLI). This tool is useful for those who prefer not to use the web-based Codiac UI.
The codiac
command is automatically aliased to cod
to save typing. For example, you can type cod -h
instead of codiac -h
.
Prerequisites
- Basic Codiac Prerequisites
- Node.js version 20.13.1 or later.
- npm version 10.5.2 or later.
- Docker version 26.1.3 or later.
Install the Codiac CLI
Use npm to install the codiac-cli
package:
npm i -g @codiac.io/codiac-cli
Authenticate with the CLI
Before you access Codiac, you need to authenticate your session.
- Use
codiac login
to log into Codiac:
codiac login
The command prompts you to authenticate with your Codiac username and password.
- Use
codiac csp login
to log into your cloud service provider:
codiac csp login
The command prompts you to:
- Authenticate with your Codiac username and password.
- Select your tenant.
- Select the cloud provider for your project.
The CLI then authenticates with your cloud provider.
Update the CLI
Use NPM to update the Codiac CLI:
npm i -g @codiac.io/codiac-cli
Use codiac -v
to check the version number:
CLI Help
Use the -h
flag to view the help documentation for the CLI commands. For example:
codiac -h
codiac asset -h
codiac asset view -h
You can also consult the reference list of CLI commands to view the same details in a browser.