Upgrade to Pro — share decks privately, control downloads, hide ads and more …

Continuous Integration with Bamboo and Docker

Avatar for johnny-tu johnny-tu
November 17, 2015
290

Continuous Integration with Bamboo and Docker

Avatar for johnny-tu

johnny-tu

November 17, 2015
Tweet

Transcript

  1. Date 2013 | Confidential | ServiceRocket Date 2013 | Confidential

    | ServiceRocket Continuous Integration with Bamboo and Docker 1
  2. Date 2013 | Confidential | ServiceRocket About Me • Johnny

    Johnny Johnny Johnny Tu Tu Tu Tu - Based in Sydney, Australia - Software training and curriculum development 2
  3. Date 2013 | Confidential | ServiceRocket Continuous Integration • A

    process of ensuring there is a constant working copy of your system that is fully integrated - Integration problems always exist in projects where components are developed independently and integrated at the end - With Continuous Integration, integration is frequent • Started out as one of the Extreme Programming practices • Bugs are found and resolved faster • Greater visibility in a project 3
  4. Date 2013 | Confidential | ServiceRocket Docker Docker Docker Docker

    is a platform for developing, shipping and running applications using container technology • The Docker Platform consists of multiple products/tools - Docker Engine - Docker Hub - Docker Trusted Registry - Docker Machine - Docker Swarm - Docker Compose - Kitematic What is Docker? 5
  5. Date 2013 | Confidential | ServiceRocket Docker Containers and Images

    • Images - Read only template used to create containers - Built by you or other Docker users - Stored in Docker Hub, Docker Trusted Registry or your own Registry • Containers - Isolated application platform - Contains everything needed to run your application - Based on one or more images 7 Image Container Creates
  6. Date 2013 | Confidential | ServiceRocket Dockerising Applications • Take

    an existing application and run it inside a Docker Container • The container will have all the tools and libraries required to run the application - i.e. Java, Tomcat, third party libraries etc… • Container can be run on any environment with the Docker Engine installed • Use a Use a Use a Use a Dockerfile Dockerfile Dockerfile Dockerfile to build image to build image to build image to build image • QUICK DEMO QUICK DEMO QUICK DEMO QUICK DEMO 9
  7. Date 2013 | Confidential | ServiceRocket Typical Bamboo Build Plan

    10 Compile code Build Plan Compile Stage Testing Stage Unit test suite 1 Unit test suite 2 Package Stage Build Application Package Deployment Project Development Environments QA Staging Production
  8. Date 2013 | Confidential | ServiceRocket Bamboo Build Plan with

    Docker 11 Build image from Dockerfile Build Plan Compile Stage Testing Stage Package Stage Push image to DockerHub Deployment Project Run application container in Development Environments Run test suite 1 in container Run test suite 2 in container Run application container in QA Run application container in Staging Run application container in Production
  9. Date 2013 | Confidential | ServiceRocket Benefits • Less infrastructure

    requirements - Each build machine only requires Docker Engine installed - No need to install additional build tools or application servers - Run dev, staging and production on one server • Improved testing time - No need to potentially spin up a new VM for each test suite - Spin up containers instead -> faster start up time • Improved build time 12
  10. Date 2013 | Confidential | ServiceRocket CI/CD Infrastructure without Docker

    13 Bamboo Server Bamboo Remote Agent Bamboo Remote Agent Dev environment Staging environment Prod environment
  11. Date 2013 | Confidential | ServiceRocket CI/CD Infrastructure with Docker

    14 Bamboo Server Bamboo Remote Agent Bamboo Remote Agent Dev environment Staging environment Prod environment