mirror of
https://github.com/garethgeorge/backrest.git
synced 2025-12-14 17:45:36 +00:00
fix: include restic binary in alpine and scratch docker images
This commit is contained in:
12
backrest.go
12
backrest.go
@@ -30,16 +30,24 @@ import (
|
||||
"golang.org/x/net/http2/h2c"
|
||||
)
|
||||
|
||||
var InstallDepsOnly = flag.Bool("install-deps-only", false, "install dependencies and exit")
|
||||
|
||||
func main() {
|
||||
flag.Parse()
|
||||
ctx, cancel := context.WithCancel(context.Background())
|
||||
go onterm(cancel)
|
||||
|
||||
resticPath, err := resticinstaller.FindOrInstallResticBinary()
|
||||
if err != nil {
|
||||
zap.S().Fatalf("Error finding or installing restic: %v", err)
|
||||
}
|
||||
|
||||
if *InstallDepsOnly {
|
||||
zap.S().Info("Dependencies installed, exiting")
|
||||
return
|
||||
}
|
||||
|
||||
ctx, cancel := context.WithCancel(context.Background())
|
||||
go onterm(cancel)
|
||||
|
||||
// Load the configuration
|
||||
configStore := createConfigProvider()
|
||||
cfg, err := configStore.Get()
|
||||
|
||||
Reference in New Issue
Block a user