How to use EPrints with HTTPS

From EPrints Documentation
Revision as of 16:38, 7 April 2008 by Tdb01r (Talk | contribs)

Jump to: navigation, search
Warning This page is under development as part of the EPrints 3.0 manual. It may still contain content specific to earlier versions. Manuals for previous versions of EPrints are also available.

Please note! This page was written for EPrints version 2 and may not apply to version 3.

Manual Sections

Setting up HTTPS under EPrints 3.0.5+/3.1

EPrints 3.0.5 (or EPrints 3.1) introduces a revised process for using EPrints under HTTPS. These instructions apply to users setting up a new repository - existing repositories will have old (incompatible) templates.


Edit archives/[repoid]/cfg/cfg.d/ It will probably look like this:

$c->{host} = '';
$c->{port} = 8080;
$c->{aliases} = [];
#$c->{securehost} = '';
#$c->{secureport} = 8083;
#$c->{securepath} = '/secure';

Add to the end of this file the following settings:

$c->{securehost} = 'HOSTNAME';
#$c->{secureport} = 'PORT';
$c->{http_root} = "";
$c->{https_root} = '/secure';
$c->{http_cgiroot} = '/cgi';
$c->{https_cgiroot} = '/secure/cgi';

Where HOSTNAME is the hostname of your HTTPS server. If your HTTPS server is not using the standard port 443 specify it here. The http(s)_(cgi)root variables specify the path to EPrints on your HTTP and HTTPS servers.

Now run bin/generate_apacheconf to generate the secure Apache configuration and copy the default template to the template used for HTTPS.

Add the following line inside your Apache SSL virtual host declaration (probably in /etc/httpd/conf.d/mod_ssl.conf):

Include /opt/eprints3/archives/[repoid]/var/auto-secure.conf

Restart Apache.