|
| 1 | +# ----------------------------------------------------------------------------- |
| 2 | +## |
| 3 | +# Default configuration for backup & restore related commands |
| 4 | +# |
| 5 | +# This file should contain useful defaults to reduce amount of configuration |
| 6 | +# work needed in derived profiles. It should NOT contain a full backup config |
| 7 | +# having "source" definitions, since these whould be inherited by all backup |
| 8 | +# profiles that derive from "base" (or "default") settings. |
| 9 | +# |
| 10 | +# To define backup sources, create a profile config in "profiles.d" like: |
| 11 | +# |
| 12 | +# >>> "profiles.d/example.conf" |
| 13 | +# |
| 14 | +# [profiles.example] |
| 15 | +# description = "Backup example" |
| 16 | +# inherit = "base" |
| 17 | +# |
| 18 | +# [profiles.example.backup] |
| 19 | +# schedule = "daily" |
| 20 | +# source = [ |
| 21 | +# "/path/to/backup", |
| 22 | +# "/other/path/to/backup", |
| 23 | +# ] |
| 24 | +# |
| 25 | +# <<< |
| 26 | +# |
| 27 | + |
| 28 | + |
| 29 | +## |
| 30 | +# Backup defaults |
| 31 | +[profiles.default.backup] |
| 32 | + |
| 33 | +# Hostname and tags to identify backup snapshots in the repository |
| 34 | +{{ template "conf:default-host" . }} |
| 35 | +{{ template "conf:default-tags" . }} |
| 36 | + |
| 37 | +# Exclude known cache files & folders from backups |
| 38 | +exclude-caches = true |
| 39 | + |
| 40 | +# Exclude nested filesystems |
| 41 | +# Prefer overriding this option in dedicated backup profiles instead of |
| 42 | +# globally as it can greatly increase the volume if nested FS mounts are |
| 43 | +# contained in backup source paths. |
| 44 | +one-file-system = true |
| 45 | + |
| 46 | +# Toggle whether a failure in reading a backup source is considered an error |
| 47 | +no-error-on-warning = false |
| 48 | + |
| 49 | +# Wait on acquiring locks when running the profile on a schedule |
| 50 | +schedule-lock-wait = "45m" |
| 51 | + |
| 52 | +# Specify the user that runs profile tasks on a schedule |
| 53 | +# "system" - root runs the profile tasks |
| 54 | +# "user" - user that created the schedule runs the profile tasks |
| 55 | +schedule-permission = "system" |
| 56 | + |
| 57 | +# Toggle verbose output for troubleshooting |
| 58 | +#verbose = false |
| 59 | + |
| 60 | +# Toggles immediate repository check before and after backup. |
| 61 | +# Checks can be heavy on resources. Consider scheduling "maintenance" |
| 62 | +# (see "conf.d/check.conf") instead of enabling checks here. |
| 63 | +check-before = false |
| 64 | +check-after = false |
| 65 | + |
| 66 | + |
| 67 | +## |
| 68 | +# Snapshot retention defaults |
| 69 | +[profiles.default.retention] |
| 70 | +# Remove obsolete snapshots prior to starting a backup |
| 71 | +before-backup = false |
| 72 | +# Remove obsolete snapshots after a successful backup |
| 73 | +after-backup = true |
| 74 | + |
| 75 | +# |
| 76 | +# Note: Retention operates on host, path and tag filters to identify snapshots |
| 77 | +# to retain or remove. In most cases these filters should be in sync with |
| 78 | +# the backup configuration of a profile so that snapshots will be removed |
| 79 | +# that truely belong to a profile's backup. |
| 80 | +# |
| 81 | + |
| 82 | +# Copying "host" block to identify snapshots by hostname |
| 83 | +{{ template "conf:default-host" . }} |
| 84 | + |
| 85 | +# Retention allows to build tag filter from backup with 'true'. It is strongly |
| 86 | +# advised not to change this as tags are the primary filter besides hostname. |
| 87 | +tag = true |
| 88 | + |
| 89 | +# Copying backup source paths to identify snapshots to retain or remove. |
| 90 | +# Set to "false" or a list of paths to disable or customize the path filter. |
| 91 | +# |
| 92 | +# It may make sense to disable path filters when source paths change. Ensure |
| 93 | +# that tags and hostname can properly identify snapshots when disabling paths. |
| 94 | +path = true |
| 95 | + |
| 96 | +# Specify the snapshots to keep when checking for obsolete snapshots |
| 97 | +# Snapshots that do not match any condition are removed |
| 98 | +keep-tag = [ "forever" ] |
| 99 | +keep-last = 3 |
| 100 | +#keep-hourly = 1 |
| 101 | +#keep-daily = 1 |
| 102 | +#keep-weekly = 1 |
| 103 | +#keep-monthly = 1 |
| 104 | +#keep-yearly = 1 |
| 105 | +#keep-within = "30d" |
| 106 | + |
| 107 | +# Use compact format for listing snapshots |
| 108 | +#compact = false |
| 109 | + |
| 110 | +# Toggles immediate prune of the repository as snapshots are removed. |
| 111 | +# |
| 112 | +# While removing snapshots is a light operation, prune (reclaim space) can |
| 113 | +# be heavy on resources as it rewrites parts of the repository. |
| 114 | +# Consider scheduling "maintenance" (see "conf.d/prune.conf") instead of |
| 115 | +# enabling prune here. |
| 116 | +# |
| 117 | +# Also an attempt to recover a removed snapshot with "resticprofile recover" |
| 118 | +# only works as long as the repository was not yet pruned. |
| 119 | +prune = false |
| 120 | + |
| 121 | + |
| 122 | +## |
| 123 | +# Defaults for operations on repository snapshots of this host |
| 124 | +# Usage: |
| 125 | +# - "resticprofile snapshots" - view snapshots |
| 126 | +# - "resticprofile mount /mnt/restore" - mount snapshots |
| 127 | +# - "resticprofile ls latest /" - list files in a snapshot |
| 128 | +# - "resticprofile dump latest /file" - dump a file to stdout |
| 129 | +# - "resticprofile find PATTERN..." - find files in snapshots |
| 130 | +# - "resticprofile copy --repo2=..." - copy snapshots to repo2 |
| 131 | +# - "resticprofile restore --target=/to/dir --include=PATTERN... latest" |
| 132 | +[profiles.default.copy] |
| 133 | +{{ template "conf:default-host" . }} |
| 134 | +schedule-lock-wait = "1h30m" |
| 135 | +[profiles.default.dump] |
| 136 | +{{ template "conf:default-host" . }} |
| 137 | +[profiles.default.find] |
| 138 | +{{ template "conf:default-host" . }} |
| 139 | +[profiles.default.forget] |
| 140 | +{{ template "conf:default-host" . }} |
| 141 | +[profiles.default.ls] |
| 142 | +{{ template "conf:default-host" . }} |
| 143 | +[profiles.default.mount] |
| 144 | +{{ template "conf:default-host" . }} |
| 145 | +[profiles.default.restore] |
| 146 | +{{ template "conf:default-host" . }} |
| 147 | +[profiles.default.snapshots] |
| 148 | +{{ template "conf:default-host" . }} |
| 149 | +[profiles.default.stats] |
| 150 | +{{ template "conf:default-host" . }} |
| 151 | +[profiles.default.tag] |
| 152 | +{{ template "conf:default-host" . }} |
| 153 | + |
| 154 | + |
| 155 | +## |
| 156 | +# Setup operations on repository snapshots for profiles deriving from "base" |
| 157 | +# Usage: |
| 158 | +# - "resticprofile profileName.snapshots" - view snapshots |
| 159 | +# - "resticprofile profileName.mount /mnt/restore" - mount snapshots |
| 160 | +# - "resticprofile profileName.ls latest /" - list files in a snapshot |
| 161 | +# - "resticprofile profileName.dump latest /file" - dump a file to stdout |
| 162 | +# - "resticprofile profileName.find PATTERN..." - find files in snapshots |
| 163 | +# - "resticprofile profileName.copy --repo2=..." - copy snapshots to repo2 |
| 164 | +# - "resticprofile profileName.restore --target=/to/dir latest" |
| 165 | +[profiles.base.copy] |
| 166 | +{{ template "conf:default-tags" . }} |
| 167 | +[profiles.base.dump] |
| 168 | +{{ template "conf:default-tags" . }} |
| 169 | +[profiles.base.find] |
| 170 | +{{ template "conf:default-tags" . }} |
| 171 | +[profiles.base.forget] |
| 172 | +{{ template "conf:default-tags" . }} |
| 173 | +[profiles.base.ls] |
| 174 | +{{ template "conf:default-tags" . }} |
| 175 | +[profiles.base.mount] |
| 176 | +{{ template "conf:default-tags" . }} |
| 177 | +[profiles.base.restore] |
| 178 | +{{ template "conf:default-tags" . }} |
| 179 | +[profiles.base.snapshots] |
| 180 | +{{ template "conf:default-tags" . }} |
| 181 | +[profiles.base.stats] |
| 182 | +{{ template "conf:default-tags" . }} |
| 183 | +[profiles.base.tag] |
| 184 | +{{ template "conf:default-tags" . }} |
| 185 | + |
| 186 | + |
| 187 | +# ----------------------------------------------------------------------------- |
0 commit comments