Internal API error using Gitlab docker


We are self-hosting a Gitlab server for our computer sciences school and since some day; sometimes; when some users try to push their commits to the git server, they get a “Internal API error (500)” from the server. They also get the error message “pre-receive hook declined”. Sometimes, when they try again, everything push as it should, but other times, it does not.

By looking on logs on the server, I can see those JSON messages:

   "error":"Internal API error (500)",
   "msg":"Internal API error",


   "error":"GitLab: http post to gitlab api /post_receive endpoint: Internal API error (500)",
   "msg":"stopping transaction because post-receive hook failed",

The Gitlab version is the “gitlab-ee:16.0.2-ee.0” and here the configuration of the Gitlab docker:

  image: 'gitlab/gitlab-ee:16.0.2-ee.0'
  restart: always
  hostname: ''
            external_url ''
            gitlab_rails['gitlab_shell_ssh_port'] = 7022
            nginx['redirect_http_to_https'] = false
            nginx['listen_port'] = 80
            nginx['listen_https'] = false
            letsencrypt['enable'] = false
            gitlab_rails['smtp_enable'] = true
            gitlab_rails['smtp_address'] = ""
            gitlab_rails['smtp_port'] = 587
            gitlab_rails['smtp_user_name'] = "****"
            gitlab_rails['smtp_password'] = "****"
            gitlab_rails['smtp_domain'] = ""
            gitlab_rails['smtp_authentication'] = "login"
            gitlab_rails['smtp_enable_starttls_auto'] = true
            gitlab_rails['smtp_openssl_verify_mode'] = 'none'
            gitlab_rails['gitlab_email_from'] = '****'
            gitlab_rails['gitlab_email_reply_to'] = ''
      # Add any other gitlab.rb configuration here, each on its own line
    - '7080:80'
    - '7022:22'
    - '7443:443'
    - '/var/docker-files/tigit/config:/etc/gitlab'
    - '/var/docker-files/tigit/logs:/var/log/gitlab'
    - '/var/docker-files/tigit/data:/var/opt/gitlab'

There is also a simple Apache proxy on the server with this configuration:

        ProxyPass /tigit/
        ProxyPassReverse /tigit/
        ProxyPass /tigit
        ProxyPassReverse /tigit

If someone could give me some advice on what I can do to find out what does not work. It would be very appreciated.


Louis M