# Emoncms and Lighttpd?

**URL:** <https://community.openenergymonitor.org/t/emoncms-and-lighttpd/1644>\
**Category:** Getting Started\
**Created:** [20 September 2016 15:07 UTC](https://community.openenergymonitor.org/t/emoncms-and-lighttpd/1644 "2016-09-20T15:07:52Z")\
**Posts on this page:** 1\
**Showing post:** 2

<div class="post-metadata">

**Author:** ![revil.o](https://community.openenergymonitor.org/letter_avatar_proxy/v4/letter/r/22d042/32.png) [@revil.o](https://community.openenergymonitor.org/u/revil.o)\
**Post date:** [25 January 2017 06:42 UTC](https://community.openenergymonitor.org/t/emoncms-and-lighttpd/1644/2 "2017-01-25T06:42:21Z")

</div>

Hi warpme,

i have tried some regex and now emoncms is running on my raspberry pi 2 served by lighttpd.

> 

Enable mod\_rewrite in lighttpd.conf

path to my emoncms-Installation: ( installed via git pull , install via apt-get not preferred → apt will install apache2 and some other modules i don’t need !)

> /var/www/html/emoncms

put the following code to the end of the lighttpd.conf-file, you have to change it for your installation-environment(replace /emoncms/ with your needs)

> 

url.rewrite-if-not-file = (  
“^/emoncms/([^?]_)?(._)$” =\> “/emoncms/index.php?q=$1”,  
“^/emoncms/([^?]_)$" =\> “/emoncms/index.php?q=$1”,  
"^/emoncms/([^?]_)(?(.+))?$” =\> “/emoncms/index.php?q=$1”  
)

voila, emoncms should now be running correctly on your raspberry pi with lighttpd-server!

 ![](https://community.openenergymonitor.org/uploads/default/original/2X/f/f850168ba5294f366d17577b4b7e36d73a144d2f.PNG)

so long

revil.o

---

_[View the full topic](https://community.openenergymonitor.org/t/emoncms-and-lighttpd/1644)._
