-
Notifications
You must be signed in to change notification settings - Fork 1
/
Dockerfile
46 lines (33 loc) · 2.06 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
FROM ubuntu:22.04
LABEL maintainer="Andreas Peters <[email protected]>"
LABEL org.opencontainers.image.title="ubuntu-m3s"
LABEL org.opencontainers.image.description="Container image with preconfigured ubuntu for mesos m3s"
LABEL org.opencontainers.image.vendor="AVENTER UG (haftungsbeschränkt)"
LABEL org.opencontainers.image.source="https://github.com/AVENTER-UG/"
RUN apt update -y
RUN apt install -y wget jq containerd dnsmasq tcpdump curl inetutils-ping iptables
RUN apt install -y fuse-overlayfs procps bash iproute2 dnsutils net-tools systemctl socat conntrack tzdata
RUN apt install -y nfs-common rpcbind
RUN update-alternatives --set iptables /usr/sbin/iptables-legacy
# Prepare systemd environment.
ENV container docker
RUN ARCH=`uname -m` && \
curl -k -L https://download.docker.com/linux/static/stable/${ARCH}/docker-24.0.6.tgz | tar -xvz -C /usr/local/bin --strip 1 && \
mkdir -p /etc/docker
RUN mkdir /usr/lib/cni/
RUN ARCH=`dpkg --print-architecture` && \
curl -k -L https://github.com/Mirantis/cri-dockerd/releases/download/v0.3.4/cri-dockerd-0.3.4.${ARCH}.tgz | tar -xvz -C /tmp && \
curl -k -L https://github.com/flannel-io/cni-plugin/releases/download/v1.1.2/cni-plugin-flannel-linux-${ARCH}-v1.1.2.tgz | tar -xvz -C /usr/lib/cni/ && \
curl -k -L https://github.com/containernetworking/plugins/releases/download/v1.1.1/cni-plugins-linux-${ARCH}-v1.1.1.tgz | tar -xvz -C /usr/lib/cni/
RUN ARCH=`dpkg --print-architecture` && \
mv /usr/lib/cni/flannel-${ARCH} /usr/lib/cni/flannel
RUN mv /tmp/cri-dockerd/cri-dockerd /usr/bin/
RUN rm -rf /tmp/cri-dockerd
RUN curl -k -L https://raw.githubusercontent.com/Mirantis/cri-dockerd/master/packaging/systemd/cri-docker.service > /etc/systemd/system/cri-docker.service && \
curl -k -L https://raw.githubusercontent.com/Mirantis/cri-dockerd/master/packaging/systemd/cri-docker.socket > /etc/systemd/system/cri-docker.socket
RUN mkdir -p /var/lib/rancher/k3s/docker
RUN groupadd docker
COPY docker_daemon.json /etc/docker/daemon.json
# Prepare entrypoint.
COPY entrypoint.sh /
STOPSIGNAL SIGRTMIN+3