Separating Subversion Repository and Creating Deployment Strategy
I have two separate components of my site: the website (MVC) and scraper based on php cli. Both components share common model files but are deployed on separate servers. Right now they both employ the same repository.
I am looking to outsource development of the scraper but am looking to keep website development in house. So, I think the best way to do this would be to setup separate repositories for the site, scraper and shared files. But, I am not sure how to do this.
Also, I do not have a strong deployment strategy. Currently I just copy over files whe开发者_高级运维n changes need to be made and store a backup.
Any advice on how to manage this setup best?
You could have a look on the property svn:external
.
I do not recommend you to separate the repositories, because it makes the process of getting tags (i.e. consistent snapshots) harder. Many times, you will need to keep the last stable version of the whole system, which will not be so easy when repositories are separated. For a deployment strategy, I propose you to have an automatic build strategy for your code. You can use Phing for this aim. Phing allows you to build what is needed to update your deployment. Configure your svn server in such a way to build your whole project using the Phing script after each check in.
Then, your build results can be automatically copied to a test server for more tests on development site. After getting an OK from QC, you can deploy the binaries on the real server.
精彩评论