Take the 2-minute tour ×
Server Fault is a question and answer site for system and network administrators. It's 100% free, no registration required.

Somehow I couldn't find a related question that quite fit me.

Anyway, I run a small blog. When I first started my blog it had next to no traffic, now it receives a couple hundred views per day though, hence my need for a new process. I have my website in a mercurial repository (on bitbucket). My previous method of updating it was to do something like

cd /srv/mywebsite
sudo svn update
sudo xbuild <release configuration options>

I feel that doing this is really not the best way. Also, previously I was using SVN, and for this next update, I've converted to Mercurial, so this won't quite work so easily.

What is probably the best way to update my simple website?

Things to keep in mind:

  • My website directory contains various non-versioned files such as images I've added as part of my blog content and such
  • My website runs on Arch Linux server and uses mod_mono+Apache+MongoDB (though database changes are quite rare)
  • There is at least one versioned file which varies between development and production. This contains database connection strings and other internal configuration
  • Downtime isn't a huge issue, but I really try to avoid more than 15 minutes per update

Surely someone out there has to manage a similar set up. What's the easiest way to do this? (preferably without having to "deploy" from my local machine and manually merge configuration files)

share|improve this question

closed as off topic by John Gardeniers, Ward, Michael Hampton, HopelessN00b, Hubert Kario Oct 7 '12 at 14:54

Questions on Server Fault are expected to relate to server, networking, or related infrastructure administration within the scope defined by the community. Consider editing the question or leaving comments for improvement if you believe the question can be reworded to fit within the scope. Read more about reopening questions here.If this question can be reworded to fit the rules in the help center, please edit the question.

Honestly, I get 10x that traffic and still use rsync. –  Magellan Oct 3 '12 at 4:34
@Adrian hmm.. I didn't think of using rsync. That could also be extremely handy for uploading new files. –  Earlz Oct 3 '12 at 4:37
I'll flesh out a more detailed answer and pop it in below. –  Magellan Oct 3 '12 at 4:56
FYI, if an answer works for you, it's a courtesy to close it out by marking the answer as accepted. –  Magellan Oct 7 '12 at 4:37
@Adrian I know. I usually wait until I actually implement a solution before marking it as the answer –  Earlz Oct 7 '12 at 5:58

1 Answer 1

I've been running a automotive enthusiast website that's been getting 500-1000 page views for about 10 years now.

For most of that time, I've been running my updates via rsync. The core is Wordpress but the non-WP content is stored locally and rsync'd to the web host via rsync from my local machine.

Rsync is quite nice in that it allows you to exclude particular files such as your php.ini, mysql.cnf, and similar environment-specific configuration files from the command line.

For example, my slightly-obfuscated usage:

rsync -rlptP ~/lcl/* username@webhost:/home/username/www/

Note: I don't use the '-a' switch as that would include the user & group which are different between the sites.

share|improve this answer

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