mirror of
https://codeberg.org/privacy1st/nix-git
synced 2024-12-23 02:36:05 +01:00
btrbk: option to disable timer
This commit is contained in:
parent
13b7c922e7
commit
f423383ca2
@ -26,6 +26,7 @@ in
|
||||
yoda.btrbkBackups = [
|
||||
{
|
||||
instance = "remote-backup-ssd";
|
||||
enable = false;
|
||||
lz4 = false;
|
||||
ssh_identity = "/mnt/backup/rootNas_ed25519";
|
||||
volume = "ssh://rootnas/jc-data";
|
||||
@ -35,6 +36,7 @@ in
|
||||
}
|
||||
{
|
||||
instance = "remote-backup-hdd";
|
||||
enable = false;
|
||||
lz4 = false;
|
||||
ssh_identity = "/mnt/backup/rootNas_ed25519";
|
||||
volume = "ssh://rootnas/mnt/data/jc-data";
|
||||
|
@ -13,12 +13,15 @@ in
|
||||
type = types.listOf types.attrs;
|
||||
default = [];
|
||||
example = [{
|
||||
instance = "local-backup-ssd";
|
||||
# Optional.
|
||||
# Can be used to disable timer.
|
||||
#enable = false;
|
||||
# Optional.
|
||||
# If this is `true` and `volume` starts with `ssh://`, `lz4` transport compression is enabled.
|
||||
lz4 = true;
|
||||
# Optional.
|
||||
#ssh_identity = /root/.ssh/rootNas_ed25519;
|
||||
instance = "local-backup-ssd";
|
||||
volume = "/jc-data";
|
||||
snapshot_dir = "/snap";
|
||||
target = "/mnt/backup/snap";
|
||||
@ -47,8 +50,7 @@ in
|
||||
# `services.btrbk.instances` template.
|
||||
{
|
||||
"${x.instance}" = {
|
||||
#onCalendar = null;
|
||||
onCalendar = "00:05";
|
||||
onCalendar = if (x.enable or true) then "00:05" else null;
|
||||
settings = {
|
||||
timestamp_format = "long";
|
||||
stream_compress = mkIf ((x.lz4 or false) && strings.hasPrefix "ssh://" x.volume) "lz4";
|
||||
|
@ -14,6 +14,9 @@ in
|
||||
default = [];
|
||||
example = [{
|
||||
instance = "local-snapshot-ssd";
|
||||
# Optional.
|
||||
# Can be used to disable timer.
|
||||
#enable = false;
|
||||
volume = "/jc-data";
|
||||
snapshot_dir = "/snap";
|
||||
subvolume = {
|
||||
@ -41,8 +44,7 @@ in
|
||||
# `services.btrbk.instances` template.
|
||||
{
|
||||
"${x.instance}" = {
|
||||
#onCalendar = null;
|
||||
onCalendar = "hourly";
|
||||
onCalendar = if (x.enable or true) then "hourly" else null;
|
||||
settings = {
|
||||
timestamp_format = "long";
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user