gitlab update from 7.4.3 to 11.1.4 cause upload img 404
Summary
After gitlab update from 7.4.3 to 11.1.4 with yum, the imgs in the Wiki page return 404.
What is the current bug behavior?
The img in the Wiki page can't visit, but all files already exists on the server path "/var/opt/gitlab/gitlab-rails/uploads". And I upload the same png file again, found that the url changed : Old url: http://example.com/uploads/eh-front-end/zapp/b8b79410d1/task-detail.png New url: http://example.com/eh-front-end/zapp/uploads/dc0d00769e592d89b1e2640e93eee046/task-detail.png
Relevant logs and/or screenshots
nginx logs
10.1.110.59 - - [22/Aug/2018:16:49:06 +0800] "GET /uploads/eh-front-end/zapp/b8b79410d1/task-detail.png HTTP/1.1" 404 3084 "" "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/68.0.3440.75 Safari/537.36"
10.1.110.59 - - [22/Aug/2018:16:49:06 +0800] "GET /favicon.ico HTTP/1.1" 301 168 "http://10.1.10.125/uploads/eh-front-end/zapp/b8b79410d1/task-detail.png" "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/68.0.3440.75 Safari/537.36"
10.1.110.59 - - [22/Aug/2018:16:49:06 +0800] "GET /assets/favicon-7901bd695fb93edb07975966062049829afb56cf11511236e61bcf425070e36e.png HTTP/1.1" 200 1611 "http://10.1.10.125/uploads/eh-front-end/zapp/b8b79410d1/task-detail.png" "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/68.0.3440.75 Safari/537.36"
I try to add a nginx location to math the "/upload" path, but it returns 403 instead. gitlab-http.conf
……
location /uploads {
root /var/opt/gitlab/gitlab-rails;
}
……
nginx logs
10.1.110.59 - - [22/Aug/2018:16:59:53 +0800] "GET /uploads/eh-front-end/zapp/b8b79410d1/task-detail.png HTTP/1.1" 403 564 "" "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/68.0.3440.75 Safari/537.36"
10.1.110.59 - - [22/Aug/2018:16:59:54 +0800] "GET /favicon.ico HTTP/1.1" 301 168 "http://10.1.10.125/uploads/eh-front-end/zapp/b8b79410d1/task-detail.png" "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/68.0.3440.75 Safari/537.36"
10.1.110.59 - - [22/Aug/2018:16:59:54 +0800] "GET /assets/favicon-7901bd695fb93edb07975966062049829afb56cf11511236e61bcf425070e36e.png HTTP/1.1" 200 1611 "http://10.1.10.125/uploads/eh-front-end/zapp/b8b79410d1/task-detail.png" "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/68.0.3440.75 Safari/537.36"
So,I guest I must missing some operations during the upgrade process.I hope to get everyone's help, thanks!
Results of GitLab environment info
System information
System:
Current User: git
Using RVM: no
Ruby Version: 2.4.4p296
Gem Version: 2.7.6
Bundler Version:1.16.2
Rake Version: 12.3.1
Redis Version: 3.2.11
Git Version: 2.17.1
Sidekiq Version:5.1.3
Go Version: unknown
GitLab information
Version: 11.1.4
Revision: 63daf37
Directory: /opt/gitlab/embedded/service/gitlab-rails
DB Adapter: postgresql
URL: http://example.com
HTTP Clone URL: http://example.com/some-group/some-project.git
SSH Clone URL: git@example.com:some-group/some-project.git
Using LDAP: no
Using Omniauth: no
GitLab Shell
Version: 7.1.4
Repository storage paths:
- default: /var/opt/gitlab/git-data/repositories
Hooks: /opt/gitlab/embedded/service/gitlab-shell/hooks
Git: /opt/gitlab/embedded/bin/git