git rebase is a very useful construct in source control management, as it allows you to re-apply your changes atop a different branch of the same repository. While this concept transitions perfectly to container management (updating a container could be as easy as a docker rebase), and the Docker client is inspired by the git semantics, Docker has no such feature (in fact, Solomon Hykes used rebase and merge as examples of things "that we don't want"). Currently, zypper-docker works by applying an updated layer on top of an existing image. While this does work quite well, it separates the process of updating the base image and updating all of your derivative images (you need to re-download new packages for each derivative image).

So, this project will be working on implementing something like git rebase for Docker images. There are several issues with this, mainly involving the fact that we are rebasing binaries and not source code, so merge conflicts will probably be quite messy. But it should be possible to implement some form of simple rebase method (which will essentially fall back to docker build in the worst case, which is what you were going to run anyway). By maximising the reuse of the existing image layers, it should be possible to reduce build times quite significantly.

Unfortunately, it seems like there's no nice way of implementing docker rebase without having access to the internal image format of Docker (as docker diff only gives you information on containers and not on images). Further work could be done to see what would be required to do as-close-as-possible live-rebase of a docker container.

Status:

  1. Load Docker image graphs [DONE].
  2. Resolve common-parent and non-common-parent cases [DESIGNED].
  3. Recognise updated layers (using the CMD) [DESIGNED].
  4. Deal with #(nop) [DESIGNED].
  5. Figure out how to nicely do single layer builds [STUCK].

Looking for hackers with the skills:

docker

This project is part of:

Hack Week 13

Activity

  • over 8 years ago: cyphar liked this project.
  • over 8 years ago: cyphar disliked this project.
  • over 8 years ago: cschum liked this project.
  • over 8 years ago: fanyadan liked this project.
  • over 8 years ago: ancorgs liked this project.
  • over 8 years ago: cyphar liked this project.
  • over 8 years ago: cyphar started this project.
  • over 8 years ago: cyphar added keyword "docker" to this project.
  • over 8 years ago: cyphar originated this project.

  • Comments

    Be the first to comment!

    Similar Projects