BetterErrors / better_errors

Better error page for Rack apps
MIT License
6.88k stars 437 forks source link

Add domain specification #328

Open manafire opened 8 years ago

manafire commented 8 years ago

Allow users to specify domains in addition to IPs. See: https://github.com/charliesome/better_errors/issues/306

szemek commented 8 years ago

@manafire recently I run into issue that my web server binds to Unix domain socket and code fails when executing allow_ip?(env).

What do you think about changing order of the execution

if allow_domain?(env) || allow_ip?(env)

?

In that case I could solve my problem with:

BetterErrors::Middleware.allow_domain!('socket')
manafire commented 8 years ago

@szemek I have changed the order as you've requested. Hope that works for you.

rubemlrm commented 8 years ago

its possible merge this pull request ? =) i'm working with vagrant env and i'm using custom domain for that instead ips .

RobinDaugherty commented 7 years ago

@Rubemlrm using a custom domain is not secure, as was discussed in #306. Please see the wiki for instructions on setting up vagrant correctly.

rubemlrm commented 7 years ago

@RobinDaugherty sorry for the duplicated error :/ i will check that later , and i will test with docker too , since i've discard the vagrant usage to use docker instead. But anyway thanks for the reply and support =)