Bamboo+Docker+Kubernetes deployment

we are currently playing around with kubernetes+docker. At the moment I’m wondering how to integrate bamboo in our deployment process during development and for release.

Our current CI process is like this:

  • Choice architecture docker for continious integration using docker
  • Docker build/push every time - is it practical for continuous deployment?
  • Jenkins Pipeline push Docker image
  • run docker commands in non-interactive shell
  • Continuous integration from a git lab repository to an amazon server
  • Deploying with Docker into production: Zero downtime
    • dev checks-in code changes to branch “develop”
    • bamboo triggers build process:
      • code is checked out from git
      • run build code (java)
      • run unit+integration tests
      • deploy artifact to artifactory
      • build docker image with artifact
      • tag docker image with artifact version
      • push image to docker hub

    This is the current workflow at the moment. Now I would like to use bamboos deployment functionality to deploy the docker image to our kubernetes clusters.

    From a technical point it should be pretty easy:

    • SSH to the master node
    • start rolling update from the replication controller with the new image

    My question is how do I get the name of the docker image that is created during the build within my deployment task. I already thought that I might create a properties file with the variables which I store as an artifact in the build process.
    I could read-out this property file within my deployment process…

    Somehow this feels more like a workaround..another idea would be to do the deployment directly within the build task and don’t use the deployment functionality at all…

    Is there another option? Has anyone another option/better idea?
    Thoughts/Help would be very nice 🙂

  • Docker failing to load apparmor profile upon ubuntu host boot
  • Docker EC2 & port binding
  • Interact with kafka docker container from outside of docker host
  • Travis Multi-Architecture Buiilds
  • How to recreate Docker container?
  • mysql container linking to only one containers
  • One Solution collect form web for “Bamboo+Docker+Kubernetes deployment”

    I’m not familiar with Bamboo, but Kubernetes 1.2 will support the Deployment API, which will perform the rolling update on your behalf once you update the Deployment spec to the new image tag.

    Alternatively, you could try Openshift 3, which is built on Kubernetes. It supports deployments triggered by image pushes:
    https://github.com/openshift/origin/blob/master/docs/deployments.md#triggers

    Docker will be the best open platform for developers and sysadmins to build, ship, and run distributed applications.