mirror of
https://codeberg.org/demostf/backup.git
synced 2026-06-03 18:04:08 +02:00
option naming
This commit is contained in:
parent
ee112f0685
commit
9b4bbe925b
1 changed files with 4 additions and 4 deletions
|
|
@ -36,7 +36,7 @@ in {
|
||||||
default = "*:0/10";
|
default = "*:0/10";
|
||||||
description = "Interval to run the service";
|
description = "Interval to run the service";
|
||||||
};
|
};
|
||||||
keyFile = mkOption {
|
accessKeyFile = mkOption {
|
||||||
type = types.nullOr types.str;
|
type = types.nullOr types.str;
|
||||||
description = "access key file path";
|
description = "access key file path";
|
||||||
};
|
};
|
||||||
|
|
@ -59,15 +59,15 @@ in {
|
||||||
STATE_FILE = cfg.stateFile;
|
STATE_FILE = cfg.stateFile;
|
||||||
RUST_LOG = cfg.logLevel;
|
RUST_LOG = cfg.logLevel;
|
||||||
}
|
}
|
||||||
// optionalAttrs (cfg.keyFile != null) {
|
// optionalAttrs (cfg.accessKeyFile != null) {
|
||||||
ACCESS_KEY_FILE = "$CREDENTIALS_DIRECTORY/api_key";
|
ACCESS_KEY_FILE = "$CREDENTIALS_DIRECTORY/api_key";
|
||||||
};
|
};
|
||||||
|
|
||||||
serviceConfig = {
|
serviceConfig = {
|
||||||
ExecStart = "${cfg.package}/bin/demostf-backup";
|
ExecStart = "${cfg.package}/bin/demostf-backup";
|
||||||
|
|
||||||
LoadCredential = optionals (cfg.keyFile != null) [
|
LoadCredential = optionals (cfg.accessKeyFile != null) [
|
||||||
"api_key:${cfg.keyFile}"
|
"api_key:${cfg.accessKeyFile}"
|
||||||
];
|
];
|
||||||
|
|
||||||
ReadWritePaths = [cfg.target cfg.stateFile];
|
ReadWritePaths = [cfg.target cfg.stateFile];
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue