I created a (real estate) site which has an area that is used by the agent
to post and edit property listings. They have the ability here to upload
pictures.
If the listing is new, it is assigned an ID, info posted to database and a
directory created using the ID to hold the uploaded pics.
The problem I have is that when they add a listing and the directory gets
created, it is uid/gid apache/apache, and this should work fine for web
access, however, I also need to make it accessible to the owner via ftp so
that they can make site changes, etc.
All of the scripts were uploaded via ftp and have the uid of the owner 10002
I think and gid of the ftp, etc. grp which is 2522.
If I try running a script against the directory created while adding the
listing, I get an error "the program whose uid/gid is 10002/10001 is not
allowed to access...etc.
It would seem that after creating the directory I could chgrp it to 2522
allowing access to it from the web but how can I change the ownership to
10002 at the time of creation?
I am thinking that I might have to run a cron job or something to reset the
perms on those files and directories.
Any suggestions would be greatly appreciated.
to post and edit property listings. They have the ability here to upload
pictures.
If the listing is new, it is assigned an ID, info posted to database and a
directory created using the ID to hold the uploaded pics.
The problem I have is that when they add a listing and the directory gets
created, it is uid/gid apache/apache, and this should work fine for web
access, however, I also need to make it accessible to the owner via ftp so
that they can make site changes, etc.
All of the scripts were uploaded via ftp and have the uid of the owner 10002
I think and gid of the ftp, etc. grp which is 2522.
If I try running a script against the directory created while adding the
listing, I get an error "the program whose uid/gid is 10002/10001 is not
allowed to access...etc.
It would seem that after creating the directory I could chgrp it to 2522
allowing access to it from the web but how can I change the ownership to
10002 at the time of creation?
I am thinking that I might have to run a cron job or something to reset the
perms on those files and directories.
Any suggestions would be greatly appreciated.
Comment