Remove project return 404 when using redirection
Summary
When using redirection, the "Remove project" page returns 404. I'm using redirection from our Apache2 frontend on a subfolder /gitlab to our internal gitlab server. The server was configured with: external_url 'https://PUBLIC_PATH/gitlab'
It worked without problems for other links or paths, but after clicking on the Remove Project button, a 404 page is displayed:
https://PUBLIC_PATH/gitlab/USER/test_project/edit#
This does not happen if the gitlab server is accessed directly via direct ip, this problem only happens when accessing via Apache redirect. And all other assets and pages are working without problems.
Steps to reproduce
- Activate HTTPS in Apache
- Set Apache redirect to gitlab installation: ProxyPass /gitlab http://INTERNAL_IP/gitlab ProxyPassReverse /gitlab http://INTERNAL_IP/gitlab
- Log-in with user (we use LDAP)
- Create a dummy project
- Go to: https://SERVER/gitlab/USER/test_project/edit
- Expand Advanced settings
- Click on Remove project
- Write the project name on the textbox
- Click on "Confirm"
What is the current bug behavior?
The system returns a 404 page (The page could not be found or you don't have permission to view it.) There is no log entries for this error I can see.
What is the expected correct behavior?
The project is deleted and the user redirected to the projects page.
Results of GitLab environment info
Expand for output related to GitLab environment info
System information System: Ubuntu 16.04 Current User: git Using RVM: no Ruby Version: 2.3.5p376 Gem Version: 2.6.13 Bundler Version:1.13.7 Rake Version: 12.3.0 Redis Version: 3.2.11 Git Version: 2.14.3 Sidekiq Version:5.0.4 Go Version: unknown
GitLab information Version: 10.3.4 Revision: 56dc722 Directory: /opt/gitlab/embedded/service/gitlab-rails DB Adapter: postgresql URL: http://www.verlab.dcc.ufmg.br/gitlab HTTP Clone URL: http://www.verlab.dcc.ufmg.br/gitlab/some-group/some-project.git SSH Clone URL: git@www.verlab.dcc.ufmg.br:some-group/some-project.git Using LDAP: yes Using Omniauth: no
GitLab Shell Version: 5.10.2 Repository storage paths:
- default: /var/opt/gitlab/git-data/repositories Hooks: /opt/gitlab/embedded/service/gitlab-shell/hooks Git: /opt/gitlab/embedded/bin/git
Results of GitLab application Check
Expand for output related to the GitLab application check
Checking GitLab Shell ...
GitLab Shell version >= 5.10.2 ? ... OK (5.10.2) Repo base directory exists? default... yes Repo storage directories are symlinks? default... no Repo paths owned by git:root, or git:git? default... yes Repo paths access is drwxrws---? default... yes hooks directories in repos are links: ... 9/4 ... repository is empty 5/5 ... ok 5/6 ... ok 8/8 ... ok 18/9 ... ok 21/10 ... ok 22/11 ... ok 23/12 ... repository is empty 18/13 ... ok 27/14 ... ok 17/15 ... ok 18/17 ... ok 30/18 ... ok 31/19 ... ok 31/20 ... repository is empty 32/21 ... ok 32/22 ... ok 32/23 ... ok 39/24 ... ok 39/25 ... ok 34/28 ... ok 34/29 ... ok 34/30 ... repository is empty 36/34 ... ok 36/35 ... ok 18/36 ... ok 18/38 ... ok 39/39 ... ok 34/40 ... ok 18/41 ... ok 37/42 ... ok 18/43 ... ok 18/44 ... ok 18/45 ... ok 18/46 ... ok 18/47 ... ok 18/48 ... repository is empty 6/55 ... repository is empty Running /opt/gitlab/embedded/service/gitlab-shell/bin/check Check GitLab API access: OK Redis available via internal API: OK
Access to /var/opt/gitlab/.ssh/authorized_keys: OK gitlab-shell self-check successful
Checking GitLab Shell ... Finished
Checking Sidekiq ...
Running? ... yes Number of Sidekiq processes ... 1
Checking Sidekiq ... Finished
Reply by email is disabled in config/gitlab.yml Checking LDAP ...
Server: ldapmain LDAP authentication... Success LDAP users with access to your GitLab server (only showing the first 100 results) DN: uid=root,ou=users,[....] uid: root REMOVED FOR SECURITY
Checking LDAP ... Finished
Checking GitLab ...
Git configured correctly? ... yes Database config exists? ... yes All migrations up? ... yes Database contains orphaned GroupMembers? ... no GitLab config exists? ... yes GitLab config up to date? ... yes Log directory writable? ... yes Tmp directory writable? ... yes Uploads directory exists? ... yes Uploads directory has correct permissions? ... yes Uploads directory tmp has correct permissions? ... yes Init script exists? ... skipped (omnibus-gitlab has no init script) Init script up-to-date? ... skipped (omnibus-gitlab has no init script) Projects have namespace: ... 9/4 ... yes 5/5 ... yes 5/6 ... yes 8/8 ... yes 18/9 ... yes 21/10 ... yes 22/11 ... yes 23/12 ... yes 18/13 ... yes 27/14 ... yes 17/15 ... yes 18/17 ... yes 30/18 ... yes 31/19 ... yes 31/20 ... yes 32/21 ... yes 32/22 ... yes 32/23 ... yes 39/24 ... yes 39/25 ... yes 34/28 ... yes 34/29 ... yes 34/30 ... yes 36/34 ... yes 36/35 ... yes 18/36 ... yes 18/38 ... yes 39/39 ... yes 34/40 ... yes 18/41 ... yes 37/42 ... yes 18/43 ... yes 18/44 ... yes 18/45 ... yes 18/46 ... yes 18/47 ... yes 18/48 ... yes 6/55 ... yes Redis version >= 2.8.0? ... yes Ruby version >= 2.3.5 ? ... yes (2.3.5) Git version >= 2.7.3 ? ... yes (2.14.3) Git user has default SSH configuration? ... yes Active users: ... 29
Checking GitLab ... Finished