Skip to content

Allow Rails request.remote_ip to defer to Fly.io's connecting IP.

License

Notifications You must be signed in to change notification settings

pcai/actionpack-fly

Repository files navigation

Actionpack::Fly

Build Status

Simple gem that extends Rails request.remote_ip to default to Fly's Fly-Client-IP header. More about Fly HTTP Request Headers and why we choose to trust Fly-Client-IP.

Installation

Add this line to your Rails application's Gemfile:

gem 'actionpack-fly'

Usage

None! Just install and feel confident that request.remote_ip is doing its job.

Contributing

  • Fork the repo. There's a default devcontainer configuration you can use to get up and running.
  • Make your changes, make sure tests keep passing: bundle exec rspec
  • Open pull request

License

The gem is available as open source under the terms of the MIT License.

Credits

Forked from https://github.com/customink/actionpack-cloudflare

About

Allow Rails request.remote_ip to defer to Fly.io's connecting IP.

Resources

License

Code of conduct

Stars

Watchers

Forks

Contributors 4

  •  
  •  
  •  
  •