forked from tutumcloud/dockup
-
Notifications
You must be signed in to change notification settings - Fork 9
/
Dockerfile
46 lines (39 loc) · 1.11 KB
/
Dockerfile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
FROM debian:bullseye-slim
LABEL maintainer="Simon Templer <[email protected]>"
RUN apt-get update \
&& apt-get install -y --no-install-recommends cron python3-pip gnupg1 curl \
&& pip install awscli \
&& apt-get autoclean -y \
&& apt-get autoremove -y \
&& rm -rf /usr/share/locale/* \
&& rm -rf /var/cache/debconf/*-old \
&& rm -rf /var/lib/apt/lists/* \
&& rm -rf /usr/share/doc/* \
&& ln -s /usr/bin/gpg1 /usr/bin/gpg
COPY ./scripts /dockup/
RUN chmod 755 /dockup/*.sh
CMD ["/dockup/run.sh"]
ENV PATHS_TO_BACKUP auto
ENV BACKUP_NAME backup
ENV RESTORE false
ENV RESTORE_TAR_OPTION --preserve-permissions
ENV NOTIFY_BACKUP_SUCCESS false
ENV NOTIFY_BACKUP_FAILURE false
ENV BACKUP_TAR_TRIES 5
ENV BACKUP_TAR_RETRY_SLEEP 30
ENV DOCKUP_MODE aws
ENV DOCKUP_COMPRESS true
# aws
ENV S3_BUCKET_NAME docker-backups.example.com
ENV AWS_ACCESS_KEY_ID **DefineMe**
ENV AWS_SECRET_ACCESS_KEY **DefineMe**
ENV AWS_DEFAULT_REGION us-east-1
# local
ENV LOCAL_TARGET /dockup/target
RUN mkdir $LOCAL_TARGET
# ENV LOCAL_CLEANUP_OLDER_HOURS
# working directory
ENV WORK_DIR /dockup/work
RUN mkdir -p $WORK_DIR
VOLUME $WORK_DIR
WORKDIR /dockup