Minimal docker image for running scheduled backups using restic with rclone as the backend.
Based on jasonccox/restic-rclone-docker
Simply pulling ghcr.io/niniyas/restic-rclone:latest should retrieve the correct image for your arch, but you can
also pull specific arch images via tags.
| Architecture | Tag |
|---|---|
| amd64 | amd64 |
| arm64 | arm64 |
version: "3.9"
services:
restic:
container_name: Restic
image: ghcr.io/niniyas/restic-rclone:latest
environment:
- PUID=1000
- PGID=1000
- CRON=0 2 * * *
- TZ=Europe/Brussels
- ...
volumes:
- .logs:/logs # Optional. Required to see the logs.
- .data:/data # Required. This is the backup directory.
- .rclone/rclone.conf:/config/rclone/rclone.conf
docker run -d \
--name=Restic \
-e PUID=1000 \
-e PGID=1000 \
-e UMASK=002 \
-e .... \
-v .data:/data \
-v ....
ghcr.io/niniyas/restic-rclone:latest- PUID
- User ID. Optional.
- PGID
- Group ID. Optional.
- TZ
- Timezone. View available values here. Default is
Europe/Brussels.
- Timezone. View available values here. Default is
- CRON
- Use crontab.guru. Required. No defaults.
- RESTIC_PASSWORD
- Password for restic repo. Required.
- RESTIC_REPOSITORY
- restic repository location. Default
rest:http://0.0.0.0:8080/.
- restic repository location. Default
- RCLONE_REMOTE_NAME
- rclone remote name as given in config. Required if you are using rclone as
RESTIC_REPOSITORY.
- rclone remote name as given in config. Required if you are using rclone as
- RCLONE_REMOTE_LOCATION
- rclone remote location. Required if you are using
RCLONE_REMOTE_NAME.
- rclone remote location. Required if you are using
- RCLONE_CONFIG_LOCATION
- rclone config location. Optional. Default is
/config/rclone/rclone.conf.
- rclone config location. Optional. Default is
- RCLONE_SERVE_ARGS
- See here for more info. Optional. No defaults.
- RESTIC_BACKUP_ARGS
- restic arguments to use when backing up. See here for more info. Optional. No defaults.
- RESTIC_FORGET_ARGS
- See here for more info. Optional. No defaults.
- NOTIFICATIONS
trueorfalse. Optional. Default isfalse.
- APPRISE_BACKUP_ARGS
- Required if
NOTIFICATIONSis set totrue. If using one or more endpoints, use space to separate. See here for more info.
- Required if
- APPRISE_FORGET_ARGS
- Required if you need to get notifications about restic forget command. If using one or more endpoints, use space to separate. Optional. No defaults.
- APPRISE_TITLE
- Default is
Restic Backup. Optional.
- Default is
- HEALTHCHECK_URL
- healthchecks.io url. See here for more info. Optional. No defaults.
- HEALTHCHECK_HEADERS
- Headers to be used while performing healthcheck. Optional. No defaults. Use
|to separate multiple headers.- Example: Key1:Value1|Key2:Value2
- Headers to be used while performing healthcheck. Optional. No defaults. Use
- PRE_BACKUP_COMMANDS
- Commands to run before backup. Optional. No defaults. Use
|to separate multiple commands.
- Commands to run before backup. Optional. No defaults. Use
- POST_BACKUP_COMMANDS
- Commands to run after backup. Optional. No defaults. Use
|to separate multiple commands.
- Commands to run after backup. Optional. No defaults. Use