stuff
This commit is contained in:
parent
3887e64f58
commit
25ee658d02
1 changed files with 17 additions and 14 deletions
|
@ -43,13 +43,10 @@ in
|
||||||
type = types.bool;
|
type = types.bool;
|
||||||
};
|
};
|
||||||
|
|
||||||
storage = lib.mkOption {
|
stateDir = lib.mkOption {
|
||||||
default = "${cfg.settings.root}/data";
|
default = "/var/lib/filebrowser";
|
||||||
defaultText = lib.literalExpression ''
|
|
||||||
"''${config.services.filebrowser.settings.root}/data"
|
|
||||||
'';
|
|
||||||
description = ''
|
description = ''
|
||||||
The directory where FileBrowser stores files.
|
The directory where FileBrowser stores its state.
|
||||||
'';
|
'';
|
||||||
type = types.path;
|
type = types.path;
|
||||||
};
|
};
|
||||||
|
@ -80,26 +77,32 @@ in
|
||||||
};
|
};
|
||||||
|
|
||||||
root = lib.mkOption {
|
root = lib.mkOption {
|
||||||
default = "/var/lib/filebrowser";
|
default = "${cfg.stateDir}/data";
|
||||||
|
defaultText = lib.literalExpression ''
|
||||||
|
"''${config.services.filebrowser.stateDir}/data"
|
||||||
|
'';
|
||||||
description = ''
|
description = ''
|
||||||
The directory where FileBrowser stores its state.
|
The directory where FileBrowser stores files.
|
||||||
'';
|
'';
|
||||||
type = types.path;
|
type = types.path;
|
||||||
};
|
};
|
||||||
|
|
||||||
database = lib.mkOption {
|
database = lib.mkOption {
|
||||||
default = "${cfg.settings.root}/database.db";
|
default = "/var/lib//database.db";
|
||||||
defaultText = lib.literalExpression ''
|
defaultText = lib.literalExpression ''
|
||||||
"''${config.services.filebrowser.settings.root}/database.db"
|
"''${config.services.filebrowser.stateDir}/database.db"
|
||||||
'';
|
'';
|
||||||
description = ''
|
description = ''
|
||||||
The path to FileBrowser's database.
|
The path to FileBrowser's Bolt database.
|
||||||
'';
|
'';
|
||||||
type = types.path;
|
type = types.path;
|
||||||
};
|
};
|
||||||
|
|
||||||
cache-dir = lib.mkOption {
|
cache-dir = lib.mkOption {
|
||||||
default = null;
|
default = "${cfg.stateDir}/cache";
|
||||||
|
defaultText = lib.literalExpression ''
|
||||||
|
"''${config.services.filebrowser.stateDir}/cache"
|
||||||
|
'';
|
||||||
description = ''
|
description = ''
|
||||||
The directory where FileBrowser stores its cache.
|
The directory where FileBrowser stores its cache.
|
||||||
'';
|
'';
|
||||||
|
@ -128,8 +131,8 @@ in
|
||||||
in
|
in
|
||||||
utils.escapeSystemdExecArgs args;
|
utils.escapeSystemdExecArgs args;
|
||||||
|
|
||||||
StateDirectory = cfg.settings.root;
|
StateDirectory = cfg.stateDir;
|
||||||
WorkingDirectory = cfg.storage;
|
WorkingDirectory = cfg.settings.root;
|
||||||
|
|
||||||
User = cfg.user;
|
User = cfg.user;
|
||||||
Group = cfg.group;
|
Group = cfg.group;
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue