docker-borgserver icon indicating copy to clipboard operation
docker-borgserver copied to clipboard

Moving from native borg to docker-borgserver

Open Sdub76 opened this issue 6 months ago • 0 comments

I've been doing machine to machine backups for years using a borgmatic container on the client side and the borg binary directly on the server (accessed via SSH)

For a variety of reasons, I want to containerize borg on the server side and I came across this container which appears to meet my needs. Are there any special considerations when you aren't starting with a blank repo? Didn't see anything in run.sh that would be dangerous for existing repos, but thought I'd ask and leave this here for anyone else that may be looking to do the same (I'm on Unraid, but it doesn't really matter)

  1. Prepare environment on SERVER

    mkdir -p /mnt/user/appdata/borgserver/sshkeys/clients chown 1000:1000 /mnt/user/appdata/borgserver/sshkeys

  2. Copy CLIENT public keys to SERVER clients folder

    CLIENT /mnt/user/appdata/borgmatic/ssh_keys/id_rsa.pub --> SERVER /mnt/user/appdata/borgserver/sshkeys/clients/CLIENT

  3. Install docker-borgserver on SERVER. Verify docker logs are clean. port -> 2222 /sshkeys -> /mnt/user/appdata/borgserver/sshkeys /backup -> /mnt/disks/borg_backup

  4. Test access to SERVER backup from CLIENT (with translated path)

    borg_shell : borg info ssh://SERVER/mnt/disks/borg_backup/CLIENT/repo --> becomes borg_shell : borg info ssh://borg@SERVER:2222/backup/CLIENT/repo

Sdub76 avatar Jun 17 '25 19:06 Sdub76