From 18dc96269d01f7fa1e2e61086444a89f5ce18890 Mon Sep 17 00:00:00 2001 From: Pol Dellaiera Date: Sun, 15 Jun 2025 22:58:26 +0200 Subject: [PATCH] docker: add basics OpenContainers labels --- docker.nix | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/docker.nix b/docker.nix index 14648f0d1..74e970e4b 100644 --- a/docker.nix +++ b/docker.nix @@ -19,6 +19,13 @@ gid ? 0, uname ? "root", gname ? "root", + Labels ? { + "org.opencontainers.image.title" = "Nix"; + "org.opencontainers.image.source" = "https://github.com/NixOS/nix"; + "org.opencontainers.image.vendor" = "Nix project"; + "org.opencontainers.image.version" = nix.version; + "org.opencontainers.image.description" = "Nix container image"; + }, # Default Packages nix, bashInteractive, @@ -352,6 +359,7 @@ dockerTools.buildLayeredImageWithNixDb { ''; config = { + inherit Labels; Cmd = [ (lib.getExe bashInteractive) ]; User = "${toString uid}:${toString gid}"; Env = [