Skip to content
This repository has been archived by the owner on May 6, 2020. It is now read-only.
James O. D. Hunt edited this page Dec 15, 2017 · 12 revisions

If you are new to Clear Containers, try working through the following tasks. They should help you to become familiar with the system.

Preliminaries

🚼 Basics

Create a Clear Container

  1. Install Clear Containers.
  2. Check that Clear Containers has installed, and is available in docker (hint: docker info).
  3. Create a Clear Container (hint: docker run as normal! :)
  4. Prove that you are running a Clear Container (hints: uname -r and ps aux | grep qemu).

Environment

  1. Run sudo cc-runtime cc-check and seeing if you understand all the output

    (see https://github.com/clearcontainers/runtime#hardware-requirements).

  2. Run sudo cc-runtime cc-env and seeing if you understand all the output

    (see https://github.com/clearcontainers/runtime#configuration).

🚴‍♂️ Intermediate

  1. Enable debugging.
  2. Find a way to force an error (hint: Try adding spurious data into the config file).
  3. Ensure you get a useful error message returned to you.
  4. See if you can find evidence of the error you forced [in the logs] (https://github.com/clearcontainers/runtime#logging).

🏎️ Advanced

ℹ️ Note:

This section assumes you have read the architecture document.

Clear Containers uses a small root filesystem (rootfs) image (which can be based on any Linux distro) and a guest kernel image to boot the virtual machine. If you wish, you can generate your own custom rootfs and / or custom kernel. This exercise gets you to create a custom rootfs image and boot a Clear Container using it.

  1. Create a new rootfs image using osbuilder.
  2. Read the osbuilder docs to establish how to modify your runtime configuration to use the new rootfs image.
  3. Start a Clear Container using your new rootfs image.
  4. Find a way to prove that you are using your new image.

If you come across any issues or you have thoughts on how we can improve the system, please raise an issue so we can help! 😄