git deployment - more simple than capistrano

Hi,

Previously I've deployed on my server (apache / passenger) with simply git clone foo, and then pull in version updates with git pull. While I read lots re staging servers and capistrano it works pretty well for me. Anyone else do it my way? Don't really have time for learning capistrano right now. Is there a better way though - e.g. using tags to deploy particular versions - or should I branch or something before cloning to the server.

Apols if my terminology is not 100%, I'm not that comfortable with git bar, push/pull/commit so any tips in code as to how I might do it better appreciated. About to deploy a new project basically.

bb

Hi,

Previously I've deployed on my server (apache / passenger) with simply git clone foo, and then pull in version updates with git pull. While I read lots re staging servers and capistrano it works pretty well for me. Anyone else do it my way? Don't really have time for learning capistrano right now. Is there a better way though - e.g. using tags to deploy particular versions - or should I branch or something before cloning to the server.

A lot depends on the scale of your situation. Doing things by hand is one thing when you have a single server, but clearly a terrible idea with 15.

I don't like deploying trunk/master because it makes it slightly more fiddly if I need to deploy an urgent fix without deploying the rest of master (which may not be ready for prime time). Not a lot more fiddly, but if you're in that situation it's usually a crisis of some sorts and I prefer to minimize complication at that point. Having tags for all of your deploys also makes it dead easy to answer the question 'what code was running at date x' or 'since when has this code been live'. You can obviously get pretty close with your commit logs, but those won't tell you when you deployed.

A basic capistrano setup is really pretty simple - there's not a lot more to do than take the default template and type in server addresses, source repository location etc. I also like having a fresh checkout for each deploy. I also hear the some people have a good time with vlad the deployer.

Fred

bingo bob wrote in post #970867:

Hi,

Previously I've deployed on my server (apache / passenger) with simply git clone foo, and then pull in version updates with git pull. While I read lots re staging servers and capistrano it works pretty well for me. Anyone else do it my way?

No way!

Don't really have time for learning capistrano right now.

Then you don't have time to be developing a Rails app.

Is there a better way though - e.g. using tags to deploy particular versions - or should I branch or something before cloning to the server.

You should always tag or branch each release.

Apols if my terminology is not 100%, I'm not that comfortable with git bar, push/pull/commit so any tips in code as to how I might do it better appreciated. About to deploy a new project basically.

Then learn Capistrano (or Inploy, perhaps). Now. If you're not willing to do that, then deploy to Heroku.

Best,

If you are only using git , your project is very simple. With capistrano i copy over the database.yml file, redeploy symlinks for confidencial files that are not in the public folder and are server with send_file, reindex sphinx, restart starling and workling and run any pendding migrations. thanks capistrano :')