Katello publishes deb packages under default/all distribution/component names but foreman-proxy expects the repo proper name (like focal/main or bionic name)

Problem:
I’ve got below messages while trying to sync ubuntu packages to foreman proxy server, but according to below foreman-proxy expects the real distro/component names (focal/main or bionic/main)
ATIX, can you help?

Apr 22 05:59:47 prx01 pulp: nectar.downloaders.threaded:INFO: Download failed: Download of http://kat01.domain.local/pulp/deb/COMPANY/Library/custom/Ubuntu_20/ubuntu_20_main/dists/focal/Release failed with code 404: Not Found
Apr 22 05:59:47 prx01 pulp: nectar.downloaders.threaded:INFO: Download failed: Download of http://kat01.domain.local/pulp/deb/COMPANY/Library/custom/Ubuntu_20/ubuntu_20_main/dists/focal/Release.gpg failed with code 404: Not Found

below URL is available (which is default/all distro/component) instead of proper names (focal/main):
http://kat01.domain.local/pulp/deb/COMPANY/Library/custom/Ubuntu_20/ubuntu_20_restricted/dists/default/all

Expected outcome:

at the moment no ubuntu package can be synced to foreman-proxy due to this issue

Foreman and Proxy versions:

kat01.domain.local Pulp, Pulpcore, TFTP, Puppet CA, Puppet, Logs, HTTPBoot, and Registration 2.3.3
prx01.domain.local Pulp Node, Templates, Puppet CA, Puppet, Logs, and Registration 2.3.3

Foreman and Proxy plugin versions:

katello server:

HTTPBoot

Version

2.3.3

Pulp

Version

2.1.0

Pulp server version

2.21.5

Database connection

Messaging connection

Workers

4

Supported Content Types

  • puppet

Pulpcore

Version

2.1.0

Supported Content Types

  • deb
  • docker
  • file
  • yum

Registration

Version

2.3.3

TFTP

Version

2.3.3

TFTP server

192.168.122.188

foreman-proxy

Pulp node

Version

2.1.0

Pulp server version

2.21.5

Database connection

Messaging connection

Workers

4

Supported Content Types

  • deb
  • docker
  • file
  • puppet
  • yum

Registration

Version

2.3.3

Templates

Version

2.3.3

Distribution and version:
centos 7.9

Other relevant data:

Ok, there are several aspects to this that need to be explored more or less independently of one another:

Pulp 2 vs Pulp 3 publish considerations

It looks like you are using Pulp 3 for deb (but I am not 100% sure).

Both Pulp 2 and Pulp 3 can be used to publish what we call “simple” mode (using the dists/default/all path) as well as “structured” mode (using upstream paths like dists/focal/). Pulp can even publish both sets of paths for the same repository (which would work as a workaround for your issue). However, for Pulp 2 it is a matter of configuration file options, which combination of paths is published, while for Pulp 3 it is a matter of what parameters are passed to the API. This means that the Pulp 2 case is within user control (configuration file), while for Pulp 3, Katello is currently hard coded to publish using simple mode only (@mbucher is that correct?).

Smart Proxy considerations:

I was under the impression that the smart proxy sync was hard coded to use “simple” paths only. Your problem indicates that this is not (or no longer) the case. This clashes with my memory of an explicit design choice we made, so I we will need to investigate. If current Katello publishes using a path, that current pulp proxy does not use for sync, then that is of course a bug. If you are on Pulp 2 you can work around that bug by configuring Pulp to use the right publish paths for the proxy. For Pulp 3 that would require changes to the Katello code.

@quba42 thanks so much for your reply
According to the information I provided before, katello server uses pulpcore which is pulp3 and foreman proxy uses pulp2. As I read in the other posts, changing Ubuntu packages from default/all to real names like focal/main can cause issues with subscription manager. Not sure if we can reconfigure smart proxy pulp2 components to use default/all.

Regards
Yaser

I added a PR to enable the original suite and component names in addition to default/all when publishing the repositories.
https://github.com/Katello/katello/pull/9306

1 Like