-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathDockerfile
More file actions
30 lines (24 loc) · 1022 Bytes
/
Dockerfile
File metadata and controls
30 lines (24 loc) · 1022 Bytes
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
FROM arm64v8/ubuntu:20.04
FROM arm64v8/golang:1.17
ARG DEBIAN_FRONTEND=noninteractive
#ADD sources.list /etc/apt/
#RUN apt-key adv --keyserver keyserver.ubuntu.com --recv-keys 40976EAF437D05B5 \
# && apt-key adv --keyserver keyserver.ubuntu.com --recv-keys 3B4FE6ACC0B21F32
# Install: dependencies, clean: apt cache, remove dir: cache, man, doc, change mod time of cache dir.
RUN apt-get update \
&& apt-get install -y --no-install-recommends \
software-properties-common \
rsyslog systemd systemd-cron sudo \
ntfs-3g \
&& apt-get clean \
&& rm -Rf /usr/share/doc && rm -Rf /usr/share/man \
&& rm -rf /var/lib/apt/lists/* \
&& touch -d "2 hours ago" /var/lib/apt/lists
RUN sed -i 's/^\($ModLoad imklog\)/#\1/' /etc/rsyslog.conf
RUN rm -f /lib/systemd/system/systemd*udev* \
&& rm -f /lib/systemd/system/getty.target
RUN go env -w GOPROXY=https://goproxy.cn,direct
COPY . /mydocker
WORKDIR /mydocker
VOLUME ["/sys/fs/cgroup", "/tmp", "/run"]
CMD ["/lib/systemd/systemd"]