Allow to pass backup path as argument

This commit is contained in:
2023-04-06 17:47:21 +02:00
parent 81892dc7ef
commit c8c5fce9f9
2 changed files with 2 additions and 0 deletions

View File

@@ -16,5 +16,6 @@ RUN apk add --update --no-cache ca-certificates fuse openssh-client tzdata jq cu
COPY --from=builder /go/src/github.com/restic/restic/restic /usr/bin
ADD backup.sh /usr/local/bin/backup.sh
RUN chmod +x /usr/local/bin/backup.sh
ENTRYPOINT ["/usr/bin/restic"]

View File

@@ -1,5 +1,6 @@
#!/bin/sh -e
BACKUP_PATH=${BACKUP_PATH:-$1}
INSTANCE="$(echo ${INSTANCE:-${TAG}} | envsubst)"
export RESTIC_REPOSITORY="$(echo ${RESTIC_REPOSITORY} | envsubst)"