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.

devops
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 footguns
breakingPulp CLI is currently in 'beta' status. Future releases may introduce backwards-incompatible changes, which could break existing scripts or automation.
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.
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.
Upgrade
Version history

Breaking-change detection hasn't run for this library yet.

Audit
Security & dependencies

CVE tracking and dependency tree are planned for a later release.

Agent activity
10 hits · last 30 days
ahrefsbot
4
gptbot
3
script
1
googlebot
1
chatgpt-user
1
Resources