{"id":13682015,"url":"https://github.com/borgmatic-collective/docker-borgmatic","last_synced_at":"2026-04-07T09:02:14.371Z","repository":{"id":38045665,"uuid":"100482658","full_name":"borgmatic-collective/docker-borgmatic","owner":"borgmatic-collective","description":"Borgmatic in Docker","archived":false,"fork":false,"pushed_at":"2026-03-20T15:14:08.000Z","size":537,"stargazers_count":517,"open_issues_count":33,"forks_count":109,"subscribers_count":5,"default_branch":"master","last_synced_at":"2026-03-21T07:04:43.392Z","etag":null,"topics":["docker","docker-image"],"latest_commit_sha":null,"homepage":"","language":"Dockerfile","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"gpl-3.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/borgmatic-collective.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2017-08-16T11:38:29.000Z","updated_at":"2026-03-20T15:14:10.000Z","dependencies_parsed_at":"2023-02-18T22:15:32.974Z","dependency_job_id":"d6aa5cf0-fb7c-49f7-8c7e-b57f699a05af","html_url":"https://github.com/borgmatic-collective/docker-borgmatic","commit_stats":null,"previous_names":["b3vis/docker-borgmatic"],"tags_count":84,"template":false,"template_full_name":null,"purl":"pkg:github/borgmatic-collective/docker-borgmatic","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/borgmatic-collective%2Fdocker-borgmatic","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/borgmatic-collective%2Fdocker-borgmatic/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/borgmatic-collective%2Fdocker-borgmatic/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/borgmatic-collective%2Fdocker-borgmatic/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/borgmatic-collective","download_url":"https://codeload.github.com/borgmatic-collective/docker-borgmatic/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/borgmatic-collective%2Fdocker-borgmatic/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":31506578,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-04-07T03:10:19.677Z","status":"ssl_error","status_checked_at":"2026-04-07T03:10:13.982Z","response_time":105,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.5:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["docker","docker-image"],"created_at":"2024-08-02T13:01:39.252Z","updated_at":"2026-04-07T09:02:14.353Z","avatar_url":"https://github.com/borgmatic-collective.png","language":"Dockerfile","funding_links":[],"categories":["Dockerfile","Shell","docker"],"sub_categories":[],"readme":"# borgmatic Container\n\n![](https://github.com/witten/borgmatic/raw/main/docs/static/borgmatic.png)\n\n[![](https://img.shields.io/github/issues/borgmatic-collective/docker-borgmatic)](https://github.com/borgmatic-collective/docker-borgmatic/issues)\n[![](https://img.shields.io/github/stars/borgmatic-collective/docker-borgmatic)](https://github.com/borgmatic-collective/docker-borgmatic/stargazers)\n[![](https://img.shields.io/docker/stars/b3vis/borgmatic)](https://hub.docker.com/r/b3vis/borgmatic)\n[![](https://img.shields.io/docker/pulls/b3vis/borgmatic)](https://hub.docker.com/r/b3vis/borgmatic)\n\n## Description ##\n\n\nThis repository provides a Docker image for [borgmatic](https://github.com/witten/borgmatic), a simple and efficient backup tool based on [Borgbackup](https://github.com/borgbackup). The image is designed to make it easy to set up and run borgmatic (with Borg and optionally Cron daemon) within a Docker container, enabling you to streamline your backup process and ensure the safety of your data.\n\n\u003e **Warning**\n\u003e As of 2023-06-23 msmtp and ntfy flavors have been discontinued. This image has now switched to apprise.\n\n\u003e **Warning**\n\u003e Secrets will be implemented differently from October 2024. From `*_FILE` to `FILE__*`\n\n## Usage ##\n\n### Prerequisites\nBefore proceeding, ensure that you have [Docker](https://www.docker.com/) installed and properly configured on your system. Refer to the [Docker documentation](https://docs.docker.com/engine/install/) for installation instructions specific to your operating system. If you want to use [docker-compose](https://docs.docker.com/compose/install/), you may also need to install it seperately.\nAlternatively, you can also use [podman](https://podman.io/docs) to run this image.\n\n### Getting Started\n\nRun this command to create data directories required by this image under your prefered directory.\n\n```\nmkdir data/{borgmatic.d,repository,.config,.ssh,.cache}\n```\nConfigure a copy of borgmatic's [config.yaml](data/borgmatic.d/config.yaml) in `data/borgmatic.d` and run the container. You can modify any of the host mount point to fit your backup configuration.\n\n```\ndocker run \\\n  --detach --name borgmatic \\\n  -v /home:/mnt/source:ro \\\n  -v ./data/repository:/mnt/borg-repository \\\n  -v ./data/borgmatic.d:/etc/borgmatic.d/ \\\n  -v ./data/.config/borg:/root/.config/borg \\\n  -v ./data/.ssh:/root/.ssh \\\n  -v ./data/.cache/borg:/root/.cache/borg \\\n  -v ./data/.state/borgmatic:/root/.local/state/borgmatic \\\n  -e TZ=Europe/Berlin \\\n  ghcr.io/borgmatic-collective/borgmatic\n```\n\nSee [Other usage methods](#other-usage-methods) below for more options.\n\n### Running the container the first time ###\n\nWhen you run the container for the first time, you'll need to execute into the container and run a command to initialize the repository in the directory you've specified in your docker configuration:\n\n```\ndocker exec -it borgmatic /bin/sh\nborgmatic init --encryption repokey\n```\n\nIn addition, it may be a good idea to manually perform a backup to ensure everything performs as expected:\n\n```\ndocker exec -it borgmatic /bin/sh\nborgmatic --stats -v 1 --files\n```\n\nBoth these commands will use the `borgmatic.d/config.yaml` file you provided, along with the `BORG_PASSPHRASE` and other environment variables in your docker configuration.\n\n\u003e **Note/Gotcha for archive names:** \n\u003e By default borgmatic uses `{hostname}` for naming (and then pruning, compacting archives). However the docker containers hostname changes every time it's rebuilt. To ensure consistent naming across archives and a properly working prune/compact you should specifically set the archive name in the config.yaml e.g. `archive_name_format: 'my-pc-backup-{now:%Y-%m-%d-%H%M%S}`.\n\n## Volumes ##\n\nThe following volumes are available for mounting:\n| Volume | Description |\n| --- | --- |\n| `/mnt/source` | Your data you wish to backup. For *some* safety you may want to mount read-only. borgmatic is running as root so all files can be backed up. |\n| `/mnt/borg-repository` | Mount your borg backup repository here. |\n| `/etc/borgmatic.d` | Where you need to create crontab.txt and your borgmatic config.yml |\n| `/root/.borgmatic` | **Note** this is now redundant and has been deprecated, please remove this from your configs |\n| `/root/.local/state/borgmatic` | Here are the state files for periodic checks. |\n| `/root/.config/borg` | Here the borg config and keys for keyfile encryption modes are stored. Make sure to backup your keyfiles! Also needed when encryption is set to none. |\n| `/root/.ssh` | Mount either your own .ssh here or create a new one with ssh keys in for your remote repo locations. |\n| `/root/.cache/borg` | A non-volatile place to store the borg chunk cache. |\n\nTo generate an example borgmatic configuration, run:\n```\ndocker exec borgmatic \\\nbash -c \"cd \u0026\u0026 borgmatic config generate -d /etc/borgmatic.d/config.yaml\"\n```\n\n## Environment ##\n\nYou can set the following environment variables:\n| Variable | Description |\n| --- | --- |\n| `TZ` | Time zone, e.g. `TZ=\"Europe/Berlin\"'`. |\n| `BORG_RSH` | SSH parameters, e.g. `BORG_RSH=\"ssh -i /root/.ssh/id_ed25519 -p 50221\"` |\n| `BORG_PASSPHRASE` | Repository passphrase, e.g. `BORG_PASSPHRASE=DonNotMissToChangeYourPassphrase` |\n| `BACKUP_CRON` | Cron schedule to run borgmatic. Default:`0 1 * * *` |\n| `RUN_ON_STARTUP` | Run borgmatic on startup. e.g.: `RUN_ON_STARTUP=true` |\n| `DOCKERCLI` | Install docker client executable to manipulate (start/stop) containers before, or after backup. See [here](#starting-and-stopping-containers-from-hooks) for a detailed explanation. |\n\nYou can also provide your own crontab file. If `data/borgmatic.d/crontab.txt` exists, `BACKUP_CRON` will be ignored in preference to it. In here you can add any other tasks you want ran\n```\n0 1 * * * PATH=$PATH:/usr/local/bin /usr/local/bin/borgmatic --stats -v 0 2\u003e\u00261\n```\n\nBeside that, you can also pass any environment variable that is supported by borgmatic. See documentation for [borgmatic](https://torsion.org/borgmatic/) and [Borg](https://borgbackup.readthedocs.io/) and for a list of supported variables.\n\n### Environment variables from files (Docker secrets)¶\nYou can set any environment variable from a file by using a special prepend `FILE__`.\nAs an example:\n```\n-e FILE__BORG_PASSPHRASE=/run/secrets/mysecretvariable\n```\nWill set the environment variable `BORG_PASSPHRASE` based on the contents of the `/run/secrets/mysecretvariable` file.\n\nIt is important to know that this environment variable is **not** simply available via `docker (compose) exec borgmatic sh` but only for the automatic call via the defined cron.\n\n#### Manual commands with secrets\nIf you want to initialize a repository manually or start a backup outside of the cron job, proceed as follows:\n\n- **Initialize repository**\n  ```\n  docker exec borgmatic /bin/sh -c 'export BORG_PASSPHRASE=$(cat /run/s6/container_environment/BORG_PASSPHRASE) \u0026\u0026 borgmatic init --encryption repokey'\n  ```\n- **Trigger manual backup**\n  ```\n  docker exec borgmatic /bin/sh -c 'export BORG_PASSPHRASE=$(cat /run/s6/container_environment/BORG_PASSPHRASE) \u0026\u0026 borgmatic create --stats -v 0'\n  ```\n\n### Docker Image Tags\n\nThe following Docker image tags are available (assuming 1.8.13 is the latest release):\n\n- `1.8.13` - Specific version 1.8.13\n- `1.8.12` - Specific version 1.8.12\n- `1.8` - Latest 1.8.x version (currently 1.8.13)\n- `1` - Latest 1.x.x version (currently 1.8.13)\n- `latest` - Latest version (currently 1.8.13)\n\nThis tagging system allows you to pin to your preferred level of version stability:\n- Pin to a specific version (e.g., `1.8.13`) for maximum stability\n- Pin to a minor version (e.g., `1.8`) to receive patch updates only\n- Pin to a major version (e.g., `1`) to receive minor and patch updates, but not major version changes\n- Use `latest` to always get the most recent version\n\n## Using Apprise for Notifications\n\nTo enhance your experience with Borgmatic, we'll show you a quick example of how to use Apprise for notifications. Apprise is a versatile tool that integrates with a variety of services and is built into Borgmatic. With the upcoming version 1.8.4 also natively. Here's a quick example of how you can use Apprise.\n\n### Basic Setup\n\n#### Cronjob Configuration\n\nIn an unmodified Borgmatic installation, your `crontab.txt` might look something like this:\n\n```\n0 1 * * * /usr/local/bin/borgmatic --stats -v 0 2\u003e\u00261\n```\n\nTo incorporate Apprise notifications, you can modify it like this:\n\n```\n*/5 * * * * PATH=$PATH:/usr/local/bin /usr/local/bin/borgmatic --stats -v 0 \u003e /tmp/backup_run.log\n```\n\n#### Borgmatic Configuration\n\nAdd the following lines to your Borgmatic configuration file (`config.yaml`):\n\n```yaml\nbefore_backup:\n  - echo \"Starting a backup job.\"\n\nafter_backup:\n  - echo \"Backup created.\"\n  - apprise -vv -t \"✅ SUCCESS\" -b \"$(cat /tmp/backup_run.log)\" \"mailtos://smtp.example.com:587?user=server@example.com\u0026pass=YourSecurePassword\u0026from=server@example.com\u0026to=receiver@example.com\"\n\non_error:\n  - echo \"Error while creating a backup.\"\n  - apprise -vv -t \"❌ FAILED\" -b \"$(cat /tmp/backup_run.log)\" \"mailtos://smtp.example.com:587?user=server@example.com\u0026pass=YourSecurePassword\u0026from=server@example.com\u0026to=receiver@example.com\"\n```\n\n##### Note:\n\nIf you don't want to send the log file, you can replace `-b \"$(cat /tmp/backup_run.log)\"` with a custom message like `-b \"My message\"`.\n\n### Advanced Options\n\n##### Apprise Capabilities\n\nApprise offers a variety of services to send notifications to, such as Telegram, Slack, Discord, and many more. For a complete list, visit the [Apprise GitHub page](https://github.com/caronc/apprise#productivity-based-notifications).\n\n#### Example for Multiple Services\n\nApprise allows you to notify multiple services at the same time:\n\n```yaml\nafter_backup:\n  - echo \"Backup created.\"\n  - apprise -vv -t \"✅ SUCCESS\" -b \"$(cat /tmp/backup_run.log)\" \"mailtos://smtp.example.com:587?user=server@example.com\u0026pass=YourSecurePassword\u0026from=server@example.com\u0026to=receiver@example.com,slack://token@Txxxx/Bxxxx/Cxxxx\"\n```\n\n### Native Apprise Configuration in Borgmatic 1.8.4+\n\nStarting from version 1.8.4, Borgmatic has native support for Apprise within its configuration. This makes it even easier to set up notifications. Below is how you can add Apprise directly to your Borgmatic `config.yaml`.\n\n```yaml\napprise:\n    states:\n        - start\n        - finish\n        - fail\n\n    services:\n        - url: mailtos://smtp.example.com:587?user=server@example.com\u0026pass=YourSecurePassword\u0026from=server@example.com\u0026to=receiver@example.com\n          label: mail\n        - url: slack://token@Txxxx/Bxxxx/Cxxxx\n          label: slack\n\n    start:\n        title: ⚙️ Started\n        body: Starting backup process.\n\n    finish:\n        title: ✅ SUCCESS\n        body: Backups successfully made.\n\n    fail:\n        title: ❌ FAILED\n        body: Your backups have failed.\n```\n\nAnd as of borgmatic 1.8.9+, borgmatic's logs are automatically appended to the `body` for each notification.\n\n### Conclusion\n\nApprise provides a flexible and powerful way to handle notifications in Borgmatic. Be sure to check out the [official Apprise documentation](https://github.com/caronc/apprise#productivity-based-notifications) for a full range of options and capabilities.\n\n\n## Other usage methods\n\n### Run borgmatic like a binary through a container\nThis image can be used to run borgmatic like a binary by passing the borgmatic command while running the container. It allows you to isolate your system and execute borgmatic commands without directly installing borgmatic on your host system and only keeping persistent data.\n\nTo execute borgmatic commands, you can run your container by passing borgmatic subcommands:\n```\ndocker run --rm -it \\\nMOUNT_FLAGS_HERE \\\nghcr.io/borgmatic-collective/borgmatic \\\nlist\n```\n\n**NOTE** Replace `MOUNT_FLAGS_HERE` placeholder with appropriate [mount flags](#volumes) and optionally [environment flags](#environment). [See above](#getting-started) for more clues.\n\nThis will execute `borgmatic list` in your container. The idea is to create symlink to a script which executes this. Now create a new file `borgmatic-docker.sh` somewhere like your workspace or home directory.\n```\n#!/bin/sh\n\ndocker run --rm -it \\\nMOUNT_FLAGS_HERE \\\nghcr.io/borgmatic-collective/borgmatic \\\n\"$@\"\n```\nModify the above script as per your needs and copy it's path. Now you can either create a symbolic link to this script or add it as alias.\n\n1. Create a symlink to a directory that exists in your PATH variable e.g.:\n```\nchmod +x /path/to/script/borgmatic-docker.sh\nsudo ln [-s] /path/to/script/borgmatic-docker.sh /usr/local/bin/borgmatic\n```\n\n2. Or, to create an alias add this to your `~/.bashrc` or similar file for other shells.\n```\nalias borgmatic=\"sh /path/to/script/borgmatic-docker.sh\"\n```\n\n**Tip** You can view list of available command line options in [borgmatic's docs](https://torsion.org/borgmatic/docs/reference/command-line/)\n\n### Running as daemon\nTo keep the container always running for continous backup, you can run it in detached mode. If you do not pass the command, by default it'll start the cron daemon which will run borgmatic at interval set in crontab.txt file.\n\n```\ndocker run -d --restart=always \\\nMOUNT_FLAGS_HERE \\\nghcr.io/borgmatic-collective/borgmatic \\\n```\n\nIf you ever need to run borgmatic manually, for instance to view or recover files, run:\n\n```\ndocker exec -it container_id_or_name bash\n```\n\nThen you can run `borgmatic` directly within that shell.\n\n### Structure deployment with docker-compose\n\nUse docker compose for easily management of your borgmatic container. You can also use this image with your existing docker-compose configuration to immediate setup backups for your deployed containers and/or the host.\n\n\u003c!-- Configure .env --\u003e\n1. Copy `.env.template` to `.env` and edit it to your needs.\n```\ncp .env.template .env\n```\n\nYou will need to configure environment variables for volumes. You can also directly configure `docker-compose.yml` file.\n\nBeside these, you can also set other configuration variables in your `.env` file. See [Environment](#environment) section for more details.\n\n2. Start the container\n```\ndocker-compose up -d\n```\n\n3. To view logs\n```\ndocker-compose logs -f\n```\n\n#### Miscelaneous\n\nIf you want to run borgmatic commands using this configuration instead of starting the container as daemon, you can run:\n\u003c!-- TODO: entry.sh is not working with docker-compose, having to pass full command --\u003e\n```\ndocker-compose run --rm borgmatic borgmatic list\n```\n\nIf a container is already running, you can execute borgmatic commands in it by running:\n```\ndocker-compose exec borgmatic ls\n# or to run a shell\ndocker-compose exec borgmatic bash\n```\n\n#### Restoring backups\n\n1. Stop the backup container: `docker-compose down`\n2. Modify volume `/host/mount/location` in `docker-compose.restore.yml` file to point to the location where you want to restore your backup.\n3. Run an interactive shell: `docker-compose -f docker-compose.yml -f docker-compose.restore.yml run borgmatic`\n4. Fuse-mount the backup: `borg mount /mnt/borg-repository \u003cmount_point\u003e`\n5. Restore your files\n6. Finally unmount and exit: `borg umount \u003cmount_point\u003e \u0026\u0026 exit`.\n\n**Tip** In case Borg fails to create/acquire a lock: `borg break-lock /mnt/repository`\n\n## Advanced ##\n\n#### Starting and stopping containers from hooks\n\nIn case you are using the container to backup docker volumes used by other containers, you might\nwant to make sure that the data is consistent and doesn't change while the backup is running. The\neasiest way to ensure this is to stop the affected containers before the backup and restart them\nafterwards.\n\nThere are two ways to achieve the start and stops. The first [use Docker CLI](#option-1-using-docker-cli). The second [Use Docker HTTP-POST API](#option-2-using-docker-http-post-api).\n\nYou can use the appropriate [borgmatic hooks](https://torsion.org/borgmatic/docs/how-to/add-preparation-and-cleanup-steps-to-backups/) and\n[control the docker engine through the API](https://docs.docker.com/engine/api/), or via the docker client labrary (see options) using the hosts\ndocker socket.\n\nPlease note that you might want to prefer the `*_everything` hooks to the `*_backup` hooks, as\n`after_backup` will not run if the backup fails for any reason (missing disk space, etc.) and\ntherefore the containers stay stopped.\n\nFirst mount the docker socket from the host by adding `-v /var/run/docker.sock:/var/run/docker.sock`\nto your `run` command or in the volume list of your `docker-compose.yml`.\n\nNow, pick one of these two options.\n\n##### Option 1 Using Docker CLI\n\nAdd the following environment to your docker run command line ``-e DOCKERCLI='true'``\nto your `run` command or in the enviroment section of your `docker-compose.yml`. This is in addition to the above mentioned socket to add.\n\nNow the docker command is available in your container. \n\nThen add the following in your config.yaml:\n```\n...\nconstants:\n  ...\n  containernames: \"container-a container-b container c\"\n...\nbefore_backup:\n  - echo {containernames} | xargs -n 1 echo | tac | xargs docker stop\n\nafter_backup:\n  - echo {containernames} | xargs docker start\n...\n```\nThis way all the containers are stopped in reverse order before the backup, and restarted in order after the backup. This way, for instance, you can ensure the back-end gets stopped last and started first.\n\n**Note**: Make sure you put the names of the containers in a single, quoted string, separated by spaces, as the *containernames* constant shows.\n\n##### Option 2 Using Docker HTTP-POST API\n\nThen use the following example to create the start/stop hooks in the `config.yml` for the containers\nthat you want to control.\n\n```yaml\nhooks:\n    before_everything:\n        - echo \"Stopping containers...\"\n        - 'echo -ne \"POST /v1.41/containers/\u003ccontainer1-name\u003e/stop HTTP/1.1\\r\\nHost: localhost\\r\\n\\r\\n\" | nc local:/var/run/docker.sock 80 \u003e /dev/null \u0026\u0026 echo \"Stopped Container 1\" || echo \"Failed to stop Container 1\"'\n        - 'echo -ne \"POST /v1.41/containers/\u003ccontainer2-name\u003e/stop HTTP/1.1\\r\\nHost: localhost\\r\\n\\r\\n\" | nc local:/var/run/docker.sock 80 \u003e /dev/null \u0026\u0026 echo \"Stopped Container 2\" || echo \"Failed to stop Container 2\"'\n        - echo \"Containers stopped.\"\n        - echo \"Starting a backup.\"\n\n    after_everything:\n        - echo \"Finished a backup.\"\n        - echo \"Restarting containers...\"\n        - 'echo -ne \"POST /v1.41/containers/\u003ccontainer1-name\u003e/start HTTP/1.1\\r\\nHost: localhost\\r\\n\\r\\n\" | nc local:/var/run/docker.sock 80 \u003e /dev/null \u0026\u0026 echo \"Started Container 1\" || echo \"Failed to start Container 1\"'\n        - 'echo -ne \"POST /v1.41/containers/\u003ccontainer2-name\u003e/start HTTP/1.1\\r\\nHost: localhost\\r\\n\\r\\n\" | nc local:/var/run/docker.sock 80 \u003e /dev/null \u0026\u0026 echo \"Started Container 2\" || echo \"Failed to start Container 2\"'\n        - echo \"Containers restarted.\"\n```\n\n### Mount an archive as FUSE filesystem\n\nWhile the parameters defined in above examples are sufficient for regular backups, following additional privileges will\nbe needed to mount an archive as FUSE filesystem:\n```\n--cap-add SYS_ADMIN \\\n--device /dev/fuse \\\n--security-opt label:disable \\\n--security-opt apparmor:unconfined\n```\nDepending on your security system, `--security-opt` parameters may not be necessary. `label:disable`\nis needed for *SELinux*, while `apparmor:unconfined` is needed for *AppArmor*.\n\nTo init the repo with encryption, run:\n```\ndocker exec borgmatic \\\nbash -c \"borgmatic --init --encryption repokey-blake2\"\n```\n\n### Additional Reading\n[Backup Docker using borgmatic](https://www.modem7.com/books/docker-backup/page/backup-docker-using-borgmatic) - Thank you [@modem7](https://github.com/modem7)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fborgmatic-collective%2Fdocker-borgmatic","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fborgmatic-collective%2Fdocker-borgmatic","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fborgmatic-collective%2Fdocker-borgmatic/lists"}