Question

I am new to magento and have been working a my first site and it is now ready to go live. I have been advised that once live to also build a staging or development site so that i can in the future work off that before putting any new changes to my live site.

Can i ask what are the best practices in setting this up? My web hosting has said they can offer to set it up within a sub directory of my existing domain but it will just be a copy of the files and database (so doubling my required disk space) and i would need to manually move and copy the files and database info. Is this the only way?

I did see one article but it required a virtual server to store the test site on which i don't have or have any knowledge in setting up

Was it helpful?

Solution

At least you should have a staging server with the sameconfiguration your live site have. This is to prevent server config issues.

Also, its not a good idea to have it in the same server since both sites will be using the same resources to run, which might slow down your live site.

A common environment setup might be 2 separate servers, one for PROD and one for staging/QA with the same setup, maybe provisioned with Ansible and/or Vagrant.

For deploys, you might want to use Jenkins to automate things, and as a hosting provider, i personally like Amazon. A medium to large instance with RDS and Elasticache is pretty fast in my experience.

I created this VM to develop Magento, you might also give it a try: https://github.com/miguelbalparda/vm

OTHER TIPS

We set up a completely different hosting account for our development server. We version our code using Beanstalk git and develop locally using a MAMP/WAMP stack.

In this way, we can create our changes, test them locally. Then, check in the files and promote with one click to development. We test again there and if all is okay, promote to production.

You have to manage configuration settings, of course, but in terms of making code file changes, this works very well for us.

The development server should have similar features as your production server, but it doesn't have to have as many resources (CPU cores, RAM) as your productions server. For instance, we have a basic account at MageMojo for our development server but a much larger account there for our production instances. We can build several installs on one development server even if we have multiple production accounts.

The key is the versioning. Versioning in Magento can be a bit tricky (local.xml file, in particular), but if you git ignore that file (and the media, var directories et al), it works quite well. This gives you roll-back capabilities, as well.

Personally, I use xampp (wamp, or mamp) to have mysql and apache php server on my personal pc, and then I install magento with the sample data http://www.magentocommerce.com/download then you can design, develop, and break it. Once I am pleased I use an FTP client to push them to my live deployment of magento.

Licensed under: CC-BY-SA with attribution
Not affiliated with magento.stackexchange
scroll top