# Location configuration?

**URL:** <https://www.ruby-forum.com/t/location-configuration/238031>\
**Category:** NGINX\
**Created:** [December 12, 2013, 3:31pm UTC](https://www.ruby-forum.com/t/location-configuration/238031 "2013-12-12T15:31:18Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![musicdenotation](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/m/ea666f/32.png) [@musicdenotation](https://www.ruby-forum.com/u/musicdenotation)\
**Post date:** [December 12, 2013, 3:31pm UTC](https://www.ruby-forum.com/t/location-configuration/238031/1 "2013-12-12T15:31:18Z")

</div>

I’m reading through the nginx architecture document at  
[Redirecting…](http://www.aosabook.org/en/nginx.html).

The location configuration is called out in a few places. For example:

```
Phase handlers typically do four things: get the
location configuration, generate an appropriate
response, send the header, and send the body.

```

What is the location configuration, and why is it significant?

Thanks in advance.

---

<div class="post-metadata">

**Author:** ![Jeffrey\_W](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/j/6f9a4e/32.png) [@Jeffrey\_W](https://www.ruby-forum.com/u/Jeffrey_W)\
**Post date:** [December 12, 2013, 3:37pm UTC](https://www.ruby-forum.com/t/location-configuration/238031/2 "2013-12-12T15:37:44Z")

</div>

On Thu, Dec 12, 2013 at 6:30 AM, Jeffrey W. [removed\_email\_address@domain.invalid](mailto:removed_email_address@domain.invalid)  
wrote:

> I’m reading through the nginx architecture document at  
> [Redirecting…](http://www.aosabook.org/en/nginx.html).  
> …  
> What is the location configuration, and why is it significant?

e.g.: (assuming some web root set)  
…  
# location configuration for directly serving files from directory  
location /dist {  
proxy\_max\_temp\_file\_size 1m;  
autoindex off;  
}  
# default handler location configuration for passing to upstream  
proxy  
location ^~ / {  
proxy\_pass [http://upstreamproxy](http://upstreamproxy);  
}  
…

best regards,

---

<div class="post-metadata">

**Author:** ![Jeffrey\_W](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/j/6f9a4e/32.png) [@Jeffrey\_W](https://www.ruby-forum.com/u/Jeffrey_W)\
**Post date:** [December 12, 2013, 3:44pm UTC](https://www.ruby-forum.com/t/location-configuration/238031/3 "2013-12-12T15:44:45Z")

</div>

On Thu, Dec 12, 2013 at 9:36 AM, coderman [removed\_email\_address@domain.invalid](mailto:removed_email_address@domain.invalid) wrote:

> ```
> proxy_max_temp_file_size 1m;
> autoindex off;
> }
> # default handler location configuration for passing to upstream proxy
> location ^~ / {
> proxy_pass http://upstreamproxy;
> }
> 
> ```
> 
> …  
> Thanks. For some reason, I was thinking along the lines of IP  
> addresses and geolocation.
