#!/usr/bin/env bash # pre action or use ExecStartPre /usr/bin/restic backup \ "${RESTIC_ADDITIONAL_CREATE_PARAMS}" \ --exclude-file "${RESTIC_FILE_EXCLUDE}" \ --files-from "${RESTIC_FILE_INCLUDE}" /usr/bin/restic forget "${RESTIC_KEEP}" # post action or adapt ExecStartPost