![]() How to develop and publish PHP websitesHow to collaborate on a PHP site and publish easily SummaryDeveloping a website with others and publish without problems can be quite a challenge. In this tutorial we will look at setting up a collaboration platform with GIT as our Source Code Control System. To setup our own development or test environment we will use JAVA property files containing the production site environment settings as well as our own deviations for our local development environment. When all is done we use ANT in combination with GIT and FTP to create a version we can blindly upload. Although this tutorial is aimed at the Ubuntu/Linux audience, all the tools are available on Windows as well. GoalLearn how to collaborate on building and deploying websites build with PHP. AudiencePHP Developers Prerequisites
Required knowledge
Required tools
Tutorial lessonsThis tutorial exists of a number of lessons which must be followed in order to reach the desired effect. Please review each step by clicking on the title 1 - The problemBefore we set out to solving the problem, we should have a clear understandig of what the problem is exactly. Now we have a clear understanding of the local environment problems and why you should consider using a build script before uploading. 2 - Breaking the problem into partsWe have seen what the two main problems are in collaborating on PHP websites. Now we will break the problem apart and link them to solutions. Now you have global knowledge of the solution we will work on in the next lessons. 3 - Setup GITAlthough this chapter is in no way a full GIT tutorial we walk through the basic steps to setup a shared GIT repository, and show how to create a local working tree considering the local and production configuration settings file. First we will setup a bare GIT repository and then clone it to a local repository. Last we will add our JAVA property files to setup the configuration. 4 - Setup local environmentIn this lesson we will setup a local environment. You now have a basic working environment. 5 - Setting up PHP filesIn this lesson we will setup the PHP environment to handle our JAVA Property configuration files. You now have a working development environment. Committing files to the repository is a no-brainer. The production environment configuration is easily maintainable by all developers. 6 - Commit to central repositoryNow we have a working example that we should commit to the central repository, before we can add new developers. 7 - Setup ANTIn this lesson we will look at the next part: setting up ANT to create an uploadable site. Now we have a basic setup for ANT. Next step is to expand with changing properties. 8 - ANT next stepsIn this lesson we will finish up on ANT and make our PHP files ready for deployment using FTP. Now your PHP website is ready for uploading to the production environment. Tags |