cleanup only when source is up
This commit is contained in:
parent
28bae81236
commit
23d7d90d20
2
app.go
2
app.go
@ -681,11 +681,13 @@ func (a AppConfig) CleanupSnapshot() error {
|
|||||||
for _, dest := range a.Destinations {
|
for _, dest := range a.Destinations {
|
||||||
if cfg.Box[dest.Box()].online {
|
if cfg.Box[dest.Box()].online {
|
||||||
for _, src := range a.Sources {
|
for _, src := range a.Sources {
|
||||||
|
if cfg.Box[src.Box()].online {
|
||||||
cleanupSnapshot[src.Box()] = cleanupSnapshot[src.Box()] + " " + src.Path()
|
cleanupSnapshot[src.Box()] = cleanupSnapshot[src.Box()] + " " + src.Path()
|
||||||
cleanupSnapshot[dest.Box()] = cleanupSnapshot[dest.Box()] + " " + dest.Path() + "/" + src.Box() + "/" + src.Path()
|
cleanupSnapshot[dest.Box()] = cleanupSnapshot[dest.Box()] + " " + dest.Path() + "/" + src.Box() + "/" + src.Path()
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
for k, v := range cleanupSnapshot {
|
for k, v := range cleanupSnapshot {
|
||||||
if *debugFlag {
|
if *debugFlag {
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
// Code generated by version.sh (@generated) DO NOT EDIT.
|
// Code generated by version.sh (@generated) DO NOT EDIT.
|
||||||
package main
|
package main
|
||||||
var githash = "93169ff"
|
var githash = "28bae81"
|
||||||
var buildstamp = "2022-06-17_13:57:23"
|
var buildstamp = "2022-06-17_14:02:53"
|
||||||
var commits = "38"
|
var commits = "39"
|
||||||
var version = "93169ff-b38 - 2022-06-17_13:57:23"
|
var version = "28bae81-b39 - 2022-06-17_14:02:53"
|
||||||
|
Loading…
Reference in New Issue
Block a user