summaryrefslogtreecommitdiff
path: root/bugs/multirepository.mdwn
blob: 72695cfba35ac88e47211b1731d4601c06bb2f34 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
[[!tag obnam-wishlist]]

Obnam should support multiple repositories, to be chosen at invocation time.

- all repositories configured in config files
- nicknames for repositories so it's easy to choose
- --repository should accept nicknames
- choose many repositories for one run
- use all available repositories by default

--liw

---
Could this also be achieved by running Obnam from a wrapper script that uses a different repository for each run?  Could Obnam be run in parallel instances backing up the same data to different repos?  Is that possible now?  --*Adam*

---

Adam, it can certainly be done by using wrapper scripts (I've been doing that), and while I haven't
actually tried it, there should be no problem with backing up to multiple repositories concurrently,
though you may need to fiddle with the configs so that they use different log files. --liw

---

After some thinking, I think I don't want nicknames for repositories, I want "profiles".Here's a concrete
suggestion:

    [config]
    encrypt-with = CAFEF00D
    profile = all
    log = /var/log/obnam/obnam-%(profile)s.log
    
    [profile "online"]
    repository = sftp://liw@personal.backup.server.example.com/~/repo/
    use-if = ping -c1 personal.backup.server.example.com
    
    [profile "usb-drive"]
    repository = /media/Drum/obnam-repo/
    use-if = test -d /media/Drum/obnam-repo/
    
    [profile "at-work"]
    repository = /mnt/backups/
    use-if = ping -c1 fs.work.example.com
    pre-command = sudo mount /mnt/backups
    post-command = sudo umount /mnt/backups

- if --profile=all, then iterate automatically over all profiles
- otherwise, use only the chosen profiles
- some day: run some/all profiles in parallel in one obnam instance; initially, user may run parallel obnam instances
- log file should embed profile name somehow
- should profile be selected based on user too? that can be done with "use-if = test $USER = liw"; better support can be added later, if there's a need

--liw


---

this is handled easily by having a set of config files and giving the
"profile" one to --config. [[done]]  --liw