Hi there, I have a problem with permissions on a virtual hosting webserver :
If "user a" logs in to an ftp account, and uploads files, they are owned by 1200:1200 ( where 1200 is their uid and gid ). The web server can read them, but when the web server creates files ( i.e. from a php script ) they are created as the web server, user/group www-data. Depending on the permissions of the files the webserver creates, the ftp user may or may not be able to edit them. Idealy you could set the webserver to run as GID/UID _per_virtualhost_ , and this feature is coming in apache 2 ( but not stable yet, esp with php). What are the work-arounds for this problem until then?
I plan to use virtual ftp users and can specify an arbitary UID/GID in mysql. ( proftpd + mysql )
I'm really interested in how other ISP's / hosting companies do this..
Not sure of a workaround from the server/ISP point of view, but when one of my scripts writes a file I tend to chmod or chown it from within the script immediately after it's written, so that its permissions are set as if I'd uploaded the file.