Improve multi-site support
mikestefff - May 8, 2009 - 23:55
| Project: | Bitcache |
| Version: | 6.x-1.x-dev |
| Component: | Miscellaneous |
| Category: | feature request |
| Priority: | normal |
| Assigned: | Arto |
| Status: | needs work |
| Issue tags: | multisite |
Jump to:
Description
Hey - me again..
I understand that FileFramework takes over file handling, in terms of public and private download settings. The application I am developing depends very highly on file security and privacy. Is it possible to move the bitcache file directory to a non web-accessible directory (not inside /sites/default/files/ etc)? Also, is there a way to specify a directory for each subsite to use? I'll be creating hundreds of subsites (*.mywebsite.com) and I'll need a separate directory for each site - I'm sure you understand..
Thanks again

#1
I think you can set a 'bitcache_root' variable directly in the db. Arto, can you correct me?
#2
Seems there isn't a variable for bitcache but the bitcache_repositories table seems to be the winner. The file repository row contains - a:3:{s:5:"title";s:14:"File framework";s:11:"description";s:50:"A repository for the file framework managed files.";s:8:"location";s:33:"sites/default/files/bitcache/file";}.
It's a little harder to work with for multisites cause I can't override it in settings.php but whatever works...unless theres something better.
#3
No other way to change it? Seems strange that there wouldn't be a setting for it. Would get confusing with multisites.
#4
Execute:
bitcache_update_repository('file', array('title' => 'File framework', 'description' => 'A repository for the file framework managed files.', 'location' => '/new/file/path'));#5
Dave's suggestion in #433708: Make all repositories configurable for a dynamic file path based on a
!site_dirtoken could be useful for multi-site support.