Files
ttyd/Dockerfile
2019-04-15 00:51:41 +08:00

44 lines
1.0 KiB
Docker

FROM ubuntu:16.04
LABEL maintainer "Shuanglei Tao - tsl0922@gmail.com"
RUN apt-get update \
&& apt-get install -y --no-install-recommends \
ca-certificates \
cmake \
curl \
g++ \
git \
libjson-c2 \
libjson-c-dev \
libssl1.0.0 \
libssl-dev \
libwebsockets7 \
libwebsockets-dev \
pkg-config \
vim-common \
&& git clone --depth=1 https://github.com/tsl0922/ttyd.git /tmp/ttyd \
&& cd /tmp/ttyd && mkdir build && cd build \
&& cmake -DCMAKE_BUILD_TYPE=RELEASE .. \
&& make \
&& make install \
&& apt-get remove -y --purge \
cmake \
g++ \
libwebsockets-dev \
libjson-c-dev \
libssl-dev \
pkg-config \
&& apt-get purge -y \
&& apt-get autoremove -y \
&& rm -rf /var/lib/apt/lists/* \
&& rm -rf /tmp/ttyd
ENV TINI_VERSION v0.18.0
ADD https://github.com/krallin/tini/releases/download/${TINI_VERSION}/tini /tini
RUN chmod +x /tini
EXPOSE 7681
ENTRYPOINT ["/tini", "--"]
CMD ["ttyd", "bash"]