Browse Source

working docker image for end users.

GitHub Issue #1013
Grant Limberg 6 năm trước cách đây
mục cha
commit
1cf953c046

+ 4 - 8
ext/installfiles/linux/zerotier-containerized/Dockerfile

@@ -7,17 +7,13 @@ FROM debian:buster-slim as builder
 RUN apt-get update && apt-get install -y curl gnupg
 RUN apt-get update && apt-get install -y curl gnupg
 RUN apt-key adv --keyserver ha.pool.sks-keyservers.net --recv-keys 0x1657198823e52a61  && \
 RUN apt-key adv --keyserver ha.pool.sks-keyservers.net --recv-keys 0x1657198823e52a61  && \
     echo "deb http://download.zerotier.com/debian/buster buster main" > /etc/apt/sources.list.d/zerotier.list
     echo "deb http://download.zerotier.com/debian/buster buster main" > /etc/apt/sources.list.d/zerotier.list
-RUN apt-get update && apt-get install -y zerotier-one=1.2.12
-RUN curl https://raw.githubusercontent.com/zerotier/ZeroTierOne/master/ext/installfiles/linux/zerotier-containerized/main.sh > /var/lib/zerotier-one/main.sh
+RUN apt-get update && apt-get install -y zerotier-one=1.4.4
+COPY ext/installfiles/linux/zerotier-containerized/main.sh /var/lib/zerotier-one/main.sh
 
 
-FROM alpine:latest
-LABEL version="1.2.12"
+FROM debian:buster-slim
+LABEL version="1.4.4"
 LABEL description="Containerized ZeroTier One for use on CoreOS or other Docker-only Linux hosts."
 LABEL description="Containerized ZeroTier One for use on CoreOS or other Docker-only Linux hosts."
 
 
-# Uncomment to build in container
-# RUN apk add --update alpine-sdk linux-headers
-RUN apk add --update libgcc libstdc++
-
 # ZeroTier relies on UDP port 9993
 # ZeroTier relies on UDP port 9993
 EXPOSE 9993/udp
 EXPOSE 9993/udp
 
 

+ 2 - 3
make-linux.mk

@@ -331,9 +331,8 @@ realclean:	distclean
 official:	FORCE
 official:	FORCE
 	make -j4 ZT_OFFICIAL=1 all
 	make -j4 ZT_OFFICIAL=1 all
 
 
-#docker:	FORCE
-#	make clean ; make -j4 one
-#	docker build -f docker/Dockerfile .
+docker:	FORCE
+	docker build -f ext/installfiles/linux/zerotier-containerized/Dockerfile -t zerotier-containerized .
 
 
 central-controller:	FORCE
 central-controller:	FORCE
 	make -j4 LDLIBS="-L/usr/pgsql-10/lib/ -lpq -Lext/librabbitmq/centos_x64/lib/ -lrabbitmq" CXXFLAGS="-I/usr/pgsql-10/include -I./ext/librabbitmq/centos_x64/include -fPIC" DEFS="-DZT_CONTROLLER_USE_LIBPQ -DZT_CONTROLLER" ZT_OFFICIAL=1 ZT_USE_X64_ASM_ED25519=1 one
 	make -j4 LDLIBS="-L/usr/pgsql-10/lib/ -lpq -Lext/librabbitmq/centos_x64/lib/ -lrabbitmq" CXXFLAGS="-I/usr/pgsql-10/include -I./ext/librabbitmq/centos_x64/include -fPIC" DEFS="-DZT_CONTROLLER_USE_LIBPQ -DZT_CONTROLLER" ZT_OFFICIAL=1 ZT_USE_X64_ASM_ED25519=1 one