-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathDockerfile
73 lines (53 loc) · 1.66 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
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
FROM ubuntu:22.04 as BACKINTIME-BUILDER
ARG BACKINTIME_VERSION=1.3.3
RUN apt-get update && \
apt-get install -q -y \
debhelper \
dh-python \
git \
build-essential \
gettext \
python3-pyfakefs \
python3 \
rsync \
cron \
openssh-client \
python3-keyring \
python3-dbus \
python3-packaging && \
rm -rf /var/lib/apt/lists/* /var/tmp/*
WORKDIR /tmp/
RUN git clone \
--depth 1 \
--branch v${BACKINTIME_VERSION} \
https://github.com/bit-team/backintime.git
WORKDIR /tmp/backintime/common
RUN ./configure && \
make
WORKDIR /tmp/backintime
RUN ./makedeb.sh
WORKDIR /tmp
RUN mv backintime-common_$(cat backintime/VERSION)_all.deb \
backintime-common.deb
FROM ubuntu:22.04
LABEL maintainer="Sander Bel <[email protected]>"
RUN apt-get update && \
apt-get install -q -y \
python3 \
rsync \
cron \
openssh-client \
python3-keyring \
python3-dbus \
python3-packaging \
sshfs && \
rm -rf /var/lib/apt/lists/* /var/tmp/*
WORKDIR /tmp
COPY --from=BACKINTIME-BUILDER /tmp/backintime-common.deb .
RUN dpkg -i backintime-common.deb && \
rm -f backintime-common.deb
RUN mkdir .ssh && \
chmod 700 .ssh
WORKDIR /root
COPY do-backup.sh .
ENTRYPOINT ["sh", "-c", "/root/do-backup.sh"]