Cannot import Puppet module because "self signed certificate in certificate chain"

Problem:
Cannot import Puppet class into Katello
When I click on “Import environments from <servername>” I get this error:

ERF12-2749 [ProxyAPI::ProxyException]: Unable to get environments from Puppet ([RestClient::NotAcceptable]: 406 Not Acceptable) for proxy https://ktl01.\<domain>.net:9090/puppet

proxy.log contains the following errors

2022-01-26T08:47:05 4510387c [I] Started GET /puppet/environments
2022-01-26T08:47:05 4510387c [E] Failed to list puppet environments: SSL_connect returned=1 errno=0 state=error: certificate verify failed (self signed certificate in certificate chain)
2022-01-26T08:47:05 4510387c [W] Error details for Failed to list puppet environments: SSL_connect returned=1 errno=0 state=error: certificate verify failed (self signed certificate in certificate chain): <Exception>: Failed to list puppet environments: SSL_connect returned=1 errno=0 state=error: certificate verify failed (self signed certificate in certificate chain)
2022-01-26T08:47:05 4510387c [W] Failed to list puppet environments: SSL_connect returned=1 errno=0 state=error: certificate verify failed (self signed certificate in certificate chain): <Exception>: Failed to list puppet environments: SSL_connect returned=1 errno=0 state=error: certificate verify failed (self signed certificate in certificate chain)
2022-01-26T08:47:05 4510387c [I] Finished GET /puppet/environments with 406 (40.36 ms)

If I browse to https://mxktl01.<domain>.net:9090/puppet, the certificate and the chain are ok.

Expected outcome:
Import custom Puppet module into Katello
If I go to
Foreman and Proxy versions:
Foreman 2.5.4
Foreman and Proxy plugin versions:
Katello 4.1.4
Distribution and version:
CenOS 7
Other relevant data:
Original name of the machine is mxktl01.<domain>.net, but I managed to change the url of Katello to katello.<domain>.net. I’m using wildcard SSL certificates for <domain>.net.

this is the output from production.log

2022-01-28T10:18:16 [I|app|b272133f] Started GET "/puppetclasses/import_environments?proxy=1-mxktl01-<domain>-net" for 10.x.x.8 at 2022-01-28 10:18:16 -0600
2022-01-28T10:18:16 [I|app|b272133f] Processing by PuppetclassesController#import_environments as HTML
2022-01-28T10:18:16 [I|app|b272133f]   Parameters: {"proxy"=>"1-mxktl01-<domain>-net"}
2022-01-28T10:18:16 [W|app|b272133f] ProxyAPI operation FAILED
2022-01-28T10:18:16 [I|app|b272133f] Backtrace for 'ProxyAPI operation FAILED' error (ProxyAPI::ProxyException): ERF12-2749 [ProxyAPI::ProxyException]: Unable to get environments from Puppet ([RestClient::NotAcceptable]: 406 Not Acceptable) for proxy https://mxktl01.<domain>.net:9090/puppet
 b272133f | /usr/share/foreman/lib/proxy_api/puppet.rb:11:in `rescue in environments'
 b272133f | /usr/share/foreman/lib/proxy_api/puppet.rb:8:in `environments'
 b272133f | /usr/share/foreman/app/services/puppet_class_importer.rb:178:in `proxy_environments'
 b272133f | /usr/share/foreman/app/services/puppet_class_importer.rb:174:in `actual_environments'
 b272133f | /usr/share/foreman/app/services/puppet_class_importer.rb:23:in `changes'
 b272133f | /usr/share/foreman/app/controllers/concerns/foreman/controller/environments.rb:11:in `import_environments'
 b272133f | /opt/theforeman/tfm/root/usr/share/gems/gems/actionpack-6.0.3.7/lib/action_controller/metal/basic_implicit_render.rb:6:in `send_action'
 b272133f | /opt/theforeman/tfm/root/usr/share/gems/gems/actionpack-6.0.3.7/lib/abstract_controller/base.rb:195:in `process_action'
 b272133f | /opt/theforeman/tfm/root/usr/share/gems/gems/actionpack-6.0.3.7/lib/action_controller/metal/rendering.rb:30:in `process_action'
 b272133f | /opt/theforeman/tfm/root/usr/share/gems/gems/actionpack-6.0.3.7/lib/abstract_controller/callbacks.rb:42:in `block in process_action'
 b272133f | /opt/theforeman/tfm/root/usr/share/gems/gems/activesupport-6.0.3.7/lib/active_support/callbacks.rb:112:in `block in run_callbacks'
 b272133f | /usr/share/foreman/app/controllers/concerns/foreman/controller/timezone.rb:10:in `set_timezone'
 b272133f | /opt/theforeman/tfm/root/usr/share/gems/gems/activesupport-6.0.3.7/lib/active_support/callbacks.rb:121:in `block in run_callbacks'
 b272133f | /usr/share/foreman/app/models/concerns/foreman/thread_session.rb:32:in `clear_thread'
 b272133f | /opt/theforeman/tfm/root/usr/share/gems/gems/activesupport-6.0.3.7/lib/active_support/callbacks.rb:121:in `block in run_callbacks'
 b272133f | /usr/share/foreman/app/controllers/concerns/foreman/controller/topbar_sweeper.rb:12:in `set_topbar_sweeper_controller'
 b272133f | /opt/theforeman/tfm/root/usr/share/gems/gems/activesupport-6.0.3.7/lib/active_support/callbacks.rb:121:in `block in run_callbacks'
 b272133f | /opt/theforeman/tfm/root/usr/share/gems/gems/audited-4.9.0/lib/audited/sweeper.rb:14:in `around'
 b272133f | /opt/theforeman/tfm/root/usr/share/gems/gems/activesupport-6.0.3.7/lib/active_support/callbacks.rb:121:in `block in run_callbacks'
 b272133f | /opt/theforeman/tfm/root/usr/share/gems/gems/audited-4.9.0/lib/audited/sweeper.rb:14:in `around'
 b272133f | /opt/theforeman/tfm/root/usr/share/gems/gems/activesupport-6.0.3.7/lib/active_support/callbacks.rb:121:in `block in run_callbacks'
 b272133f | /opt/theforeman/tfm/root/usr/share/gems/gems/activesupport-6.0.3.7/lib/active_support/callbacks.rb:139:in `run_callbacks'
 b272133f | /opt/theforeman/tfm/root/usr/share/gems/gems/actionpack-6.0.3.7/lib/abstract_controller/callbacks.rb:41:in `process_action'
 b272133f | /opt/theforeman/tfm/root/usr/share/gems/gems/actionpack-6.0.3.7/lib/action_controller/metal/rescue.rb:22:in `process_action'
 b272133f | /opt/theforeman/tfm/root/usr/share/gems/gems/actionpack-6.0.3.7/lib/action_controller/metal/instrumentation.rb:33:in `block in process_action'
 b272133f | /opt/theforeman/tfm/root/usr/share/gems/gems/activesupport-6.0.3.7/lib/active_support/notifications.rb:180:in `block in instrument'
 b272133f | /opt/theforeman/tfm/root/usr/share/gems/gems/activesupport-6.0.3.7/lib/active_support/notifications/instrumenter.rb:24:in `instrument'
 b272133f | /opt/theforeman/tfm/root/usr/share/gems/gems/activesupport-6.0.3.7/lib/active_support/notifications.rb:180:in `instrument'
 b272133f | /opt/theforeman/tfm/root/usr/share/gems/gems/actionpack-6.0.3.7/lib/action_controller/metal/instrumentation.rb:32:in `process_action'
 b272133f | /opt/theforeman/tfm/root/usr/share/gems/gems/actionpack-6.0.3.7/lib/action_controller/metal/params_wrapper.rb:245:in `process_action'
 b272133f | /opt/theforeman/tfm/root/usr/share/gems/gems/activerecord-6.0.3.7/lib/active_record/railties/controller_runtime.rb:27:in `process_action'
 b272133f | /opt/theforeman/tfm/root/usr/share/gems/gems/actionpack-6.0.3.7/lib/abstract_controller/base.rb:136:in `process'
 b272133f | /opt/theforeman/tfm/root/usr/share/gems/gems/actionview-6.0.3.7/lib/action_view/rendering.rb:39:in `process'
 b272133f | /opt/theforeman/tfm/root/usr/share/gems/gems/actionpack-6.0.3.7/lib/action_controller/metal.rb:190:in `dispatch'
 b272133f | /opt/theforeman/tfm/root/usr/share/gems/gems/actionpack-6.0.3.7/lib/action_controller/metal.rb:254:in `dispatch'
 b272133f | /opt/theforeman/tfm/root/usr/share/gems/gems/actionpack-6.0.3.7/lib/action_dispatch/routing/route_set.rb:50:in `dispatch'
 b272133f | /opt/theforeman/tfm/root/usr/share/gems/gems/actionpack-6.0.3.7/lib/action_dispatch/routing/route_set.rb:33:in `serve'
 b272133f | /opt/theforeman/tfm/root/usr/share/gems/gems/actionpack-6.0.3.7/lib/action_dispatch/journey/router.rb:49:in `block in serve'
 b272133f | /opt/theforeman/tfm/root/usr/share/gems/gems/actionpack-6.0.3.7/lib/action_dispatch/journey/router.rb:32:in `each'
 b272133f | /opt/theforeman/tfm/root/usr/share/gems/gems/actionpack-6.0.3.7/lib/action_dispatch/journey/router.rb:32:in `serve'
 b272133f | /opt/theforeman/tfm/root/usr/share/gems/gems/actionpack-6.0.3.7/lib/action_dispatch/routing/route_set.rb:834:in `call'
 b272133f | /opt/theforeman/tfm/root/usr/share/gems/gems/katello-4.1.4/lib/katello/middleware/organization_created_enforcer.rb:18:in `call'
 b272133f | /opt/theforeman/tfm/root/usr/share/gems/gems/katello-4.1.4/lib/katello/middleware/event_daemon.rb:10:in `call'
 b272133f | /opt/theforeman/tfm/root/usr/share/gems/gems/actionpack-6.0.3.7/lib/action_dispatch/middleware/static.rb:126:in `call'
 b272133f | /opt/theforeman/tfm/root/usr/share/gems/gems/actionpack-6.0.3.7/lib/action_dispatch/middleware/static.rb:126:in `call'
 b272133f | /opt/theforeman/tfm/root/usr/share/gems/gems/apipie-dsl-2.4.0/lib/apipie_dsl/static_dispatcher.rb:67:in `call'
 b272133f | /opt/theforeman/tfm/root/usr/share/gems/gems/apipie-rails-0.5.17/lib/apipie/static_dispatcher.rb:66:in `call'
 b272133f | /opt/theforeman/tfm/root/usr/share/gems/gems/apipie-rails-0.5.17/lib/apipie/extractor/recorder.rb:137:in `call'
 b272133f | /opt/theforeman/tfm/root/usr/share/gems/gems/actionpack-6.0.3.7/lib/action_dispatch/middleware/static.rb:126:in `call'
 b272133f | /opt/theforeman/tfm/root/usr/share/gems/gems/actionpack-6.0.3.7/lib/action_dispatch/middleware/static.rb:126:in `call'
 b272133f | /opt/theforeman/tfm/root/usr/share/gems/gems/actionpack-6.0.3.7/lib/action_dispatch/middleware/static.rb:126:in `call'
 b272133f | /usr/share/foreman/lib/foreman/middleware/telemetry.rb:10:in `call'
 b272133f | /opt/theforeman/tfm/root/usr/share/gems/gems/apipie-rails-0.5.17/lib/apipie/middleware/checksum_in_headers.rb:27:in `call'
 b272133f | /usr/share/foreman/lib/foreman/middleware/catch_json_parse_errors.rb:9:in `call'
 b272133f | /opt/theforeman/tfm/root/usr/share/gems/gems/rack-2.2.3/lib/rack/tempfile_reaper.rb:15:in `call'
 b272133f | /opt/theforeman/tfm/root/usr/share/gems/gems/rack-2.2.3/lib/rack/etag.rb:27:in `call'
 b272133f | /opt/theforeman/tfm/root/usr/share/gems/gems/rack-2.2.3/lib/rack/conditional_get.rb:27:in `call'
 b272133f | /opt/theforeman/tfm/root/usr/share/gems/gems/rack-2.2.3/lib/rack/head.rb:12:in `call'
 b272133f | /opt/theforeman/tfm/root/usr/share/gems/gems/actionpack-6.0.3.7/lib/action_dispatch/http/content_security_policy.rb:18:in `call'
 b272133f | /usr/share/foreman/lib/foreman/middleware/logging_context_session.rb:22:in `call'
 b272133f | /opt/theforeman/tfm/root/usr/share/gems/gems/rack-2.2.3/lib/rack/session/abstract/id.rb:266:in `context'
 b272133f | /opt/theforeman/tfm/root/usr/share/gems/gems/rack-2.2.3/lib/rack/session/abstract/id.rb:260:in `call'
 b272133f | /opt/theforeman/tfm/root/usr/share/gems/gems/actionpack-6.0.3.7/lib/action_dispatch/middleware/cookies.rb:648:in `call'
 b272133f | /opt/theforeman/tfm/root/usr/share/gems/gems/actionpack-6.0.3.7/lib/action_dispatch/middleware/callbacks.rb:27:in `block in call'
 b272133f | /opt/theforeman/tfm/root/usr/share/gems/gems/activesupport-6.0.3.7/lib/active_support/callbacks.rb:101:in `run_callbacks'
 b272133f | /opt/theforeman/tfm/root/usr/share/gems/gems/actionpack-6.0.3.7/lib/action_dispatch/middleware/callbacks.rb:26:in `call'
 b272133f | /opt/theforeman/tfm/root/usr/share/gems/gems/actionpack-6.0.3.7/lib/action_dispatch/middleware/actionable_exceptions.rb:18:in `call'
 b272133f | /opt/theforeman/tfm/root/usr/share/gems/gems/actionpack-6.0.3.7/lib/action_dispatch/middleware/debug_exceptions.rb:32:in `call'
 b272133f | /opt/theforeman/tfm/root/usr/share/gems/gems/actionpack-6.0.3.7/lib/action_dispatch/middleware/show_exceptions.rb:33:in `call'
 b272133f | /opt/theforeman/tfm/root/usr/share/gems/gems/railties-6.0.3.7/lib/rails/rack/logger.rb:37:in `call_app'
 b272133f | /opt/theforeman/tfm/root/usr/share/gems/gems/railties-6.0.3.7/lib/rails/rack/logger.rb:28:in `call'
 b272133f | /opt/theforeman/tfm/root/usr/share/gems/gems/sprockets-rails-3.2.1/lib/sprockets/rails/quiet_assets.rb:13:in `call'
 b272133f | /usr/share/foreman/lib/foreman/middleware/logging_context_request.rb:11:in `call'
 b272133f | /opt/theforeman/tfm/root/usr/share/gems/gems/actionpack-6.0.3.7/lib/action_dispatch/middleware/remote_ip.rb:81:in `call'
 b272133f | /opt/theforeman/tfm/root/usr/share/gems/gems/actionpack-6.0.3.7/lib/action_dispatch/middleware/request_id.rb:27:in `call'
 b272133f | /opt/theforeman/tfm/root/usr/share/gems/gems/katello-4.1.4/lib/katello/prevent_json_parsing.rb:12:in `call'
 b272133f | /opt/theforeman/tfm/root/usr/share/gems/gems/rack-2.2.3/lib/rack/method_override.rb:24:in `call'
 b272133f | /opt/theforeman/tfm/root/usr/share/gems/gems/rack-2.2.3/lib/rack/runtime.rb:22:in `call'
 b272133f | /opt/theforeman/tfm/root/usr/share/gems/gems/activesupport-6.0.3.7/lib/active_support/cache/strategy/local_cache_middleware.rb:29:in `call'
 b272133f | /opt/theforeman/tfm/root/usr/share/gems/gems/actionpack-6.0.3.7/lib/action_dispatch/middleware/executor.rb:14:in `call'
 b272133f | /opt/theforeman/tfm/root/usr/share/gems/gems/actionpack-6.0.3.7/lib/action_dispatch/middleware/static.rb:126:in `call'
 b272133f | /opt/theforeman/tfm/root/usr/share/gems/gems/rack-2.2.3/lib/rack/sendfile.rb:110:in `call'
 b272133f | /opt/theforeman/tfm/root/usr/share/gems/gems/actionpack-6.0.3.7/lib/action_dispatch/middleware/host_authorization.rb:76:in `call'
 b272133f | /opt/theforeman/tfm/root/usr/share/gems/gems/secure_headers-6.3.0/lib/secure_headers/middleware.rb:11:in `call'
 b272133f | /opt/theforeman/tfm/root/usr/share/gems/gems/railties-6.0.3.7/lib/rails/engine.rb:527:in `call'
 b272133f | /opt/theforeman/tfm/root/usr/share/gems/gems/railties-6.0.3.7/lib/rails/railtie.rb:190:in `public_send'
 b272133f | /opt/theforeman/tfm/root/usr/share/gems/gems/railties-6.0.3.7/lib/rails/railtie.rb:190:in `method_missing'
 b272133f | /opt/theforeman/tfm/root/usr/share/gems/gems/rack-2.2.3/lib/rack/urlmap.rb:74:in `block in call'
 b272133f | /opt/theforeman/tfm/root/usr/share/gems/gems/rack-2.2.3/lib/rack/urlmap.rb:58:in `each'
 b272133f | /opt/theforeman/tfm/root/usr/share/gems/gems/rack-2.2.3/lib/rack/urlmap.rb:58:in `call'
 b272133f | /opt/theforeman/tfm/root/usr/share/gems/gems/puma-5.3.2/lib/puma/configuration.rb:249:in `call'
 b272133f | /opt/theforeman/tfm/root/usr/share/gems/gems/puma-5.3.2/lib/puma/request.rb:77:in `block in handle_request'
 b272133f | /opt/theforeman/tfm/root/usr/share/gems/gems/puma-5.3.2/lib/puma/thread_pool.rb:338:in `with_force_shutdown'
 b272133f | /opt/theforeman/tfm/root/usr/share/gems/gems/puma-5.3.2/lib/puma/request.rb:76:in `handle_request'
 b272133f | /opt/theforeman/tfm/root/usr/share/gems/gems/puma-5.3.2/lib/puma/server.rb:438:in `process_client'
 b272133f | /opt/theforeman/tfm/root/usr/share/gems/gems/puma-5.3.2/lib/puma/thread_pool.rb:145:in `block in spawn_thread'
 b272133f | /opt/theforeman/tfm/root/usr/share/gems/gems/logging-2.3.0/lib/logging/diagnostic_context.rb:474:in `block in create_with_logging_context'
2022-01-28T10:18:16 [I|app|b272133f] Redirected to https://katello.<domain>.net/puppetclasses
2022-01-28T10:18:16 [I|app|b272133f] Completed 302 Found in 117ms (ActiveRecord: 2.4ms | Allocations: 5022)
2022-01-28T10:18:16 [I|app|2bd35e71] Started GET "/puppetclasses" for 10.x.x.8 at 2022-01-28 10:18:16 -0600
2022-01-28T10:18:16 [I|app|2bd35e71] Processing by PuppetclassesController#index as HTML
2022-01-28T10:18:16 [I|app|2bd35e71]   Rendering puppetclasses/index.html.erb within layouts/application
2022-01-28T10:18:16 [I|app|2bd35e71]   Rendering text template
2022-01-28T10:18:16 [I|app|2bd35e71]   Rendered text template (Duration: 0.0ms | Allocations: 1)
2022-01-28T10:18:16 [I|app|2bd35e71]   Rendered puppetclasses/index.html.erb within layouts/application (Duration: 13.9ms | Allocations: 7928)
2022-01-28T10:18:16 [I|app|2bd35e71]   Rendered layouts/_application_content.html.erb (Duration: 4.2ms | Allocations: 6074)
2022-01-28T10:18:16 [I|app|2bd35e71]   Rendering layouts/base.html.erb
2022-01-28T10:18:16 [I|app|2bd35e71]   Rendered layouts/base.html.erb (Duration: 27.2ms | Allocations: 22893)
2022-01-28T10:18:16 [I|app|2bd35e71] Completed 200 OK in 61ms (Views: 48.9ms | ActiveRecord: 3.7ms | Allocations: 45901)