usually this setup makes "www-data" the owner of /var/www/ and everything 
beneath it, so you'll have to (a) do file operations as 
root/sudo/administrator, (b) add yourself to www-data group and give write 
permission to group, or (c) temporarily give yourself ownership and then 
change it back

in order to have uploaded files deleted when removed from the database, set 
"autodelete=True" in table definition "Field('image', 'upload', 
autodelete=True)"



On Wednesday, July 24, 2013 4:51:05 AM UTC-5, Joe Barnhart wrote:
>
> So a central part of my website is a repository of files/objects that are 
> added and removed.  I've chosen to use the "uploads" folder in my 
> application directory, with additional feature of scattering the files into 
> subdirectories (because I expect a LOT of them).
>
> I'm trying the stock apache2 setup from the book but I find it has no 
> provision for permissions on the uipload directory.  I copied the setup for 
> the "static" directory and was able to put files in the directory, but I 
> can't delete files from the directory within my site.
>
> Has anyone worked out the changes needed to the stock Apache2 setup that 
> accommodates the upload directory?  Seems like it would be a nice 
> addition/update to the book setup.
>
> Joe B.
>

-- 

--- 
You received this message because you are subscribed to the Google Groups 
"web2py-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to web2py+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.


Reply via email to