From editing a file till the automated deployment pipeline.
Only a nearly complete automated build-, test- , release- and deploymentstructure makes it possible to implement modern architectures, which saves time and let us concentrate on the important things to do, like writing businesscode
We want:
- Versioncontroll with git
- Codestylecheck with codesniffer
- "Copy and Paste" detector to prevent mess
- Automated unittest
- Automatted seleniumtests
- A releasepackage build
- Copy the release artifacts to the artifact manager
- autmate the deployment
For that we need some tools like gitlab, jenkins, sonar nexus and selenium. But noone want to install these tools by hand today.
"Git submodules" and "docker-compose" does the trick for us.
Let's create a tool, that will install these tools for us in a docker construct.
Prerequisits
We need some things installed on the local machine.- docker installed
- docker-compose installed
Get the installscript
We just clone the docker scripts from this repositoryClone setupscripts
$ git clone --recursive https://github.com/pboethig/PhpBuildSystem.git
$ cd builsystem
$ ./startup.sh
This will clone all releated submodules in that main repository
Installed Components
The startup.sh script will execute docker-compose commands for each single application. This will bring up all the needed containers.Use "docker ps" and "docker images" to show the images and containers.
Versioncontrol
- GitLab Community Edition 8.11.4 b871b76
- http://localhost:10080
- username: admin@gitlabsample.com / gitlabadmin
- Github project: https://github.com/sameersbn/docker-gitlab
Buildsystem
- Jenkins 2.0
- http://localhost:8081
- username: admin / admin
- Build your projects, run tests , package them and deploy your application
Artifactmanager
Sonar Nexus Repository Manager OSS 2.13.0-0:- http://localhost:8082
- username: admin / admin
- Its the artifactmanager to store releases and 3rdparty lib
Acceptenstest
- Seleniumgrid
- http://localhost:4444/grid/console
- Its the artifactmanager to store releases and 3rdparty libs
- Git project: https://github.com/elgalu/docker-selenium
Keine Kommentare:
Kommentar veröffentlichen