Gitlab - Fixing Unable To Upload Images To Wiki
Whenever I was dragging and dropping an image into the Gitlab window for a Wiki page, I kept getting the following error in the console of Firefox:
Blocked loading mixed active content "http://gitlab.mydomain.com/api/v4/projects/2/wikis/attachments"
It turns out that this was to do with the fact that I was terminating the https connection at the reverse proxy, the encryption wasn't going all the way thorugh to the server. To configure Gitlab to work in this scenario, perform the following steps.
Edit your gitlab.rb file. For me this was at
sudo vim /mnt/storage/gitlab/config/gitlab.rb
Uncomment the external_url line and set it to your hostname, making sure to include https://
Also find and set
nginx['listen_port'] = 80 nginx['listen_https'] = false
- Gitlab.com Issue - "Mixed Context" errors in browser console when HTTP external_url behind HTTPS reverse proxy
- Gitlab Docs - Supporting proxied SSL
First published: 6th September 2019