nixos/ceph: add options to configure package used by each component
This makes updates following the upstream guide possible.
This commit is contained in:
parent
e1fedfdf45
commit
d64e1f0b40
1 changed files with 6 additions and 2 deletions
|
@ -11,7 +11,7 @@ let
|
||||||
|
|
||||||
makeServices = daemonType: daemonIds:
|
makeServices = daemonType: daemonIds:
|
||||||
mkMerge (map (daemonId:
|
mkMerge (map (daemonId:
|
||||||
{ "ceph-${daemonType}-${daemonId}" = makeService daemonType daemonId cfg.global.clusterName pkgs.ceph; })
|
{ "ceph-${daemonType}-${daemonId}" = makeService daemonType daemonId cfg.global.clusterName cfg.${daemonType}.package; })
|
||||||
daemonIds);
|
daemonIds);
|
||||||
|
|
||||||
makeService = daemonType: daemonId: clusterName: ceph:
|
makeService = daemonType: daemonId: clusterName: ceph:
|
||||||
|
@ -210,6 +210,7 @@ in
|
||||||
to the id part in ceph i.e. [ "name1" ] would result in mgr.name1
|
to the id part in ceph i.e. [ "name1" ] would result in mgr.name1
|
||||||
'';
|
'';
|
||||||
};
|
};
|
||||||
|
package = mkPackageOptionMD pkgs "ceph" { };
|
||||||
extraConfig = mkOption {
|
extraConfig = mkOption {
|
||||||
type = with types; attrsOf str;
|
type = with types; attrsOf str;
|
||||||
default = {};
|
default = {};
|
||||||
|
@ -230,6 +231,7 @@ in
|
||||||
to the id part in ceph i.e. [ "name1" ] would result in mon.name1
|
to the id part in ceph i.e. [ "name1" ] would result in mon.name1
|
||||||
'';
|
'';
|
||||||
};
|
};
|
||||||
|
package = mkPackageOptionMD pkgs "ceph" { };
|
||||||
extraConfig = mkOption {
|
extraConfig = mkOption {
|
||||||
type = with types; attrsOf str;
|
type = with types; attrsOf str;
|
||||||
default = {};
|
default = {};
|
||||||
|
@ -250,7 +252,7 @@ in
|
||||||
to the id part in ceph i.e. [ "name1" ] would result in osd.name1
|
to the id part in ceph i.e. [ "name1" ] would result in osd.name1
|
||||||
'';
|
'';
|
||||||
};
|
};
|
||||||
|
package = mkPackageOptionMD pkgs "ceph" { };
|
||||||
extraConfig = mkOption {
|
extraConfig = mkOption {
|
||||||
type = with types; attrsOf str;
|
type = with types; attrsOf str;
|
||||||
default = {
|
default = {
|
||||||
|
@ -278,6 +280,7 @@ in
|
||||||
to the id part in ceph i.e. [ "name1" ] would result in mds.name1
|
to the id part in ceph i.e. [ "name1" ] would result in mds.name1
|
||||||
'';
|
'';
|
||||||
};
|
};
|
||||||
|
package = mkPackageOptionMD pkgs "ceph" { };
|
||||||
extraConfig = mkOption {
|
extraConfig = mkOption {
|
||||||
type = with types; attrsOf str;
|
type = with types; attrsOf str;
|
||||||
default = {};
|
default = {};
|
||||||
|
@ -289,6 +292,7 @@ in
|
||||||
|
|
||||||
rgw = {
|
rgw = {
|
||||||
enable = mkEnableOption (lib.mdDoc "Ceph RadosGW daemon");
|
enable = mkEnableOption (lib.mdDoc "Ceph RadosGW daemon");
|
||||||
|
package = mkPackageOptionMD pkgs "ceph" { };
|
||||||
daemons = mkOption {
|
daemons = mkOption {
|
||||||
type = with types; listOf str;
|
type = with types; listOf str;
|
||||||
default = [];
|
default = [];
|
||||||
|
|
Loading…
Reference in a new issue