Error syncing deb content on smart proxy

**Problem: Cannot Sync Deb Repositories

Expected outcome:

**Foreman and Proxy versions:Satellite 6.9 (Foreman 2.3 / katello-3.18)

Foreman and Proxy plugin versions:

Distribution and version:

Not syncing deb content to smart proxy.

When syncing deb content to smart proxy the following error appeared on smart proxy logs

404 Not Found: {"http_request_method": "POST", "exception": null, "error_message": "Missing resource(s):
opt/theforeman/tfm/root/usr/share/gems/gems/rest-client-2.0.2/lib/restclient/abstract_response.rb:223:in `exception_with_response'
 | /opt/theforeman/tfm/root/usr/share/gems/gems/rest-client-2.0.2/lib/restclient/abstract_response.rb:103:in `return!'
 | /opt/theforeman/tfm/root/usr/share/gems/gems/runcible-2.13.1/lib/runcible/base.rb:95:in `block in get_response'
 | /opt/theforeman/tfm/root/usr/share/gems/gems/rest-client-2.0.2/lib/restclient/request.rb:807:in `process_result'
 | /opt/theforeman/tfm/root/usr/share/gems/gems/rest-client-2.0.2/lib/restclient/request.rb:725:in `block in transmit'
Nov  8 13:10:21 capsule pulp: pulp.server.controllers.repository:ERROR: (44693-01632) Exception adding importer to repo [6617483c-31c3-4593-a25f-a4f3e19d52c9]; the repo will be deleted
Nov  8 13:10:21 capsule pulp: pulp.server.controllers.repository:ERROR: (44693-01632) Traceback (most recent call last):
Nov  8 13:10:21 capsule pulp: pulp.server.controllers.repository:ERROR: (44693-01632)   File "/usr/lib/python2.7/site-packages/pulp/server/controllers/repository.py", line 428, in create_repo
Nov  8 13:10:21 capsule pulp: pulp.server.controllers.repository:ERROR: (44693-01632)     importer_controller.set_importer(repo_id, importer_type_id, importer_repo_plugin_config)
Nov  8 13:10:21 capsule pulp: pulp.server.controllers.repository:ERROR: (44693-01632)   File "/usr/lib/python2.7/site-packages/celery/local.py", line 191, in __call__
Nov  8 13:10:21 capsule pulp: pulp.server.controllers.repository:ERROR: (44693-01632)     return self._get_current_object()(*a, **kw)
Nov  8 13:10:21 capsule pulp: pulp.server.controllers.repository:ERROR: (44693-01632)   File "/usr/lib/python2.7/site-packages/pulp/server/async/tasks.py", line 688, in __call__
Nov  8 13:10:21 capsule pulp: pulp.server.controllers.repository:ERROR: (44693-01632)     return super(Task, self).__call__(*args, **kwargs)
Nov  8 13:10:21 capsule pulp: pulp.server.controllers.repository:ERROR: (44693-01632)   File "/usr/lib/python2.7/site-packages/pulp/server/async/tasks.py", line 110, in __call__
Nov  8 13:10:21 capsule pulp: pulp.server.controllers.repository:ERROR: (44693-01632)     return super(PulpTask, self).__call__(*args, **kwargs)
Nov  8 13:10:21 capsule pulp: pulp.server.controllers.repository:ERROR: (44693-01632)   File "/usr/lib/python2.7/site-packages/celery/app/task.py", line 379, in __call__
Nov  8 13:10:21 capsule pulp: pulp.server.controllers.repository:ERROR: (44693-01632)     return self.run(*args, **kwargs)
Nov  8 13:10:21 capsule pulp: pulp.server.controllers.repository:ERROR: (44693-01632)   File "/usr/lib/python2.7/site-packages/pulp/server/controllers/importer.py", line 91, in set_importer
Nov  8 13:10:21 capsule pulp: pulp.server.controllers.repository:ERROR: (44693-01632)     importer_type_id=importer_type_id)
Nov  8 13:10:21 capsule pulp: pulp.server.controllers.repository:ERROR: (44693-01632) PulpCodedValidationException: The importer type deb_importer does not exist
Nov  8 13:10:21 capsule pulp: pulp.server.webservices.middleware.exception:INFO: The importer type deb_importer does not exist

Thanks

If your Smart Proxy is using Pulp 3, the deb content sync does not work in any Katello versions before this issue was fixed: Bug #33377: Smart Proxy Syncing debian repositories fails with `Response body: {"distributions":["This field is required."]} (PulpDebClient::ApiError)` - Katello - Foreman
If your Server is using Pulp 3 and your proxy is using Pulp 2 then the deb content sync does not work (for any Katello version).