-
Notifications
You must be signed in to change notification settings - Fork 1
/
Dockerfile
49 lines (38 loc) · 1 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
FROM clover/base AS base
RUN groupadd \
--gid 50 \
--system \
memcachedb \
&& useradd \
--home-dir /var/lib/memcachedb \
--no-create-home \
--system \
--shell /bin/false \
--uid 50 \
--gid 50 \
memcachedb
FROM library/ubuntu:bionic AS build
ENV LANG C.UTF-8
RUN export DEBIAN_FRONTEND=noninteractive \
&& apt-get update \
&& apt-get install -y \
--no-install-recommends \
software-properties-common \
apt-utils
RUN mkdir -p /build/image
WORKDIR /build
RUN apt-get download \
memcachedb \
libevent-2.1-6
RUN for file in *.deb; do dpkg-deb -x ${file} image/; done
WORKDIR /build/image
RUN rm -rf \
etc \
usr/share
COPY --from=base /etc/group /etc/gshadow /etc/passwd /etc/shadow etc/
COPY init/ etc/init/
FROM clover/base
WORKDIR /
COPY --from=build /build/image /
VOLUME [${MEMCACHEDB_DB_HOME:-/var/lib/memcached}]
EXPOSE ${MEMCACHED_TCP_PORT:-21201}/tcp ${MEMCACHED_UDP_PORT:-21201}/udp