Pulp CLI Console
A command-line interface for Pulp, providing console administrative functionality.
Table of Contents
Overview
The Pulp CLI Console provides a set of commands to manage Pulp resources from the command line. It extends the base Pulp CLI functionality with console-specific administrative tools for system operators and administrators.
The console offers capabilities for task management, vulnerability scanning, system monitoring, and more, all through a unified command-line interface.
Requirements
- Python 3.8 or higher
- Access to a Pulp 3.x server
- Network connectivity to your Pulp server
- Appropriate user permissions on the Pulp server
Installation
You can install the Pulp CLI Console using pip:
pip install pulp-cli-console
For development or the latest features, you can install directly from the repository:
pip install git+https://github.com/pulp/pulp-cli-console.git
Configuration
Basic Configuration
The Pulp CLI Console requires configuration to connect to your Pulp server. Create a configuration file at ~/.config/pulp/cli.toml:
[cli]
base_url = "https://pulp.example.com"
verify_ssl = true
format = "json"
timeout = 30
username = "admin"
password = "password" # Consider using environment variables instead
Advanced Options
You can customize various aspects of the CLI behavior:
[cli]
base_url = "https://pulp.example.com"
verify_ssl = true
cert = "/path/to/client/cert.pem" # Optional client certificate
key = "/path/to/client/key.pem" # Optional client key
ca_cert = "/path/to/ca/cert.pem" # Custom CA certificate
format = "json" # Output format: json, yaml, or none
timeout = 60 # Request timeout in seconds
limit = 100 # Default pagination limit
interactive = true # Enable interactive prompts
quiet = false # Suppress non-error output
verbose = 0 # Verbosity level (0-3)
# Use one of the following authentication methods
username = "admin"
password = "password"
token = "your-api-token" # API token authentication
refresh_token = "refresh-token" # For OAuth2 refresh token flow
Environment Variables
You can also use environment variables for configuration, which is recommended for sensitive information:
# Base configuration
export PULP_BASE_URL="https://pulp.example.com"
export PULP_VERIFY_SSL="true"
# Authentication
export PULP_USERNAME="admin"
export PULP_PASSWORD="password"
# Alternative authentication
export PULP_TOKEN="your-api-token"
Usage
Task Management
The CLI provides commands for managing administrative tasks:
# List all tasks
pulp console task list
# Filter tasks by state
pulp console task list --state=completed
# List tasks with pagination
pulp console task list --limit=10 --offset=20
# Filter tasks by name
pulp console task list --name="sync" --name-contains="content"
# Filter tasks by time
pulp console task list --started-at-gte="2023-01-01T00:00:00Z"
# Show detailed information for a specific task
pulp console task show --href=/pulp/api/v3/tasks/1234abcd/
# Cancel a running task
pulp console task cancel --href=/pulp/api/v3/tasks/1234abcd/
Available Filters for Tasks
--limit: Limit the number of tasks shown--offset: Skip a number of tasks--name: Filter by task name--name-contains: Filter tasks containing this name--logging-cid-contains: Filter by logging correlation ID--state: Filter by task state--state-in: Filter by multiple states (comma-separated)--task-group: Filter by task group--parent-task: Filter by parent task--worker: Filter by worker--created-resources: Filter by created resources--started-at-gte/--started-at-lte: Filter by start time--finished-at-gte/--finished-at-lte: Filter by finish time--reserved-resource/--reserved-resource-in: Filter by reserved resources--exclusive-resource/--exclusive-resource-in: Filter by exclusive resources--shared-resource/--shared-resource-in: Filter by shared resources
Vulnerability Management
The CLI provides commands for managing vulnerability reports:
# List vulnerability reports
pulp console vulnerability list
# Show a specific vulnerability report
pulp console vulnerability show --href=/api/pulp/vulnerability-reports/123/
# Create a vulnerability report
pulp console vulnerability create --file=/path/to/packages.json
Vulnerability Commands
list: List all vulnerability reportsshow: Display details of a specific vulnerability reportcreate: Create a new vulnerability report from a JSON file
Options for Vulnerability Commands
--href: Reference to a specific vulnerability report (for show command)--file: JSON file containing npm packages (required for create command)--chunk-size: Size of chunks for uploading files (for create command)--severity: Filter by vulnerability severity (critical, high, medium, low)--status: Filter by status (open, in-progress, resolved, false-positive)
Performance Monitoring
# Get system performance metrics
pulp console monitor performance
# View resource utilization
pulp console monitor resources
# Check Pulp server health
pulp console monitor health
Troubleshooting
Common Issues
Metadata
Release files for pulp-cli-console 0.1.7
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| pulp_cli_console-0.1.7.tar.gz | 8.1 kB | Without provenance | Details for pulp_cli_console-0.1.7.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| pulp_cli_console-0.1.7-py3-none-any.whl | Python 3 | none | any | Details for pulp_cli_console-0.1.7-py3-none-any.whl |
Total release size: 16.0 kB
Release files / pulp_cli_console-0.1.7.tar.gz
| Download URL | pulp_cli_console-0.1.7.tar.gz |
|---|---|
| Size | 8.1 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
1fdf7d3e923445e200bb59b02877f4a4c302c208dc409c7eca4daf1f473b1386
|
|
BLAKE2b-256 checksum How to use checksums |
1d09fd79b45994d2c2cc4671cc94bab961a17c0a2cacd9490fa8c5b4b8cba98f
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/7.0.0 CPython/3.14.7
|
Release files / pulp_cli_console-0.1.7-py3-none-any.whl
| Download URL | pulp_cli_console-0.1.7-py3-none-any.whl |
|---|---|
| Size | 8.0 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
dc5ebc6b3f3e7d815bf07f568ffc6f7e31bcc6a63588a56ecc0cf23b254d74e7
|
|
BLAKE2b-256 checksum How to use checksums |
d6b127414bdd44643f8b63f14bac69e053d94b947bd066523cb823ddb2db2ff6
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/7.0.0 CPython/3.14.7
|
Security for pulp-cli-console 0.1.7
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.