Skip to content

Commit

Permalink
clarifying a dir path is required for custom policies (aquasecurity#4716
Browse files Browse the repository at this point in the history
)

Signed-off-by: AnaisUrlichs <urlichsanais@gmail.com>
  • Loading branch information
AnaisUrlichs committed Jun 26, 2023
1 parent fbab9ee commit 8a1aa44
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 1 deletion.
3 changes: 3 additions & 0 deletions docs/docs/scanner/misconfiguration/custom/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,9 @@ Once you finish writing custom policies, you can pass the directory where those
trivy conf --policy /path/to/custom_policies --namespaces user /path/to/config_dir
```

!!! Tip
Note: The `--policy` path always needs to refer to a directory. You cannot pass a specific policy file.

As for `--namespaces` option, the detail is described as below.

### File formats
Expand Down
3 changes: 2 additions & 1 deletion docs/docs/scanner/misconfiguration/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -327,7 +327,8 @@ trivy conf --policy custom-policy/policy --policy combine/policy --namespaces us
For more details, see [Custom Policies](./custom/index.md).

!!! tip
You also need to specify `--namespaces` option.
You also need to specify `--namespaces` option.
Furthermore, the `--policy` path always needs to refer to a directory. You cannot pass a specific policy file.

### Pass custom data
You can pass directories including your custom data through `--data` option.
Expand Down

0 comments on commit 8a1aa44

Please sign in to comment.