# Migrating from Lighttpd/Apache combo: extra path on static files

**URL:** <https://www.ruby-forum.com/t/migrating-from-lighttpd-apache-combo-extra-path-on-static-files/203068>\
**Category:** NGINX\
**Created:** [February 11, 2011, 5:05pm UTC](https://www.ruby-forum.com/t/migrating-from-lighttpd-apache-combo-extra-path-on-static-files/203068 "2011-02-11T17:05:41Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![dubstep](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/d/cdc98d/32.png) [@dubstep](https://www.ruby-forum.com/u/dubstep)\
**Post date:** [February 11, 2011, 5:05pm UTC](https://www.ruby-forum.com/t/migrating-from-lighttpd-apache-combo-extra-path-on-static-files/203068/1 "2011-02-11T17:05:41Z")

</div>

Hi,

I’m migrating a setup for a friend, and hit a snag, I can’t seem to  
find the proper way to do this on nginx.

Assume a directory /my/files/ with a.gif inside. He is using:

location /files {  
alias /my/files;  
}

but then he is requesting /files/a.gif/extra.jpg

With the previous setup, the server would send a.git and ignore the  
extra.jpg. With nginx I get a 404.

Any way to convince nginx to walk to path and serve the first file  
found, or do I have to trick him with rewrite rules?

## Thanks,

Pedro Melo  
[http://www.simplicidade.org/](http://www.simplicidade.org/)  
xmpp:removed\_email\_address@domain.invalid  
[mailto:removed\_email\_address@domain.invalid](mailto:removed_email_address@domain.invalid)
