views:

65

answers:

2

There are some Magento Connect extensions that I find myself installing every time I create a new project, such as Fontis_Recaptcha, Mass_Product_Relater, HM_DeveloperToolbar, ModuleCreator, Alanstormdotcom_Layoutviewer, etc. What's on your list?

Does anyone know of a capability to automate the installation of a base set of modules? In the same way that Mage itself installs all its modules. I guess a bash or phing script to automate PEAR? Thoughts?

+1  A: 

I would take another approach. Install a clean installation and add all your extension. When your done export the DB and zip all the files. Then you should be able to use the files and the DB as a base for all your magento installations...

I do the same with Joomla, have not tried that with magento yet, but it should work.

silvo
Wouldn't this become laborious if you wanted to add a new plugin (or plugin version), not to mention Magento major/minor revision? It seems like it would work in theory, but in practice you'd probably have to rebuild your clean image as often as you get to use it.
Joseph Mastey
I think it is just a matter of changing the configuration to cater for the new physical (directory structure) and logical (url) location of the store. It should be possible to write a script which changes all the appropriate config data on install.
silvo
I link the idea @silvo, but I was thinking the same as @Joseph has described. You would need to run a `./pear mage setup` and remove all the `downloader` ini files to avoid the (well documented - http://www.magentocommerce.com/wiki/groups/227/downloader_upgrades_wrong_store) problems with updating the wrong locations. I would want to update all the plugins on install anyway to check for latest, so while having a "canned" install might be helpful, there are still steps that would benefit from automation. Right?
Jonathan Day
+1  A: 

Cant you just use the auto installer script as provided and maintained here:

http://www.magentocommerce.com/wiki/groups/227/magento_bash_script_installer

and edit it to install your desired extensions

ie just add ./pear install xxxxxxx at the end of the script.

Andy Bird
Yeah, quite a good idea. Unfortunately a couple of those extensions (e.g. Alanstormdotcom_Layoutviewer and _Configviewer) aren't actually installed by pear, but there's no reason why the bash script couldn't manually `cp` those files into the new install. Obviously it wont work in Windows XAMPP (without Cygwin anyway). I wonder if there's a concept of a meta-extension that could install latest magento-connect extensions...
Jonathan Day