Server Fault is a question and answer site for system and network administrators. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

As a beginner I have come to the stage where I realize the problem with taking down my production server to make changes as often as I have, now that I have a couple of users on it.

I created an EC2 image of my live server and set up a separate instance on EC2, so now I have 2 EC2 instances, Stage and Production. I set up GitHub and push changes to stage and test my code there, and when it's all done and working, I push it to the production branch, and everything is good. And there is a slight issue here since I name my files config_stage.js and config_production.js and set up .gitignore on each server, and in my code, I would have it read the ENV flags and set up the appropriate configs, is this the correct approach?

And my main question is: how do you keep track of non-code changes to the server? For example, I installed HAProxy, Stunnel, Redis, MongoDB and several other things onto the Stage server for testing and now that it's all working and good, how do I deploy them to production? Right now, I'm just keeping track of everything I installed and copying configuration files over, which is very tedious and I'm afraid I may have missed a step somewhere.

Is there a better way to port these changes over from my test server to my live server?

share|improve this question

closed as primarily opinion-based by Nathan C, Bryan, Ward, Falcon Momot, Scott Pack Jul 21 '13 at 3:58

Many good questions generate some degree of opinion based on expert experience, but answers to this question will tend to be almost entirely based on opinions, rather than facts, references, or specific expertise.If this question can be reworded to fit the rules in the help center, please edit the question.

short answer ?: puppet. Long answer ? puuuuuuuuuuuuuuuuppet. – Sirex Sep 19 '12 at 3:30
..or chef (if you like ruby), or even cfengine (if you don't like hair). Most people are biased on configuration management questions, but I think the agreement will be "you need configuration management" – Sirex Sep 19 '12 at 3:32
Oh, so that's what "configuration management" is. Time to pick up a book.. this'll be fun. Thanks Sirex! – gotta have my pops Sep 19 '12 at 3:41
generally accepted as a really good book is "pro puppet" for puppet people. Likely a good place to start, that and the tutorials online. – Sirex Sep 19 '12 at 3:54

you could consider using fabric to collect, automate and document your deployment routines. it's extremely flexible, and provides a very neat solution to these problems.

share|improve this answer

Not the answer you're looking for? Browse other questions tagged or ask your own question.