combining cloudbees ec2 docker image with docker in docker

Am trying to combine docker in docker feature with in cloudbees ecs image.
Both the images are build using different linux based distribution.
Cloudbees ECS slave image is build use base ubuntu 14.04 and docker:1.8-dind is build from base debian:jessie. What is the best way to combine both into one docker image with both features using debian:jessie as the base.

  • How to deploy a Docker container on EC2 ECS from Docker Hub private repo?
  • How to build docker images on AWS EC2 Windows Server instance?
  • Hibernate database configuration for cloud deployment
  • docker COPY not working when deploying with docker-machine
  • Unable to connect to dockerized mysql db remotely
  • Graylog2 Docker unable to start
  • Where can i find the tensorflow folder which i pulled from DockerHub? (on windows7)
  • Docker Compose w/ Gulp - Local gulp not found
  • Docker OSX Unable to Access Container via IP Address
  • Docker-machine resource limit
  • can't execute conky on docker
  • Mount non-existing host directory into non-root container
  • One Solution collect form web for “combining cloudbees ec2 docker image with docker in docker”

    I’ve done something similar in the past and it usually comes down to walking the Dockerfile dependency chain and building up the image that way. In your instance, you’d probably want to start at and swap out

    FROM ubuntu:15.04


    FROM debian:jessie

    And build it to see what works and what doesn’t work. Typically it’s a package manager or something that needs to be updated/replaced.

    The downside of this approach is that it can be a lot of trial and error and you end up with giant Dockerfiles, but the upside is that you can usually streamline your image to do exactly what you want without a lot of the Ubuntu extras.

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