https://bitbucket.org/jorkar/automagically_install
I took a quick look in it and it might be a little rough (overwritting) on your Apache/MySQL config files but apart from that Jörgen also has nicely written instructions on how to do the installation. (Haven't tried to execute it thou, because I already have automagically installed on my RPi).
Many thanks to Jörgen for this work!