Skip to content

Commit

Permalink
docs(general): add --repo-id to relevant examples with API key (#6605)
Browse files Browse the repository at this point in the history
add --repo-id to relevant examples with API key
  • Loading branch information
mikeurbanski1 authored Jul 25, 2024
1 parent 6ad3b69 commit a0d4ecd
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 8 deletions.
10 changes: 5 additions & 5 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -251,14 +251,14 @@ checkov -d . --skip-check kube-system
Run a scan of a container image. First pull or build the image then refer to it by the hash, ID, or name:tag:
```sh
checkov --framework sca_image --docker-image sha256:1234example --dockerfile-path /Users/path/to/Dockerfile --bc-api-key ...
checkov --framework sca_image --docker-image sha256:1234example --dockerfile-path /Users/path/to/Dockerfile --repo-id ... --bc-api-key ...
checkov --docker-image <image-name>:tag --dockerfile-path /User/path/to/Dockerfile --bc-api-key ...
checkov --docker-image <image-name>:tag --dockerfile-path /User/path/to/Dockerfile --repo-id ... --bc-api-key ...
```
You can use --image flag also to scan container image instead of --docker-image for shortener:
```sh
checkov --image <image-name>:tag --dockerfile-path /User/path/to/Dockerfile --bc-api-key ...
checkov --image <image-name>:tag --dockerfile-path /User/path/to/Dockerfile --repo-id ... --bc-api-key ...
```
Run an SCA scan of packages in a repo:
Expand All @@ -278,12 +278,12 @@ checkov -d .
Run secrets scanning on all files in MyDirectory. Skip CKV_SECRET_6 check on json files that their suffix is DontScan
```sh
checkov -d /MyDirectory --framework secrets --bc-api-key ... --skip-check CKV_SECRET_6:.*DontScan.json$
checkov -d /MyDirectory --framework secrets --repo-id ... --bc-api-key ... --skip-check CKV_SECRET_6:.*DontScan.json$
```
Run secrets scanning on all files in MyDirectory. Skip CKV_SECRET_6 check on json files that contains "skip_test" in path
```sh
checkov -d /MyDirectory --framework secrets --bc-api-key ... --skip-check CKV_SECRET_6:.*skip_test.*json$
checkov -d /MyDirectory --framework secrets --repo-id ... --bc-api-key ... --skip-check CKV_SECRET_6:.*skip_test.*json$
```
One can mask values from scanning results by supplying a configuration file (using --config-file flag) with mask entry.
Expand Down
4 changes: 2 additions & 2 deletions docs/7.Scan Examples/Git History.md
Original file line number Diff line number Diff line change
Expand Up @@ -20,12 +20,12 @@ Use `--secrets-history-timeout` to set how long the secrets scan will run on his

A run with a timeout of `12h` by default:
```bash
checkov -d <git dir> --scan-secrets-history --bc-api-key <your_api_key>
checkov -d <git dir> --scan-secrets-history --bc-api-key <your_api_key> --repo-id <repo/name>
```

A run with a timeout of `1h`:
```bash
checkov -d <git dir> --scan-secrets-history --secrets-history-timeout 1h --bc-api-key <your_api_key>
checkov -d <git dir> --scan-secrets-history --secrets-history-timeout 1h --bc-api-key <your_api_key> --repo-id <repo/name>
```

### Example output
Expand Down
2 changes: 1 addition & 1 deletion docs/7.Scan Examples/Sca.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ In order to use this feature, you first need to create an [API token using Prism

## Package scanning
```bash
checkov -d . --framework sca_package --bc-api-key <access key>::<secret key> --prisma-api-url <prisma api url>
checkov -d . --framework sca_package --bc-api-key <access key>::<secret key> --prisma-api-url <prisma api url> --repo-id <repo/name>
```

### Example output
Expand Down

0 comments on commit a0d4ecd

Please sign in to comment.