From Resin 3.0

Jump to: navigation, search

<rewrite-real-path> lets you configure the URL to filename mapping for any URL matching a regular expression. It can be used to create aliases for URL directories that live in a different directory from the expanded .war, e.g. images or static files.


directive description
rewrite directs rewrite-real-path to rewrite the URL and continue processing
regexp the regular expression matching the URL
replacement the replacement pattern for the url
real-path completes the rewriting for a real-path
target the target path


The following example directs the /images URL and its children to an external directory /var/www/images

 <web-app xmlns="">
     <real-path regexp='^/images' target='/var/www/images'/>
Personal tools