I'm quite sure that with the latest version of SS, those four files don't need mods.
We've moved the forum!
Please use forum.silverstripe.org for any new questions
(announcement).
The forum archive will stick around, but will be read only.
You can also use our Slack channel
or StackOverflow to ask for help.
Check out our community overview for more options to contribute.
Yes, it works!
1 hour ago, beginning from a fresh 2.3.2 installation and simply modifying /sapphire/core/model/Image.php on four places (replace all "../" with Director::baseFolder()."/") we have a working master-symlink environment with no issues so far. Images are uploaded, resampled and thumbnailed correctly.
So the recipe for using symlinks is;
1. Copy the silverstripe files to a master silverstripe directory; ex. "silverstripe232"
2. Don't install it :) (perhaps thats ok too?)
3. Copy assets, mysite, themes folders to another directory; ex. "mysymlinkedsite"
4. Set the correct rights to these folders
5. Create symlinks to the shared folders (saphhire, cms, etc.)
6. Create a "silverstripe-cache" folder in your "mysymlinkedsite"
7. Proceed with the installation as normal (by visiting e.g. localhost/mysymlinkedsite)
8. Enjoy (if I haven't forgotten anything... :)
Thanks to Uncle Cheese, JamesS and quamsta for helping us!
Tim
Great summary, TWoSH. I'm glad that this is solved. Now, I'm curious. Would it be appropriate to submit these changes to Image.php to the bug tracker? I'm not familiar with the protocol for that sort of thing, but I think it would be a worthy fix for the next release of SilverStripe.
TWoSH - I think thats a very valid change to the core which enables much more flexibility with users setup. You might like to submit this as a diff patch to open.silverstripe.org and would be great to have this information on the wiki.
Thanks guys!
willr - where do I start? :) I visited open.silverstripe.org but that link wasn't too helpful... :)
Regards,
Tim
Sorry we are currently moving open to a new server. When its back it will have links to submitting patchs etc
Great setup, thanks :-)
How would you guys go about installing modules. I guess by separate symlinks, so you could still easily add new modules to individual sites?
And how about patching or upgrading to a new version. Since Silverstripe versions are not always backwards compatible - would you create a new master and modules path, and then change the symlinks per site, in order to be able to check if everything works? That would be a lot of work still...
Or would you just change the existing code, and 'see what happens'?
Unfortunately, you can't share modules. The bootstrap process in SS just won't follow the symlinks. The way we do that is with SVN. On a new site set up, we'll run something like
new_ss_site mysite.com dataobject_manager, swfupload, event_calendar
and all those modules get checked out into the vhost via SVN.