First of all - nice work! Soon you’ll be able to differentiate Duplicacy from other backup tools on the basis of performance AND functionality/ease of use.
Note: I am running duplicacy on a Linux x64 server.
Is there any way we can get this into a docker image? I’m fairly religious about running my web apps in docker images (reverse-proxied by Traefik). Benefits?
Minimize the attack vector (if you don’t run docker as root).
Allows you to mount just the storage you want backed up to the image.
Eliminates the need to start the application before modifying the port it listens on (as has been mentioned, port 8080 will commonly be in use on an existing (shared) server. In a docker container, you can choose to:
Leave it at 8080 (since it’s only on the container) and reverse proxy to that port, without needing to bind it to the host at all (very common with several web apps I run).
Bind port 8080 internally to whatever port you want on the host without touching the code.
Here’s the Dockerfile I’ve created. The only error I’m getting is that it cannot find the CLI executable. I tried ensuring the CLI version of Duplicacy was available inside the image (at /bin, in the path) but no matter how I executed to GUI runtime, it gave the CLI missing error inside the container upon startup. That’s the one piece I need to figure out.
FROM alpine:latest ADD duplicacy_web_linux_x64_0.1.0 /bin/duplicacy_web ADD duplicacy_linux_x64_2.1.2 /bin/duplicacy RUN chmod +x /bin/duplicacy_web /bin/duplicacy EXPOSE 8080
I’ve tried each of the following as the last line in the Dockerfile:
CMD ["/bin/duplicacy_web"] and other variations. I just need to get the CLI found inside the image. I’m not exactly a developer though. Ideas?
Oh - here’s how a very simple
docker run would work:
docker run -d -p <any_port>:8080 -v /volume/to/backup:/backup/name_of_volume -v /second/volume/to/backup:/backup/name_of_second_volume <repo>/duplicacy_web
And a simple
image: <repo>/duplicacy_web container_name: duplicacy_web volumes: - /volume/to/backup:/backup/name_of_volume - /second/volume/to/backup:/backup/name_of_second_volume ports: - <any_port>:8080
Then all your backup repositories are nicely mounted inside the container. (By the way, I presume the web GUI doesn’t change the underlying architecture in which .duplicacy folder is present in each repo. If the repo information is kept elsewhere, then you could mount the backup repositories as “read only”).