Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Compact IPv4 attributes for Active Record. Presents an unsigned int (4 bytes) as an IPAddr.
Ruby
Branch: master

Fetching latest commit…

Cannot retrieve the latest commit at this time

Failed to load latest commit information.
bin
lib
test
.gitignore
.ruby-version
Gemfile
Gemfile.lock
MIT-LICENSE
README.md
Rakefile
composed_of_ipaddr.gemspec

README.md

Composed of IPAddr

Make it easier to store IPs in the db as 4-byte unsigned integers. Indexes well and saves space over a varchar.

Pardon these implementation contortions. In our code, we can just work with an ipaddr attribute using '1.2.3.4' strings and expect implicit coercion to integers.

Requires an int unsigned column named ipv4.

Something went wrong with that request. Please try again.