doorparty-server/Dockerfile

34 lines
964 B
Docker
Raw Normal View History

2021-03-15 12:25:50 +00:00
# NAME leenooks/doorparty
# VERSION latest
FROM debian:buster-slim
# Set the default timezone for the container
RUN ln -sf /usr/share/zoneinfo/Australia/Melbourne /etc/localtime
# Add SSH
RUN apt-get update \
&& apt-get install -yqq openssh-server \
&& apt-get -y autoremove \
&& apt-get clean \
&& rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/*
# Add Doorparty
RUN apt-get update \
&& apt-get install -yqq golang git \
&& cd /tmp && git clone https://github.com/echicken/dpc2 && cd dpc2 \
&& go mod vendor \
&& go build -o /sbin/doorparty-connector ./cmd/doorparty-connector.go \
&& chmod +x /sbin/doorparty-connector \
&& mv configs/doorparty-connector.ini /etc \
&& apt-get -y purge golang git \
&& apt-get -y autoremove \
&& apt-get clean \
&& rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/*
COPY doorparty-connector.ini /etc
COPY sshd_config /etc/ssh
COPY init /sbin/init
ENTRYPOINT [ "/sbin/init" ]