Registry / devops / pulp-cli

pulp-cli

JSON →
library0.39.0pypypiunverified

Pulp CLI is a command-line interface for managing Pulp 3 resources and interacting with Pulpcore's REST API. It serves as a client for various Pulp plugins (e.g., pulp_ansible, pulp_file, pulp_rpm) to perform tasks like listing repositories, synchronizing content, and managing distributions. Currently at version 0.39.0, the library is under active development, and its status is considered 'beta', implying that future releases may introduce backwards-incompatible changes.

pip install pulp-cli
INSTALL
IMPORT
SIG · PULP-CLI
P
pulp-cli
devopspythonv0.39.0
harness data pending
Install & Compatibility
Where this runs

No compatibility data collected yet for this library.

Code
Verified usage

The Pulp CLI requires initial configuration to connect to a Pulp 3 server. This typically involves setting the base URL, username, and password, which can be done via `pulp config create` or environment variables. After configuration, you can verify the connection with `pulp status` and interact with various Pulp resources.

import os # Configure Pulp CLI. This creates or updates ~/.config/pulp/cli.toml # In a real scenario, avoid hardcoding credentials. Use environment variables or a .netrc file. # Example using environment variables: # export PULP_BASE_URL="http://localhost:8080" # export PULP_USERNAME="admin" # export PULP_PASSWORD="password" base_url = os.environ.get('PULP_BASE_URL', 'http://localhost:8080') username = os.environ.get('PULP_USERNAME', 'admin') password = os.environ.get('PULP_PASSWORD', 'password') # This command is meant to be run in a shell, not directly via Python subprocess # For demonstration, it's shown as a shell command. print(f"Setting up Pulp CLI configuration for {base_url}...") print(f"pulp config create --base-url {base_url} --username {username} --password {password}") # To verify connection and list available repositories print("\nVerifying Pulp server status:") print("pulp status") print("\nListing file repositories (example):") print("pulp file repository list") # To see full help for a command: print("\nTo view full help for the 'pulp' command:") print("pulp --help")
pulp --version
Debug
Known issues
breakingPulp CLI is currently in 'beta' status. Future releases may introduce backwards-incompatible changes, which could break existing scripts or automation.
fix
Regularly consult the official Changelog (e.g., on GitHub) before upgrading and test new versions in a non-production environment.
affects: All versions, due to ongoing beta status.
gotchaFor certain integrations, Pulp CLI is primarily read-only. Attempts to perform write operations (add, update, delete content) may result in an 'Error: Call aborted due to safe mode' message and a non-zero exit code.
fix
If write operations are required and supported by your Pulp setup, append `--force` to the command, or use alternative tools like orcharhino management UI, Hammer CLI, or Foreman Ansible Modules for specific content types.
affects: All versions, depending on the Pulp server configuration and integrated tools.
deprecatedSeveral options for `pulp_rpm` commands, including `--package-checksum-type`, `--metadata-checksum-type`, `--gpgcheck`, and `--repo-gpgcheck`, have been removed in version 0.33.0.
fix
Update scripts to remove these deprecated options. Consult the `pulp_rpm` plugin documentation for current best practices for checksum and GPG handling.
affects: >=0.33.0
Errors
Common errors & fixes
Error: Call aborted due to safe mode
Attempting to perform a write or modify operation (e.g., `pulp rpm repository update`) when the Pulp CLI, or the underlying Pulp server, is configured in a read-only 'safe mode' for that operation context.
fix
If the operation is intended and safe mode can be overridden, append the `--force` global option to your Pulp CLI command (e.g., `pulp --force rpm repository update ...`).
Error: {'detail': 'Authentication credentials were not provided.'}
The Pulp CLI failed to authenticate with the Pulp server. This can be due to incorrect username/password, missing API tokens, issues with client certificates, or an inaccessible identity provider.
fix
Verify that your `~/.config/pulp/cli.toml` or environment variables (e.g., `PULP_USERNAME`, `PULP_PASSWORD`, `PULP_TOKEN`) contain correct and active credentials. If using client certificates, ensure `--cert` and `--key` paths are correct and the server accepts them. Test basic connectivity with `pulp status`, which doesn't require authentication.
requests.exceptions.SSLError: [SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed
The Python environment or Pulp CLI is unable to verify the SSL certificate of the Pulp server, often because the server uses a self-signed certificate or a CA certificate not trusted by the client system.
fix
Provide the path to your CA certificate bundle using the `--ca-cert` global option (e.g., `pulp --ca-cert /path/to/ca.crt ...`) or by setting the `PULP_CA_BUNDLE` environment variable. Alternatively, for testing *only*, you can disable SSL verification with `--no-verify-ssl` (not recommended for production).
Upgrade
Version history
0.39.0latest on PyPI · released Apr 8, 2026
Audit
Dependencies
pythonrequiredRequired Python interpreter version for pulp-cli.
Agent activity
9 hits · last 30 days
node
8
Resources
pulp-cli — pip install pulp-cli · libregistry