First of all, backup the httpd.conf file with the following command:
cp /etc/httpd/conf/httpd.conf /etc/httpd/conf/httpd.bkup.ssl.1
The following command opens httpd.conf and searches for the term SSL:
vi +/SSL /etc/httpd/conf/httpd.conf
You should see the following lines with the prompt at SSL selected:
# # Use name-based virtual hosting. # #NameVirtualHost *:80 # # NOTE: NameVirtualHost cannot be used without a port specifier # (e.g. :80) if mod_ssl is being used, due to the nature of the # SSL protocol. #
Just move the cursor down and add following line after:
# SSL protocol. # RequestHeader set X_FORWARDED_PROTO 'https'
Opening and closing vi Editor
To quit the vi editor with saving the changes you made, hit ‘ESC’ key and type ‘ZZ’ (in caps) and it will save the changes and close the vi editor.
If you have made any mistake and want to quite without saving any changes, just hit ‘ESC’ key and type :q! and hit enter.
Hope that helps.
this does not work for a cpanel server.
In standard Cpanel installations, as far I know, Apache is not used for Redmine, Cpanel uses WEBrick web server to serve Redmine over port 3000.
You might find my this post useful where I have explained how can WEBrick be configured to serve Redmine over SSL Configuring WEBrick to serve Redmine over SSL using openSSL certificate.