diff options
author | stuebinm | 2021-05-31 16:20:55 +0200 |
---|---|---|
committer | stuebinm | 2021-05-31 16:20:55 +0200 |
commit | 90dc63cc998becf832a7aed446a6b68ecbcf3906 (patch) | |
tree | da8988cca979de08d669c72f50d33df8f52f74bf /nix-modules | |
parent | 818f7a68df4ca0221107b2d07eb502b16fa6d653 (diff) |
nixos-modules oci container: keep to the spec
turns out you can break the image spec in subtle ways and instead of
telling anyone about it, docker will just guess what was meant and do
whatever.
podman won't, and actually keeps to the spec.
it should work with both now ...
Diffstat (limited to '')
-rw-r--r-- | nix-modules/docker-nixos-modules.nix | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/nix-modules/docker-nixos-modules.nix b/nix-modules/docker-nixos-modules.nix index d14144d..4f7c93d 100644 --- a/nix-modules/docker-nixos-modules.nix +++ b/nix-modules/docker-nixos-modules.nix @@ -68,7 +68,7 @@ in pkgs.dockerTools.buildImage { # Note that many features of the systemd.services config # are just ignored (e.g. no auto-restarts yet) config = with pkgs.lib; with pkgs.lib.strings; dockerConfig // { - Cmd = pkgs.writeScript "main-entrypoint" + Cmd = [ (pkgs.writeScript "main-entrypoint" ("#!${pkgs.dash.outPath}/bin/dash\n" + concatStrings (map (command: "${command}&\n") (mapAttrsToList @@ -103,6 +103,6 @@ in pkgs.dockerTools.buildImage { then service.script else service.serviceConfig.ExecStart} '').outPath) - config.config.systemd.services)) + "\n wait"); + config.config.systemd.services)) + "\n wait")) ]; }; } |