-
Notifications
You must be signed in to change notification settings - Fork 2
Expand file tree
/
Copy pathDockerfile
More file actions
43 lines (37 loc) · 1.22 KB
/
Dockerfile
File metadata and controls
43 lines (37 loc) · 1.22 KB
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
FROM postgres:11
ARG DEBIAN_FRONTEND=noninteractive
ARG BUILD_DEPS='gcc git libffi-dev libssl-dev python3-dev python3-pip python3-wheel'
RUN apt-get update && \
apt-get install -y --no-install-recommends \
$BUILD_DEPS \
gosu \
lzop \
libpq-dev \
pv \
python3 \
util-linux \
# swift package needs pkg_resources and setuptools
python3-pkg-resources \
python3-setuptools \
python3-pip && \
ln -sf /usr/bin/python3 /usr/bin/python && \
ln -sf /usr/bin/pip3 /usr/bin/pip
# setuptools from ubuntu archives is too old for googleapis-common-protos
RUN pip install --upgrade setuptools && \
pip install --disable-pip-version-check --no-cache-dir \
envdir==1.0.1 \
wal-e[aws,azure,google,swift]==1.1.0 \
gcloud==0.18.3 \
oauth2client==4.1.3 \
azure-storage==0.20.0
# cleanup
RUN apt-get purge -y --auto-remove $BUILD_DEPS && \
apt-get autoremove -y && \
apt-get clean -y
COPY rootfs /
ENV WALE_ENVDIR=/etc/wal-e.d/env
RUN mkdir -p $WALE_ENVDIR
RUN python3 /patcher-script.py /bin/create_bucket
RUN python3 /patcher-script.py /usr/local/bin/wal-e
CMD ["/docker-entrypoint.sh", "postgres"]
EXPOSE 5432