ПРОЕКТЫ 


  АРХИВ 


Apache-Talk @lexa.ru 

Inet-Admins @info.east.ru 

Filmscanners @halftone.co.uk 

Security-alerts @yandex-team.ru 

nginx-ru @sysoev.ru 


  СТАТЬИ 


  ПЕРСОНАЛЬНОЕ 


  ПРОГРАММЫ 



ПИШИТЕ
ПИСЬМА












     АРХИВ :: nginx-ru
Nginx-ru mailing list archive (nginx-ru@sysoev.ru)

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: http geoip module по-умолчанию д ля всех виртуальных хост ов


  • To: nginx-ru@xxxxxxxxx
  • Subject: Re: http geoip module по-умолчанию д ля всех виртуальных хост ов
  • From: "anton_last" <nginx-forum@xxxxxxxx>
  • Date: Thu, 15 Sep 2011 09:32:48 -0400
  • Dkim-signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=mickey.jlkhosting.com; s=x; h=Date:Sender:From:References:In-Reply-To:Message-ID:Content-Transfer-Encoding:Content-Type:Subject:To; bh=pBiLhmQMG1Gno4zjF2hhV7nl+WQOnQmgwiXu3dX9i5c=; b=Quby3r15HVY46XUDP6YT4Ys/Y34gnBwo1EsJ/EQzH6ePHj3OBdieyzxkL3DWYUzWKftVUrpA/BK/0BTX8rlNJwGhd+rj/o5DdqHEnamBAZplppZZ8XG1opgSLI/7aQ+0;
  • In-reply-to: <4E71FCC5.5030308@xxxxxxxxx>
  • References: <4E71FCC5.5030308@xxxxxxxxx>

можно пример как сделать с помощью include
и как скриптом?


часть nginx.conf по geoip:
    geoip_country /usr/local/etc/nginx/geoip/GeoIP.dat;
    map $geoip_country_code $black_country {
        default 0;
        include geoip/white_countries;
    }

нужно сделать чтобы не писать в каждом
server {}:
> if ($black_country){
> return 444;
> }

?

а, например, включить/отключить сразу
для всех виртуальных хостов.

Posted at Nginx Forum: 
http://forum.nginx.org/read.php?21,215254,215255#msg-215255

_______________________________________________
nginx-ru mailing list
nginx-ru@xxxxxxxxx
http://mailman.nginx.org/mailman/listinfo/nginx-ru


 




Copyright © Lexa Software, 1996-2009.