Alauda Container Security provides the roxctl
CLI to help you check deployment YAML files and container images for policy compliance. This guide explains how to use roxctl
for these checks and interpret the results.
Set the ROX_ENDPOINT
environment variable:
Replace <host:port>
with the address of your Alauda Container Security Central instance.
When running roxctl deployment check
or roxctl image check
, you can specify the output format using the -o
option. Supported formats are json
, table
, csv
, and junit
. If not specified, the default is table
for deployment and image checks, and json
for image scans.
The following table summarizes the available output options:
Option | Description | Formats |
---|---|---|
--compact-output | Display JSON output in a compact format. | json |
--headers | Specify custom headers. | table , csv |
--no-header | Omit the header row from the output. | table , csv |
--row-jsonpath-expressions | Use GJSON paths to select specific data. | table , csv |
--merge-output | Merge table cells with the same value. | table |
headers-as-comment | Include the header row as a comment in the output. | csv |
--junit-suite-name | Specify the name of the JUnit test suite. | junit |
To check build-time and deploy-time policy violations in your deployment YAML files, run:
<yaml_filename>
: Path to the deployment YAML file(s). You can specify multiple files by repeating the --file
flag.<cluster_namespace>
: (Optional) Namespace for context. Default is default
.<cluster_name_or_id>
: (Optional) Cluster name or ID for context.--verbose
: (Optional) Show additional information, such as RBAC permissions and network policies.Note: Additional deployment information is included in JSON output, regardless of the
--verbose
flag.
To force Alauda Container Security to re-pull image metadata and scan results, add the --force
option.
Permission Requirement:
To check specific image scan results, your token must have bothread
andwrite
permissions for theImage
resource. The default Continuous Integration system role includes these permissions.
The deployment check validates:
To check build-time policy violations in images, run:
To force Alauda Container Security to re-pull image metadata and scan results, add the --force
option.
Permission Requirement:
To check specific image scan results, your token must have bothread
andwrite
permissions for theImage
resource. The default Continuous Integration system role includes these permissions.
To view the components and vulnerabilities found in an image in JSON format, run:
To force Alauda Container Security to re-pull image metadata and scan results, add the --force
option.
Permission Requirement:
To check specific image scan results, your token must have bothread
andwrite
permissions for theImage
resource. The default Continuous Integration system role includes these permissions.