delete

Remove specific content from one or more Pulp repository

usage: pubtools-pulp-delete [-h] [--debug] [--udcache-url UDCACHE_URL]
                            [--udcache-user UDCACHE_USER]
                            [--udcache-password UDCACHE_PASSWORD]
                            [--udcache-certificate UDCACHE_CERTIFICATE]
                            [--udcache-certificate-key UDCACHE_CERTIFICATE_KEY]
                            [--pulp-url PULP_URL] [--pulp-user PULP_USER]
                            [--pulp-password PULP_PASSWORD]
                            [--pulp-certificate PULP_CERTIFICATE]
                            [--pulp-certificate-key PULP_CERTIFICATE_KEY]
                            [--pulp-insecure] [--pulp-throttle PULP_THROTTLE]
                            [--pulp-fake] [--clean] [--force] [--repo REPO]
                            [--advisory ADVISORY] [--file FILE]
                            [--signing-key SIGNING_KEY] [--allow-unsigned]
                            [--skip SKIP]

Named Arguments

--debug, -d

Show debug logs; can be provided up to three times to enable more logs

Default: 0

--repo

remove content from these comma-seperated repositories. If ‘*’ is used, the package will be removed from all repos, excluding all-rpm-content-* repos. These may be added separately.

--advisory

remove packages and modules in these comma-separated advisories

--file

remove these comma-separated rpm, srpm, modulemd or iso file(s)

--signing-key

remove the content with these signing-keys(s)

--allow-unsigned

remove unsigned content

Default: False

--skip

skip given comma-separated sub-steps

Unified Downloads Cache environment

--udcache-url

Base URL of UD cache flush API; if omitted, UD cache flush features are disabled.

--udcache-user

Username for UD cache flush

--udcache-password

Password for UD cache flush (or set UDCACHE_PASSWORD)

Default: “”

--udcache-certificate

Client certificate for UD cache flush (or set UDCACHE_CERT)

Default: “”

--udcache-certificate-key

Client key for UD cache flush (or set UDCACHE_KEY)

Default: “”

Pulp environment

--pulp-url

Pulp server URL

--pulp-user

Pulp username

--pulp-password

Pulp password (or set PULP_PASSWORD environment variable)

--pulp-certificate

Pulp certificate. Can also be a single file (.pem)

--pulp-certificate-key

Pulp certificate key

--pulp-insecure

Allow unverified HTTPS connection to Pulp

Default: False

--pulp-throttle

Allows to enqueue or run only specified number of Pulp tasks at one moment (or set PULP_THROTTLE environment variable)

--pulp-fake

Use a fake in-memory Pulp client rather than interacting with a real server. For development/testing only, may have limited functionality.

Default: False

Publish options

Options affecting the behavior of Pulp repo publishes.

--clean

attempt to delete remote content not in the repo

Default: False

--force

force publish of repos even if Pulp thinks nothing has changed

Default: False

Example: File

A typical invocation of delete file would look like this:

pubtools-pulp-delete \
  --pulp-url https://pulp.example.com/ \
  --pulp-user admin \
  --pulp-password XXXXX \
  --file some-pkg-1.3-1.el8_x86_64.rpm \
  --signing-key aabbcc \
  --repo some-yumrepo

Mentioned file with the signing key will be removed from the repo. If there are multiple files and repos, each file will be removed from the repos they belong to. All those repos will then be published.

Example: Mix file types

File provided in `--file` could either be a RPM(rpm name), ISO(filename) or ModuleMD(N:S:V:C:A) file. Different file types could be included in the same command.

pubtools-pulp-delete \
  --pulp-url https://pulp.example.com/ \
  --pulp-user admin \
  --pulp-password XXXXX \
  --file some-pkg-1.3-1.el8_x86_64.rpm \
  --file some-file.iso,some-modmd:s1:123:a1c2:s390x \
  --signing-key aabbcc \
  --repo some-yumrepo \
  --repo some-filerepo

Signing key will be used wherever applicable.

Example: Advisory

Packages from an advisory could be removed by providing the advisory ID and the repos to be removed from. All the packages and the modules that were pushed to the provided repos as part of the advisory will be removed.

pubtools-pulp-delete \
  --pulp-url https://pulp.example.com/ \
  --pulp-user admin \
  --pulp-password XXXXX \
  --advisory RHBA-2020:1234 \
  --repo some-yumrepo \
  --repo some-filerepo

Example: Mix files and advisory

Removing files and packages from the advisory could be requested in the same request. They will be removed from the provided applicable repos.

pubtools-pulp-delete \
  --pulp-url https://pulp.example.com/ \
  --pulp-user admin \
  --pulp-password XXXXX \
  --advisory RHBA-2020:1234 \
  --file some-pkg-1.3-1.el8_x86_64.rpm \
  --file some-file.iso,some-modmd:s1:123:a1c2:s390x \
  --signing-key aabbcc \
  --repo some-yumrepo
  --repo some-filerepo

Example: Skip publish

The repos are published and the caches are cleaned(provided required arguments) by default. This can skipped by providing `--skip` option with the publish step name i.e. `--skip publish`

pubtools-pulp-delete \
  --pulp-url https://pulp.example.com/ \
  --pulp-user admin \
  --pulp-password XXXXX \
  --file some-pkg-1.3-1.el8_x86_64.rpm \
  --signing-key aabbcc \
  --repo some-yumrepo \
  --skip publish