Review-apps cleanup fails repeteadly
Context
We noticed several errors in review-cleanup CI/CD jobs (example):
/usr/local/lib/ruby/3.0.0/net/protocol.rb:46:in `connect_nonblock': SSL_connect returned=1 errno=0 state=error: certificate verify failed (self signed certificate in certificate chain) (OpenSSL::SSL::SSLError)
from /usr/local/lib/ruby/3.0.0/net/protocol.rb:46:in `ssl_socket_connect'
from /usr/local/lib/ruby/3.0.0/net/http.rb:1038:in `connect'
from /usr/local/lib/ruby/3.0.0/net/http.rb:970:in `do_start'
from /usr/local/lib/ruby/3.0.0/net/http.rb:959:in `start'
from /usr/local/lib/ruby/3.0.0/net/http.rb:1512:in `request'
from /usr/local/lib/ruby/gems/3.0.0/gems/httparty-0.20.0/lib/httparty/request.rb:152:in `perform'
from /usr/local/lib/ruby/gems/3.0.0/gems/httparty-0.20.0/lib/httparty.rb:613:in `perform_request'
from /usr/local/lib/ruby/gems/3.0.0/gems/httparty-0.20.0/lib/httparty.rb:527:in `get'
from /usr/local/lib/ruby/gems/3.0.0/gems/gitlab-4.19.0/lib/gitlab/request.rb:54:in `block (2 levels) in <class:Request>'
from /usr/local/lib/ruby/gems/3.0.0/gems/gitlab-4.19.0/lib/gitlab/client/deployments.rb:19:in `deployments'
from /usr/local/lib/ruby/gems/3.0.0/gems/gitlab-4.19.0/lib/gitlab.rb:28:in `method_missing'
from scripts/review_apps/automated_cleanup.rb:132:in `perform_gitlab_docs_environment_cleanup!'
from scripts/review_apps/automated_cleanup.rb:299:in `block in <main>'
from scripts/review_apps/automated_cleanup.rb:290:in `timed'
from scripts/review_apps/automated_cleanup.rb:298:in `<main>'
Also, we changed the CI/CD image for that job recently in !144034 (merged).
Goal
Reproduce the problem locally (hint: use the new docker image locally), and fix the issue.