Bump version to 1.0.22

This commit is contained in:
2026-07-09 16:54:38 -04:00
parent 6c48031dd7
commit be7d47c0e1
3 changed files with 10 additions and 5 deletions
+1 -1
View File
@@ -1,5 +1,5 @@
BINARY=syncserver
VERSION?=1.0.21
VERSION?=1.0.22
GO?=go
LDFLAGS=-s -w -X main.version=$(VERSION) -X main.commit=$(shell git rev-parse --short HEAD 2>/dev/null || echo unknown)
BUILD_FLAGS=CGO_ENABLED=0
+1 -1
View File
@@ -20,7 +20,7 @@ import (
"github.com/syncserver/internal/syncengine"
)
var version = "1.0.21"
var version = "1.0.22"
func main() {
cfgPath := flag.String("config", "", "Path to config.yaml")
+8 -3
View File
@@ -261,17 +261,22 @@ func (e *Engine) Run(ctx context.Context, jobID int64, pairID int64) error {
var result *RsyncResult
if isRemoteToRemote(srcMachine, dstMachine) {
destPrivKey, err := e.resolveSSHKey(dstMachine)
destPrivKeyPath, err := e.resolveSSHKey(dstMachine)
if err != nil {
slog.Warn("failed to resolve destination SSH key, using server key", "error", err)
destPrivKey = filepath.Join(e.cfg.SSHDir(), "id_ed25519")
destPrivKeyPath = filepath.Join(e.cfg.SSHDir(), "id_ed25519")
}
destPrivKeyBytes, err := os.ReadFile(destPrivKeyPath)
if err != nil {
slog.Warn("failed to read destination SSH key, using empty", "error", err)
destPrivKeyBytes = []byte{}
}
result, err = runner.RunRemote(jobCtx, cfg, RemoteMachine{
Host: srcMachine.Host,
Port: srcMachine.Port,
SSHUser: srcMachine.SSHUser,
PrivKey: privKey,
DestPrivKey: destPrivKey,
DestPrivKey: string(destPrivKeyBytes),
}, onLine)
} else {
result, err = runner.Run(jobCtx, cfg, onLine)