diff --git a/src/haskell/testdata/Arion/NixSpec/arion-compose.json b/src/haskell/testdata/Arion/NixSpec/arion-compose.json index 5f644ac..64b8169 100644 --- a/src/haskell/testdata/Arion/NixSpec/arion-compose.json +++ b/src/haskell/testdata/Arion/NixSpec/arion-compose.json @@ -33,6 +33,7 @@ } }, "version": "3.4", + "volumes": {}, "x-arion": { "images": [ { diff --git a/src/nix/modules/composition/docker-compose.nix b/src/nix/modules/composition/docker-compose.nix index a74c958..8ff3f62 100644 --- a/src/nix/modules/composition/docker-compose.nix +++ b/src/nix/modules/composition/docker-compose.nix @@ -63,6 +63,11 @@ in type = lib.types.attrsOf (lib.types.submodule service); description = "An attribute set of service configurations. A service specifies how to run an image as a container."; }; + docker-compose.volumes = lib.mkOption { + type = lib.types.attrsOf lib.types.unspecified; + description = "A attribute set of volume configurations."; + default = {}; + }; }; config = { out.dockerComposeYaml = pkgs.writeText "docker-compose.yaml" config.out.dockerComposeYamlText; @@ -73,6 +78,7 @@ in version = "3.4"; services = lib.mapAttrs (k: c: c.out.service) config.services; x-arion = config.docker-compose.extended; + volumes = config.docker-compose.volumes; }; }; }