nixos/memcached: Type all options

This commit is contained in:
Janne Heß 2019-12-29 23:56:11 +01:00 committed by Jörg Thalheim
parent d00e5e84cc
commit 55127e16af
No known key found for this signature in database
GPG key ID: 003F2096411B5F92

View file

@ -17,39 +17,44 @@ in
options = { options = {
services.memcached = { services.memcached = {
enable = mkEnableOption "Memcached"; enable = mkEnableOption "Memcached";
user = mkOption { user = mkOption {
type = types.str;
default = "memcached"; default = "memcached";
description = "The user to run Memcached as"; description = "The user to run Memcached as";
}; };
listen = mkOption { listen = mkOption {
type = types.str;
default = "127.0.0.1"; default = "127.0.0.1";
description = "The IP address to bind to"; description = "The IP address to bind to.";
}; };
port = mkOption { port = mkOption {
type = types.port;
default = 11211; default = 11211;
description = "The port to bind to"; description = "The port to bind to.";
}; };
enableUnixSocket = mkEnableOption "unix socket at /run/memcached/memcached.sock"; enableUnixSocket = mkEnableOption "unix socket at /run/memcached/memcached.sock";
maxMemory = mkOption { maxMemory = mkOption {
type = types.ints.unsigned;
default = 64; default = 64;
description = "The maximum amount of memory to use for storage, in megabytes."; description = "The maximum amount of memory to use for storage, in megabytes.";
}; };
maxConnections = mkOption { maxConnections = mkOption {
type = types.ints.unsigned;
default = 1024; default = 1024;
description = "The maximum number of simultaneous connections"; description = "The maximum number of simultaneous connections.";
}; };
extraOptions = mkOption { extraOptions = mkOption {
type = types.listOf types.str;
default = []; default = [];
description = "A list of extra options that will be added as a suffix when running memcached"; description = "A list of extra options that will be added as a suffix when running memcached.";
}; };
}; };