CLI Reference
Auth
The Auth command allows you to log in and out of Codezero.
Usage
czctl auth [SUB-COMMAND]
Examples
czctl auth login
Sub-commands
Sub-command | Description |
---|---|
login | Login to Codezero |
logout | Logout from Codezero |
Flags
Flags | Description |
---|---|
--token | If set, app will not try to open a browser window for login and will use the provided token. |
Cleanup
Cleans the system changes performed by Codezero daemon. Can help if daemon did not exit gracefully to bring back your network settings.
Usage
czctl cleanup
Completion
Generate the autocompletion script for czctl for the specified shell.
See each sub-command's help for details on how to use the generated script.
Usage
czctl completion [SUB-COMMAND]
Sub-commands
Sub-command | Description |
---|---|
bash | Generate the autocompletion script for bash |
fish | Generate the autocompletion script for fish |
powershell | Generate the autocompletion script for powershell |
zsh | Generate the autocompletion script for zsh |
Example
To load zsh completions in your current shell session:
source <(czctl completion zsh)
Compose
Applies all the serve sessions/consume rules from a compose file.
Usage
czctl compose start
Flags
Flags | Description |
---|---|
--file | Path to the compose file (default "codezero-compose.yaml") |
Consume
Manage consume rules.
All
Consume all services.
Usage
czctl consume all
Apply
Apply consume rules from a file.
Usage
czctl consume apply source_file [flags]
Flags
Flags | Description |
---|---|
--primary-namespace | The primary namespace used for services consume |
Edit
Edit consume rules.
Usage
czctl consume edit
List
List consumed services.
Usage
czctl consume list
View
View consume rules.
Usage
czctl consume view
Daemon
Manage Codezero daemon.
Usage
czctl daemon [SUB-COMMAND]
Example
czctl daemon start
Sub-commands
Sub-command | Description |
---|---|
install | Install the Codezero daemon as a background service |
restart | Restart the Codezero daemon |
run | Run the Codezero daemon in the foreground |
start | Start the Codezero daemon |
stop | Stop the Codezero daemon |
uninstall | Uninstall the Codezero daemon background service |
Organization
Manage Organizations.
List
List organizations
Usage
czctl organization list
Select
Changes the current organization
You can use this command to change the current organization. If you don't provide a name or there are multiple spaces with the same name, you will be interactively prompted to select one.
Usage
czctl organization select [organization name] [flags]
Examples
czctl organization select MyOrg
Arguments
Arguments | Description |
---|---|
organization name | The name of the organization. |
Flags
Flags | Description |
---|---|
--id string | Select by organization ID |
Primary Namesapce
Manage primary namespace.
Clear
Clear the currently selected primary namespace.
Usage
czctl primary-namespace clear
Select
Change the current primary namespace.
Usage
czctl primary-namespace select [namespace]
Examples
czctl primary-namespace select sample-project
Arguments
Arguments | Description |
---|---|
namespace | The name of the Kubernetes namespace. |
Reset
Removes all consume and serve sessions.
Usage
czctl reset
Restart
Restarts the Codezero daemon if it is running. If it is not running, does nothing.