retr0h / railsolver
- Source
- Commits
- Network (0)
- Issues (0)
- Downloads (0)
- Wiki (1)
- Graphs
-
Branch:
master
railsolver / README.rdoc
Railsolver
This plugin will "hijack" Ruby host(s) resolver aka(resolv-replace.rb), allowing programmatic host file resolution (including wildcard host resolution).™
Example
Create the hosts file at:
RAILS_ROOT/config/hosts.yml
Hosts can be added globally or overridden per environment. ERB is also supported inside the configuration.
app.dewey.ws: <%= #!SOME_RUBY_CODE %>
development:
app.dewey.ws: 192.168.0.1
Experimental
One can specify "wildcard" hosts (more or less). The host ‘baz.foo.com’ will match the most specific (‘baz.foo.com’) when present in hosts.yml. Otherwise, it will match ’.foo.com’ then ’.com’.
.com: 1.1.1.1 .foo.com: 6.6.6.6 bar.com: 10.10.10.2 baz.com: 10.10.10.3 baz.foo.com: 10.10.10.4
Copyright © 2008 John Dewey <john@dewey.ws>, released under the MIT license
