This commit is contained in:
Michael Jerger 2024-08-20 07:55:54 +02:00
parent 26822dd8fd
commit 4df437f707
3 changed files with 29 additions and 7 deletions

View file

@ -9,8 +9,16 @@
[dda.backup.infrastructure :as i]))
(s/def ::config
(s/keys :req-un [::domain/files ::cd/restic-repository ::cd/backup-path]
:opt-un [::cd/certificate-file ::cd/directory ::cd/debug ::cd/dry-run]))
(s/keys :req-un [::domain/files
::cd/restic-repository
::cd/backup-path]
:opt-un [::cd/certificate-file
::cd/password-file
::cd/days-to-keep
::cd/months-to-keep
::cd/directory
::cd/dry-run
::cd/debug]))
(defn-spec backup! nil?
[config ::config]

View file

@ -8,9 +8,15 @@
[dda.backup.infrastructure :as i]))
(s/def ::config
(s/keys :req-un [::cd/restic-repository ::cd/backup-path]
:opt-un [::cd/certificate-file ::cd/directory ::cd/debug
::cd/dry-run ::cd/days-to-keep ::cd/months-to-keep]))
(s/keys :req-un [::cd/restic-repository
::cd/backup-path]
:opt-un [::cd/certificate-file
::cd/password-file
::cd/days-to-keep
::cd/months-to-keep
::cd/directory
::cd/dry-run
::cd/debug]))
(defn-spec initalized? boolean?
[config ::config]

View file

@ -12,8 +12,16 @@
(s/def ::config
(s/keys :req-un [::domain/target-directory
::cd/restic-repository ::cd/backup-path]
:opt-un [::domain/snapshot-id ::cd/certificate-file ::cd/directory ::cd/debug ::cd/dry-run]))
::cd/restic-repository
::cd/backup-path]
:opt-un [::domain/snapshot-id
::cd/certificate-file
::cd/password-file
::cd/days-to-keep
::cd/months-to-keep
::cd/directory
::cd/dry-run
::cd/debug]))
(defn-spec restore! nil?
[config ::config]