Bakalářská práce

Building docker images without accessing /build API endpoint

František Lachman, učo 433670
Anotace

Docker je současně nejrozšířenějším kontejnerizačním systémem. Jeho živelný vývoj přináší četné změny rozhraní a dílčí nástroje často nedostačují potřebám uživatelů. Obvyklou volbou pro vytváření kontejnerových obrazů pro tuto platformu je nástroj docker builder, kterému chybí několik vlastností, jenž společnost stojící za tímto projektem nemá v plánu implementovat. Dodávaný nástroj neumožňuje použití …více

Abstract

Docker is nowadays a most popular containerization platform. Its quick development causes frequent API changes and the provided tools often not satisfy the need of all users. The common method for creating container images for this platform is to use a docker builder, which has some missing features, that the company behind is not going to implement. This component does not allow defining secrets …více

Zadání práce

Docker Inc., the company behind popular container engine, aims to move code for building images out of server. The component is named builder currently and is available at URL /build in daemon’s API. It is the most common and official method of building images.

Upstream already managed to implement all low-level API calls which were needed to create an image (these were used internally by build API call). These functions are:

  • create and start container
  • commit container – transform a container to an image (this call is able to change metadata also)
  • copy files or folders inside a container
  • tag an image

Builds in current state suffer from multiple issues which docker is not planning to address any time soon: having secrets during build time which won’t leak to final image, controlling number of layers in final image, precisely specifying metadata of a final image and more.

Target of this thesis is to research and implement a solution, which uses engine API endpoints mentioned above (/commit, /containers/(id or name)/archive, /containers/(id or name)/exec). The tool should be able to:

  • Build an image from provided dockerfile.
  • Mount a directory inside container during build with arbitrary data (e.g. private ssh keys) which won't be present in final image.
  • Precisely control layering of the final image.
  • Enable to add arbitrary metadata to the image
  • The tool should be written in Python programming language and should support both version 2 and version 3.
Práce zkontrolována:
30. 5. 2017 09:45, Mgr. Marek Grác, Ph.D., učo 50728
Jazyk práce
angličtina angličtina
Termín obhajoby
30. 6. 2017
Práce byla úspěšně obhájena

Vedoucí

Mgr. Marek Grác, Ph.D., učo 50728
ÚČJ FF MU

Oponent

RNDr. Pavel Šmerk, Ph.D., učo 3880
CVT FI MU

Konzultant

Mgr. Tomáš Tomeček
abs FI MU

  • Přidání souboru

    Soubor nebo složku lze nahrát pomocí tlačítka Přidat.
  • Další operace se soubory

    Podrobnosti lze zjistit označením příslušného řádku.
  • Pohled pro experty

    Pro častou práci je možné zvolit režim Více možností.
  • Vyhledávání souborů

    Vyhledávaný výraz můžete zadat přímo do adresního řádku.
  • Rychlý přístup k souborům

    Pomocí funkce Nedávné je možné se rychle vrátit k právě prohlíženým souborům. Oblíbené soubory je také možné označit Hvězdičkou.