summaryrefslogtreecommitdiff
path: root/ext/installfiles/linux/zerotier-containerized/Dockerfile
blob: f1fc45ed3ef59b228f3c2704458fcaaba620415a (plain)
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
FROM alpine:latest as builder
MAINTAINER Adam Ierymenko <adam.ierymenko@zerotier.com>

ARG VERSION=1.2.12
LABEL version=$VERSION
LABEL description="Containerized ZeroTier One"

RUN apk add --update alpine-sdk linux-headers
RUN git clone https://github.com/zerotier/ZeroTierOne.git
WORKDIR ZeroTierOne
RUN git checkout $VERSION
RUN make

FROM alpine:latest as final

RUN apk add --update libgcc libstdc++

COPY --from=builder /ZeroTierOne/zerotier-one /
RUN chmod 0755 /zerotier-one
RUN ln -sf /zerotier-one /zerotier-cli
RUN mkdir -p /var/lib/zerotier-one

ADD main.sh /
RUN chmod 0755 /main.sh

ENTRYPOINT /main.sh