forked from yu-re-ka/binary-cache
feat(module): expose common-composition to the user
This commit is contained in:
parent
9dcfcbf178
commit
608f8008eb
|
@ -41,6 +41,7 @@ in
|
|||
options = {
|
||||
grpcListenAddress = lib.mkOption { type = lib.types.str; };
|
||||
narBridgeListenAddress = lib.mkOption { type = lib.types.str; };
|
||||
common-composition = lib.mkOption { inherit (settingsFormat) type; };
|
||||
nar-bridge-composition = lib.mkOption { inherit (settingsFormat) type; };
|
||||
tvix-daemon-composition = lib.mkOption { inherit (settingsFormat) type; };
|
||||
name = lib.mkOption {
|
||||
|
@ -57,8 +58,7 @@ in
|
|||
};
|
||||
};
|
||||
|
||||
config =
|
||||
let
|
||||
config = {
|
||||
common-composition = {
|
||||
blobservices.default = {
|
||||
type = "objectstore";
|
||||
|
@ -86,9 +86,9 @@ in
|
|||
};
|
||||
};
|
||||
};
|
||||
in
|
||||
nar-bridge-composition = lib.mkMerge [
|
||||
cacheAttrs.config.common-composition
|
||||
{
|
||||
nar-bridge-composition = lib.recursiveUpdate common-composition {
|
||||
pathinfoservices.default = {
|
||||
type = "grpc";
|
||||
url = "grpc+http://${
|
||||
|
@ -104,14 +104,18 @@ in
|
|||
cacheAttrs.config.grpcListenAddress
|
||||
}";
|
||||
};
|
||||
};
|
||||
tvix-daemon-composition = lib.recursiveUpdate common-composition {
|
||||
}
|
||||
];
|
||||
tvix-daemon-composition = lib.mkMerge [
|
||||
cacheAttrs.config.common-composition
|
||||
{
|
||||
pathinfoservices.default = {
|
||||
type = "sled";
|
||||
is_temporary = false;
|
||||
path = "/var/lib/tvix-daemon-${name}/pathinfos.sled";
|
||||
};
|
||||
};
|
||||
}
|
||||
];
|
||||
};
|
||||
}
|
||||
)
|
||||
|
|
Loading…
Reference in a new issue