all messages for Guix-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Antoine Eiche <lewo@abesis.fr>
To: Ricardo Wurmus <rekado@elephly.net>
Cc: guix-devel@gnu.org
Subject: Re: Building container images with nix2container
Date: Mon, 26 Feb 2024 11:09:21 +0100	[thread overview]
Message-ID: <87plwjilke.fsf@tilia> (raw)
In-Reply-To: <87wmqszwif.fsf@elephly.net>

Ricardo Wurmus <rekado@elephly.net> writes:

> We have "guix pack" as part of Guix.  It builds Docker or squashfs
> images as well as various other formats.  What does nix2container offer
> beyond what we have?

I acutally don't know how you currently build Docker images. But if
nix2container brings something, i think it would mainly be
optimizations (time and space).

Does your built images contains several layers?

nix2container uses an heuristic to group store paths into layers. The
goal is to share common layers between images and to avoid full image
rebuild when only a storepath differs.

Do you write the image tarball into your store when you build an image?

nix2container is able to build layers on the fly from the Nix store. The
goal is to reduce IOs and storage. Instead of writing an image tarball
into the store, it generates a script which stream layers from store
paths to the destination (a Docker registry, the Docker deamon, Podman
or a file).

nix2container also has more advanced features allowing to control the
layers that are rebuilt. For instance, if you work on a Python
application, nix2container would allow to isolate your application and
the Python libraries into dedicated layers. When you change something in
your application, the layers containing the Python libraries won't have
to be rebuilt and pushed to a registry.

lewo.


  reply	other threads:[~2024-02-26 10:10 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-02-24  9:27 Building container images with nix2container Antoine Eiche
2024-02-25 10:07 ` Ricardo Wurmus
2024-02-26 10:09   ` Antoine Eiche [this message]
2024-02-26 10:24     ` Ricardo Wurmus
2024-02-26 17:33     ` Simon Tournier
2024-03-08 10:31       ` Simon Tournier
2024-03-17 17:32         ` Antoine Eiche
2024-03-17 17:09       ` Antoine Eiche

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=87plwjilke.fsf@tilia \
    --to=lewo@abesis.fr \
    --cc=guix-devel@gnu.org \
    --cc=rekado@elephly.net \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/guix.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.