Dockerfile 1.1 KB
Newer Older
P
Ping Xiao 已提交
1 2 3 4
FROM ubuntu:latest AS builder
 
ARG PACKAGE=TDengine-server-1.6.5.10-Linux-x64.tar.gz
ARG EXTRACTDIR=TDengine-enterprise-server
5 6
ARG TARBITRATORPKG=TDengine-tarbitrator-1.6.5.10-Linux-x64.tar.gz
ARG EXTRACTDIR2=TDengine-enterprise-arbitrator
P
Ping Xiao 已提交
7 8 9
ARG CONTENT=taos.tar.gz
 
WORKDIR /root
10

P
Ping Xiao 已提交
11
COPY ${PACKAGE} .
12
COPY ${TARBITRATORPKG} .
P
Ping Xiao 已提交
13 14
 
RUN tar -zxf ${PACKAGE}
15
RUN tar -zxf ${TARBITRATORPKG}
P
Ping Xiao 已提交
16 17
RUN mv ${EXTRACTDIR}/driver ./lib
RUN tar -zxf ${EXTRACTDIR}/${CONTENT}
18
RUN mv ${EXTRACTDIR2}/bin/* /root/bin
P
Ping Xiao 已提交
19 20 21 22 23 24 25 26
 
FROM ubuntu:latest
 
WORKDIR /root

RUN apt-get update
RUN apt-get install -y vim tmux net-tools
RUN echo 'alias ll="ls -l --color=auto"' >> /root/.bashrc
27
RUN ulimit -c unlimited
28
       
P
Ping Xiao 已提交
29
COPY --from=builder /root/bin/taosd /usr/bin
30
COPY --from=builder /root/bin/tarbitrator /usr/bin
P
Ping Xiao 已提交
31 32 33 34 35 36 37 38
COPY --from=builder /root/bin/taos /usr/bin
COPY --from=builder /root/cfg/taos.cfg /etc/taos/
COPY --from=builder /root/lib/libtaos.so.* /usr/lib/libtaos.so.1
 
ENV LD_LIBRARY_PATH="$LD_LIBRARY_PATH:/usr/lib"
ENV LC_CTYPE=en_US.UTF-8
ENV LANG=en_US.UTF-8
 
39
EXPOSE 6030-6042/tcp 6060/tcp 6030-6039/udp
P
Ping Xiao 已提交
40 41 42
 
# VOLUME [ "/var/lib/taos", "/var/log/taos", "/etc/taos" ]
 
43
CMD [ "bash" ]