I did the same thing at my last place. What we had was:
- a repository per website
- a branch for each website dedicated to the live site (i.e.
/branches/live
) and test site (i.e. /branches/testing
)
- 2 webservers which could talk to SVN
- a test server which could talk to SVN
- all servers had SVN command-line client installed
Each webserver operated independently, so they didn't really know about each other - that was left to the load balancer. Each server had a cronjob that ran every 3 hours and exported the latest version of each website's live
branch into the correct folder on the file system.
On our test server, it was a checkout of the testing
branch for each website, and no cronjob. Developers updated the folders whenever they wanted to put something out for users to test before it went live.
During developments, commits were made to the trunk
of the website. When changes were ready for testing, they were merged into the testing branch and the checkout updated manually on the test server. When changes were ready to go live, they were merged to the live branch and the servers would have updated by the end of the day.
In 3 years we only had one issue where a developer had committed something incorrectly and had to roll the site back.