Hrmm, im not sure what im doing wrong then, i am mostly using default config,&nbsp;<div>only 1 server {}&nbsp;<br><div><br><div><div>stopping and starting using /usr/local/etc/rc.d/nginx stop</div><div><br></div><div><br></div><div>
worker_processes &nbsp;2;</div><div><br></div><div>events {</div><div>&nbsp;&nbsp; &nbsp;worker_connections &nbsp;1024;</div><div>}</div><div><br></div><div><br></div><div>http {</div><div><br></div><div>&nbsp;&nbsp; &nbsp;include &nbsp; &nbsp; &nbsp; mime.types;</div><div>&nbsp;&nbsp; &nbsp;default_type &nbsp;application/octet-stream;</div>
<div><br></div><div><br></div><div>&nbsp;&nbsp; &nbsp;sendfile &nbsp; &nbsp; &nbsp; &nbsp;on;</div><div>&nbsp;&nbsp; &nbsp;#tcp_nopush &nbsp; &nbsp; on;</div><div><br></div><div>&nbsp;&nbsp; &nbsp;#keepalive_timeout &nbsp;0;</div><div>&nbsp;&nbsp; &nbsp;keepalive_timeout &nbsp;65;</div><div><br></div><div>&nbsp;&nbsp; &nbsp;#gzip &nbsp;on</div>
<div><br></div><div>&nbsp;&nbsp; &nbsp;server {</div><div>&nbsp;&nbsp; &nbsp; &nbsp; &nbsp;listen &nbsp; &nbsp; &nbsp;<a href="http://127.0.0.1:8080">127.0.0.1:8080</a>;</div><div>&nbsp;&nbsp; &nbsp; &nbsp; &nbsp;server_name &nbsp;_;</div><div><br></div><div>&nbsp;&nbsp; &nbsp; &nbsp; &nbsp;#charset koi8-r;</div><div><br></div><div>
&nbsp;&nbsp; &nbsp; &nbsp; &nbsp;#access_log &nbsp;logs/host.access.log &nbsp;main;</div><div><br></div><div>&nbsp;&nbsp; &nbsp; &nbsp; &nbsp;location / {</div><div>&nbsp;&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;root &nbsp; /usr/local/www/nginx;</div><div>&nbsp;&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;index &nbsp;index.html index.htm;</div><div><br></div><div>
&nbsp;&nbsp; &nbsp; &nbsp; &nbsp;}</div><div>&nbsp;&nbsp; &nbsp;}</div><div>}</div><div><br><div class="gmail_quote">On Sat, Feb 21, 2009 at 9:19 PM, Igor Sysoev <span dir="ltr">&lt;<a href="mailto:is@rambler-co.ru">is@rambler-co.ru</a>&gt;</span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;">
<div class="Ih2E3d">On Sat, Feb 21, 2009 at 08:54:05PM +1100, Gendouki Office wrote:<br>
<br>
&gt; I am trying to make nginx only accessible by localhost:8080<br>
&gt; i have tried doing<br>
&gt;<br>
&gt; server {<br>
&gt;<br>
&gt; listen &nbsp;<a href="http://127.0.0.1:8080" target="_blank">127.0.0.1:8080</a>;<br>
&gt;<br>
&gt; &nbsp; &nbsp; &nbsp; &nbsp; server_name &nbsp;_;<br>
&gt;<br>
&gt; ...<br>
&gt;<br>
&gt;<br>
&gt; however it still accepts requests from external ip&#39;s<br>
&gt;<br>
&gt;<br>
&gt; how can i stop this?<br>
<br>
</div>This should work.<br>
Have you are server{}s in configuration ?<br>
<div class="Ih2E3d"><br>
&gt; i have also tried<br>
&gt;<br>
&gt; allow 127.0.0.1;<br>
&gt;<br>
&gt; deny all;<br>
<br>
</div>This should work too.<br>
<div><div></div><div class="Wj3C7c"><br>
&gt; but this seems to deny localhost as well<br>
&gt;<br>
&gt; running latest stable 0.6<br>
<br>
<br>
</div></div><font color="#888888">--<br>
Igor Sysoev<br>
<a href="http://sysoev.ru/en/" target="_blank">http://sysoev.ru/en/</a><br>
<br>
</font></blockquote></div><br></div></div></div></div>