Skip to content

Commit b6e9eee

Browse files
committed
Fix pulp-cli commands on vuln report docs
It was using a non-existent command before.
1 parent e28456f commit b6e9eee

2 files changed

Lines changed: 15 additions & 7 deletions

File tree

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
Fixed CLI commands in the vulnerability report documentation to use `pulp repository version scan`. The command previously shown there (`pulp vulnerability-report create`) doesn't exit.

‎docs/user/guides/vulnerability_report.md‎

Lines changed: 14 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,13 @@
11
# Vulnerability Report
22

33
Pulp Python provides vulnerability scanning capabilities to help you identify known security
4-
vulnerabilities in your Python packages. This feature integrates with the [Open Source Vulnerabilities (OSV)](https://osv.dev/)
4+
vulnerabilities in your Python packages.
5+
This feature integrates with the [Open Source Vulnerabilities (OSV)](https://osv.dev/)
56
database to scan Pulp `RepositoryVersions` for vulnerable packages.
67

8+
!!! info "New in `pulp_python>=3.21.0`"
9+
!!! info "New in `pulp-cli>=0.37.0` (optional)"
10+
711
## Prerequisites
812

913
Before generating the vulnerability report, ensure that:
@@ -13,11 +17,14 @@ Before generating the vulnerability report, ensure that:
1317

1418
## Generating a vulnerability report
1519

16-
To scan a `RepositoryVersion` for vulnerabilities, you need to pass the name of the repository and
17-
optionally the version:
20+
To scan a `RepositoryVersion` for vulnerabilities, call the `scan` command on a repository version.
1821

1922
```bash
20-
pulp vulnerability-report create --repository my-repo --version 1
23+
# Use the latest version
24+
pulp python repository version scan --repository my-repo
25+
26+
# Or specify a version
27+
pulp python repository version scan --repository my-repo --version 1
2128
```
2229

2330
## Understanding Scan Results
@@ -70,7 +77,7 @@ To view the actual vulnerability data, retrieve the vulnerability report:
7077

7178
```bash
7279
# Get vulnerability report details
73-
pulp vulnerability-report show --href ${VULN_REPORT_HREF}
80+
pulp show --href ${VULN_REPORT_HREF}
7481
```
7582

7683
The report contains detailed information about each vulnerability, including:
@@ -111,9 +118,9 @@ pulp python repository sync \
111118
--remote pypi-remote
112119

113120
# 4. Scan for vulnerabilities
114-
pulp vulnerability-report create --repository security-scan-repo
121+
pulp python repository version scan --repository security-scan-repo
115122

116123
# 5. View the vulnerability report
117124
VULN_REPORT=$(pulp python repository version show --repository security-scan-repo | jq -r '.vuln_report')
118-
pulp vulnerability-report show --href $VULN_REPORT
125+
pulp show --href $VULN_REPORT
119126
```

0 commit comments

Comments
 (0)