Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

I'm running two webservers in a single host. One of them is a Tomcat running in a reverse proxy configuration. The front webserver is a nginx that proxies request to the Tomcat.

So far, is working ok.

A location in a domain, let's say domain.com/photos is server by Tomcat. I'd like the photos to be server by nginx. The files are stored in a folder, but the files are written by Tomcat application and the files end up with owner tomcat and group tomcat.

The nginx process is running in www-data group, so it cannot retrieve the files.

How can I accomplish that the the webservers runs under the same group? Is a good practice to use newgrp before starting the webservers, so both runs under the same group?

Thanks.

share|improve this question

1 Answer 1

Have you considered just adding your nginx user to the tomcat group? Seems like an easy solution...

share|improve this answer
    
Thanks. I didn't realize of that option. –  user59614 Nov 11 '10 at 14:17

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.