2019-09-05 19:14:30 +02:00
|
|
|
# Usage:
|
|
|
|
# Building
|
|
|
|
# docker build -t weechat-matrix .
|
|
|
|
# Running (no saved state)
|
|
|
|
# docker run -it \
|
|
|
|
# -v /etc/localtime:/etc/localtime:ro \ # for your time
|
|
|
|
# weechat-matrix
|
|
|
|
# Running (saved state)
|
|
|
|
# docker run -it \
|
|
|
|
# -v /etc/localtime:/etc/localtime:ro \ # for your time
|
|
|
|
# -v "${HOME}/.weechat:/home/user/.weechat" \
|
|
|
|
# weechat-matrix
|
|
|
|
#
|
|
|
|
FROM alpine:latest
|
|
|
|
|
|
|
|
RUN apk add --no-cache \
|
|
|
|
build-base \
|
|
|
|
ca-certificates \
|
|
|
|
git \
|
|
|
|
libffi-dev \
|
|
|
|
libressl-dev \
|
|
|
|
python \
|
|
|
|
python-dev \
|
|
|
|
py2-pip \
|
|
|
|
weechat \
|
|
|
|
weechat-perl \
|
|
|
|
weechat-python \
|
2020-05-15 10:46:43 +02:00
|
|
|
--repository https://dl-4.alpinelinux.org/alpine/edge/community
|
2019-09-05 19:14:30 +02:00
|
|
|
|
|
|
|
ENV HOME /home/user
|
|
|
|
|
|
|
|
RUN adduser -S user -h $HOME \
|
|
|
|
&& chown -R user $HOME \
|
|
|
|
&& cd $HOME \
|
|
|
|
&& git clone https://github.com/poljar/weechat-matrix.git \
|
|
|
|
&& cd weechat-matrix \
|
|
|
|
&& pip install -r requirements.txt \
|
2019-09-05 19:49:10 +02:00
|
|
|
&& pip install websocket-client \
|
2019-09-05 19:14:30 +02:00
|
|
|
&& make install \
|
|
|
|
&& chown -R user $HOME
|
|
|
|
|
|
|
|
WORKDIR $HOME
|
|
|
|
USER user
|
|
|
|
|
2019-09-10 18:14:13 +02:00
|
|
|
CMD [ "weechat" ]
|