From 2d079e4f416aee2457536a997b89781a40736b44 Mon Sep 17 00:00:00 2001 From: Serhii Khoma Date: Mon, 16 Sep 2019 20:35:39 +0300 Subject: [PATCH] feat: docker-compose fields -> container_name -> add --- src/nix/modules/service/docker-compose-service.nix | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/src/nix/modules/service/docker-compose-service.nix b/src/nix/modules/service/docker-compose-service.nix index 54dae9f..5bde3ad 100644 --- a/src/nix/modules/service/docker-compose-service.nix +++ b/src/nix/modules/service/docker-compose-service.nix @@ -90,6 +90,11 @@ in default = null; description = dockerComposeRef "command"; }; + service.container_name = mkOption { + type = nullOr types.str; + default = null; + description = dockerComposeRef "container_name"; + }; service.depends_on = mkOption { type = listOf str; default = []; @@ -214,6 +219,8 @@ in inherit cap_drop; } // lib.optionalAttrs (config.service.command != null) { inherit (config.service) command; + } // lib.optionalAttrs (config.service.container_name != null) { + inherit (config.service) container_name; } // lib.optionalAttrs (config.service.depends_on != []) { inherit (config.service) depends_on; } // lib.optionalAttrs (config.service.devices != []) {