views:

220

answers:

3

Does it exist? Basically I'm developing a Django app on my local machine, when I've finished adding my feature and get it working locally, I want to commit it, and then update the production server. Then I want to automatically restart apache. Is this possible? How?

A: 

Why a post-commit hook not appropriate?

erenon
How would that work? I'm committing from my local dev machine... restarting apache at that point in time wouldn't do anything. Apache needs to be restarted *after* the production files have been updated.
Mark
So how are you updating the remote server then? You seemed to imply you wanted to commit, and have the server update and restart - in which case you could do both in the post-commit hook. If you are updating the remote server manually, then why couldn't whatever script you are using to do that be extended to restart the server as well?
Daniel Roseman
I'm updating the remote server manually. I'm a naughty boy and all my commits aren't necessarily stable, so I don't want to update the server immediately. You're quite right that I could just use an update-and-restart script instead, Daniel. That'd work.
Mark
+1  A: 

The following probably wouldn't apply to you, as your more than likely in a linux environment, but on Windows, TortoiseSVN supports a post-update hook on the client side, if you go into Settings then Hook Scripts

phsr
Yeah.. that doesn't really help at all :\ I do have tortoise installed on my dev machine, but my production server is indeed linux.
Mark
+3  A: 

Seems like you want a CI server? http://en.wikipedia.org/wiki/Continuous_integration

svinto