Nold360 / docker-borgserver

Dockerimage that runs a Borg backup server, accessible by ssh using publickey authentication
40 stars 24 forks source link

COPY failed: stat /var/lib/docker/tmp/docker-builder549501746/data/run.sh: no such file or directory #8

Closed dokbua closed 4 years ago

dokbua commented 4 years ago

Build failed with the error "COPY failed: stat /var/lib/docker/tmp/docker-builder549501746/data/run.sh: no such file or directory".

The Dockerfile declares:

COPY ./data/run.sh /run.sh
COPY ./data/sshd_config /etc/ssh/sshd_config

but the documentation does not mention these files or what they should contain.

Nold360 commented 4 years ago

These files are contained in this repository. To build this container you should clone the whole git-repo, then it should just work:

git clone https://github.com/Nold360/docker-borgserver
cd docker-borgserver
docker build -t borgserver:latest .
dokbua commented 4 years ago

Fair enough, my bad. Still, after having cloned everything I still get an error:

borgserver_1  | ########################################################
borgserver_1  |  * Docker BorgServer powered by borg 1.1.9
borgserver_1  | ########################################################
borgserver_1  |  * User  id: 65534
borgserver_1  |  * Group id: 65534
borgserver_1  | ########################################################
borgserver_1  |  * Testing Volume BORG_DATA_DIR: /backup
borgserver_1  | ERROR: No SSH-Pubkey file found in /sshkeys
docker-borgserver_borgserver_1 exited with code 1

I understand the client keys should be under sshkeys/clients but I don't see any info about what should be under sshkeys?

It's also not clear to me what the client keys should be called?

Nold360 commented 4 years ago

filename = borg repo name all files will be included, except hidden/dotfiles, so just name it how you want your repo to be named: e.g. sshkeys/clients/noldbook -> repo will be named noldbook, so then you can borg init borgserver.domain:noldbook - where borgserver.domain must be replaced with whatever you need to resolve your borgserver setup.

https://github.com/Nold360/docker-borgserver#sshkeysclients