Skip to content
This repository was archived by the owner on Jul 12, 2023. It is now read-only.
This repository was archived by the owner on Jul 12, 2023. It is now read-only.

Catalyst HTTPS redirect #91

@jgara

Description

@jgara

Topic: the HTTPS redirect on catalyst
Both -prod and -stage use the following code in /etc/httpd/conf.d/01_catalyst.conf:

# BEGIN http redirect
  # We run Catalyst/Blacklight in the main virtual host, and we require
  # https access. So this :80 virtual host insists on redirects to https.
  #
  # This could also be put in <Location> directives if it wasn't the whole
  # server that was so restricted.
  #
  # Except Refworks sometimes refuses to make callbacks to https, so we
  # have to allow refworks-formatted exports in http.
  RewriteEngine On
  RewriteCond %{HTTPS} !=on
  RewriteCond %{REQUEST_URI} !refworks_marc_txt$
  RewriteRule .* https://%{SERVER_NAME}%{REQUEST_URI} [R,L]

# END http redirect

The proposed change/simplification is:

# BEGIN http redirect
  Redirect "/" "https://{{ hostname | default('myapp') }}.{{ domainname | default('test.test') }}"
# END http redirect

Is this ok? Will some rare condition not be fulfilled? Will something be lost?

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions