Adding Piwik to Apps folder - merging Perusio configs correctly

luxpir's picture

I'm trying to make use of Perusio's Piwik config alongside his Drupal config. I've copied the Piwik config files to /etc/nginx/apps/piwik/ and created a .conf file using the subdomain suggested ( This has the include to /apps/piwik.conf in it, as per the example conf file provided.

Do I need to add a DNS record/'officially' create a subdomain to run Piwik from that URL? If possible, I'd rather use an structure, but that's proving tricky.

If I wanted to run it from a directory under www, what server_name would I use, so as not to create a conflict with existing .conf files?


It's not that hard.

perusio's picture

For starter include the piwik config at in the the drupal site.

Then prefix all the locations, except the regex based ones, with the directory. For example if your directory is named piwik prefix like here:

Piwik is much simpler than Drupal.


luxpir's picture

I was overcomplicating it, creating another .conf for piwik in sites-available. Scrapped that on your advice, added the include in the Drupal site and added the prefixes. Thank you for your help/configs and dedication to performance :)