Sha256: 4ff4990bf60dfe1f551cc96c90b55a252a05df2cfcd0fa5ab7dca9b261d1c6ad

Contents?: true

Size: 347 Bytes

Versions: 2

Compression:

Stored size: 347 Bytes

Contents

# frozen_string_literal: true

module CloudflareIPs
  # Configure trusted_proxies with Cloudflare IPv4 and IPv6 addresses.
  class Railtie < ::Rails::Railtie
    initializer 'cloudflare_ips.configure_rails_initialization' do |app|
      app.config.action_dispatch.trusted_proxies += CloudflareIPs::IPS_V4 + CloudflareIPs::IPS_V6
    end
  end
end

Version data entries

2 entries across 2 versions & 2 rubygems

Version Path
cloudflare-ips-0.1.0 lib/cloudflare_ips/railtie.rb
cloudflare_ips-0.1.0 lib/cloudflare_ips/railtie.rb