Project

General

Profile

[Solved] rewriting rules with [P] flag (like Apache)

Added by ito over 9 years ago

Hello,
I'm using the mod_proxy Apache2 module and I would to translate this kind of rules for Lighttpd :

RewriteRule ^picts/pict/(.*)\.jpg$ http://from_other_domaine-name.com/dbcontent/pict/$1.jpg [P]

Is it possible to do the same with Lighttpd?
Thank you.


Replies (4)

RE: rewriting rules with [P] flag (like Apache) - Added by darix over 9 years ago

see mod_proxy + mod_rewrite.

RE: rewriting rules with [P] flag (like Apache) - Added by ito over 9 years ago

Tank you for for your reply.
I made a test with mod_proxy + mod_rewrite Lighttpd modules, but mod_proxy works only with IPs in the declaration, no domain name :(

RE: rewriting rules with [P] flag (like Apache) - Added by darix over 9 years ago

your other option is a small fastcgi app.

  1. check if file exists
  2. if not rewrite to your fastcgi app.
  3. let app write the cache file so next hit goes to the file directly

mod_magnet + mod_fastcgi.

    (1-4/4)