Sha256: 796206f2f21316cff2bb3c26d6ad7663de70c010db8afc2b4da2118c2fc2de90

Contents?: true

Size: 1010 Bytes

Versions: 11

Compression:

Stored size: 1010 Bytes

Contents

<% if @rewrites -%>
  ## Rewrite rules
  RewriteEngine On
<% if @rewrite_base -%>
  RewriteBase <%= @rewrite_base %>
<% end -%>

<% [@rewrites].flatten.compact.each do |rewrite_details| -%>
<% if rewrite_details['comment'] -%>
  #<%= rewrite_details['comment'] %>
<% end -%>
<% if rewrite_details['rewrite_cond'] -%>
<%- Array(rewrite_details['rewrite_cond']).each do |commands| -%>
<%- Array(commands).each do |command| -%>
  RewriteCond <%= command %>
<%- end -%>
<% end -%>
<% end -%>
<%- Array(rewrite_details['rewrite_rule']).each do |commands| -%>
<%- Array(commands).each do |command| -%>
  RewriteRule <%= command %>
<%- end -%>

<% end -%>
<% end -%>
<%- end -%>
<%# reverse compatibility %>
<% if @rewrite_rule and !@rewrites -%>
  ## Rewrite rules
  RewriteEngine On
<% if @rewrite_base -%>
  RewriteBase <%= @rewrite_base %>
<% end -%>
<% if @rewrite_cond -%>
<% Array(@rewrite_cond).each do |cond| -%>
  RewriteCond <%= cond %>
<% end -%>
<% end -%>
  RewriteRule <%= @rewrite_rule %>
<%- end -%>

Version data entries

11 entries across 11 versions & 1 rubygems

Version Path
freighthop-0.6.1 modules/apache/templates/vhost/_rewrite.erb
freighthop-0.6.0 modules/apache/templates/vhost/_rewrite.erb
freighthop-0.5.2 modules/apache/templates/vhost/_rewrite.erb
freighthop-0.5.1 modules/apache/templates/vhost/_rewrite.erb
freighthop-0.5.0 modules/apache/templates/vhost/_rewrite.erb
freighthop-0.4.1 modules/apache/templates/vhost/_rewrite.erb
freighthop-0.4.0 modules/apache/templates/vhost/_rewrite.erb
freighthop-0.3.3 modules/apache/templates/vhost/_rewrite.erb
freighthop-0.3.2 modules/apache/templates/vhost/_rewrite.erb
freighthop-0.3.1 modules/apache/templates/vhost/_rewrite.erb
freighthop-0.3.0 modules/apache/templates/vhost/_rewrite.erb