Unverified Commit d69eadeb authored by fleaz's avatar fleaz
Browse files

nixos/r53-ddns: Add new option for record ttl

parent cf478129
Loading
Loading
Loading
Loading
+7 −1
Original line number Diff line number Diff line
@@ -41,6 +41,11 @@ in
        '';
      };

      ttl = mkOption {
        type = types.int;
        description = "The TTL for the generated record";
      };

      environmentFile = mkOption {
        type = types.str;
        description = ''
@@ -68,7 +73,8 @@ in
      serviceConfig = {
        ExecStart =
          "${pkg}/bin/r53-ddns -zone-id ${cfg.zoneID} -domain ${cfg.domain}"
          + lib.optionalString (cfg.hostname != null) " -hostname ${cfg.hostname}";
          + lib.optionalString (cfg.hostname != null) " -hostname ${cfg.hostname}"
          + lib.optionalString (cfg.ttl != null) " -ttl ${toString cfg.ttl}";
        EnvironmentFile = "${cfg.environmentFile}";
        DynamicUser = true;
      };