From a0a9cb51e35e915dbcc1d7bda430f45c4353c8ff Mon Sep 17 00:00:00 2001 From: seth Date: Sat, 27 Apr 2024 04:40:29 +0000 Subject: better compose overlay + add aarch64 support (#53) * better compose overlay + add aarch64 support * ci: update workflows --- container.nix | 30 ++++++++++++++++++++++++++++++ 1 file changed, 30 insertions(+) create mode 100644 container.nix (limited to 'container.nix') diff --git a/container.nix b/container.nix new file mode 100644 index 0000000..3d25586 --- /dev/null +++ b/container.nix @@ -0,0 +1,30 @@ +{ + lib, + buildEnv, + dockerTools, + runCommand, + bashInteractive, + workerd, +}: +dockerTools.buildLayeredImage { + name = workerd.pname; + tag = "latest"; + + contents = [ + (buildEnv { + name = "image-root"; + paths = [ + (runCommand "bin-sh" {} '' + mkdir -p $out/bin + ln -s ${lib.getExe bashInteractive} $out/bin/sh + '') + workerd + ]; + pathsToLink = ["/bin" "/etc"]; + }) + dockerTools.caCertificates + ]; + + config.Cmd = [(lib.getExe workerd)]; + architecture = workerd.stdenv.hostPlatform.ubootArch; +} -- cgit v1.2.3