Seems I didn’t fully understand it when I read the documentation the first time.
Thanks for the hint, it works now.
Here is what I did to get docker kopia repository server up an running. Maybe someone might find this useful:
Login to your docker host and create some base directories:
mkdir /srv/kopia
cd /srv/kopia
mkdir {cache,config,data,logs}
chown 65532:65532 {cache,config,data,logs} # kopia container runs in rootless mode
docker run --name kopia -e KOPIA_PASSWORD="yourrepositorypassword" \
-v /srv/kopia/data:/app/data \ # You only have to mount this if you create a local filesystem for storing the data
-v /srv/kopia/config:/app/config \
-v /srv/kopia/cache:/app/cache \
-v /srv/kopia/logs:/app/logs \
-v /etc/ssl/certs/yourcert_fullchain.pem:/app/backup.fullchain.pem \ # you can use --insecure for testing or create a self signed cert.
-v /etc/ssl/private/yourcert_privkey.pem:/app/backup.privkey.pem \
-p 51515:51515 \
kopia/kopia:latest server \
--address 0.0.0.0:51515
--tls-cert-file /app/backup.fullchain.pem \
--tls-key-file /app/backup.privkey.pem
In a second screen, during the server is running (upper command), you can execute additional commands for creating the local filesystem or add a user:
docker run -e KOPIA_PASSWORD="yourrepositorypassword" \
-v /srv/kopia/data:/app/data \
-v /srv/kopia/config:/app/config \
-v /srv/kopia/cache:/app/cache \
-v /srv/kopia/logs:/app/logs \
kopia/kopia:latest repository create filesystem \
--path=/app/data
For adding a user, use the docker arguments as above, but then
...
kopia/kopia:latest server user add user1@laptop1 \
--user-password="passwordforuser1"
If you want to be able to login as “root” (kopia user) to the WebUI, you have to create a user, e.g. kopia@localhost, and then restart the server and append the following argument:
...
--server-username kopia@localhost
You can go now to your hosts ip address:51515 and login with kopia@localhost and the defined password.