Gitlab shell does not respect puma['port']
Summary
Gitlab shell config (/var/opt/gitlab/gitlab-shell/config.yml
) does not respect puma['port']
setting
Steps to reproduce
- Setup
puma['port'] = 9080
:
unicorn['enable'] = false
puma['enable'] = true
puma['worker_processes'] = 5
puma['port'] = 9080
sudo gitlab-ctl reconfigure
What is the current bug behavior?
$ git fetch
remote:
remote: ========================================================================
remote:
remote: Internal API unreachable
remote:
remote: ========================================================================
remote:
fatal: Could not read from remote repository.
Please make sure you have the correct access rights
and the repository exists.
What is the expected correct behavior?
gitlab-shell/config.yml
should read new port value from gitlab.rb
Relevant logs
Relevant logs
== gitlab-shell/gitlab-shell.log == {"duration_ms":1.623,"error":"Post http://127.0.0.1:8080/api/v4/internal/allowed: EOF","level":"error","method":"POST","msg":"Internal API unreachable","time":"2020-05-09T11:02:10+03:00","url":"http://127.0.0.1:8080/api/v4/internal/allowed"}
== nginx/gitlab_error.log == 2020/05/09 11:02:10 [error] 1351#0: *128035 broken header: "POST /api/v4/internal/allowed HTTP/1.1 Host: 127.0.0.1:8080 User-Agent: Go-http-client/1.1
Connection: close Content-Length: 133 Content-Type: application/json Gitlab-Shared-Secret: *** Accept-Encoding: gzip
{"action":"git-upload-pack","project":"infra/ansible.git","changes":"_any","protocol":"ssh","key_id":"98","check_ip":"46.39.251.239"}" while reading PROXY protocol, client: 127.0.0.1, server: 0.0.0.0:8080
Details of package version
Provide the package version installation details
gitlab-ce-12.10.3-ce.0.el7.x86_64
Environment details
- Operating System:
CentOS Linux release 7.8.2003 (Core)
- Installation Target, remove incorrect values:
- VM:
GCP
- VM:
- Installation Type, remove incorrect values:
- Upgrade from version
12.9.3
- Upgrade from version
- this is a single node installation
Configuration details
Provide the relevant sections of `/etc/gitlab/gitlab.rb`
unicorn['enable'] = false puma['enable'] = true puma['worker_processes'] = 5 puma['port'] = 9080
nginx['enable'] = true nginx['client_max_body_size'] = '0' nginx['redirect_http_to_https'] = false nginx['listen_port'] = '8080 proxy_protocol' nginx['listen_https'] = false
nginx['real_ip_trusted_addresses'] = ['10.1.2.51', '10.32.0.2', '10.32.0.3'] nginx['real_ip_header'] = 'proxy_protocol' nginx['proxy_set_headers'] = { "Host" => "$http_host_with_default", "X-Real-IP" => "$remote_addr", "X-Forwarded-For" => "$remote_addr", "X-Forwarded-Proto" => "$http_x_forwarded_proto_with_default", "X-Forwarded-Ssl" => "$http_x_forwarded_ssl", "X-Forwarded-Port" => "$http_x_forwarded_port_with_default", "Upgrade" => "$http_upgrade", "Connection" => "$connection_upgrade" } nginx['custom_gitlab_server_config'] = %q{ set $http_x_forwarded_proto_with_default $http_x_forwarded_proto; if ( $http_x_forwarded_proto_with_default = '') { set $http_x_forwarded_proto_with_default $scheme; } set $http_x_forwarded_port_with_default $http_x_forwarded_port; if ( $http_x_forwarded_port_with_default = '') { set $http_x_forwarded_port_with_default $server_port; } if ( $http_x_forwarded_proto_with_default = https) { set $http_x_forwarded_ssl on; } }