summaryrefslogtreecommitdiff
path: root/images/znc/Dockerfile
blob: 50028d7d7513bac4b3fc95bdba9f7e2125101eff (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
FROM alpine:3.6 AS builder

RUN apk add --no-cache build-base git automake autoconf openssl-dev icu-dev icu-libs

RUN git clone --single-branch --depth=1 --recursive https://github.com/znc/znc.git /tmp/znc

RUN mkdir -p /app /data
RUN cd /tmp/znc \
 && ./autogen.sh \
 && ./configure --prefix="/app/znc" \
 && make \
 && make install

ADD privmsg.cpp /tmp/
RUN cd /tmp/ \
 && /app/znc/bin/znc-buildmod /tmp/privmsg.cpp \
 && mv privmsg.so /app/znc/lib/znc/

FROM server_runit

EXPOSE 80

RUN apk add --no-cache sudo libcap openssl icu icu-libs ca-certificates
COPY --from=builder /app /app

# -S: system, -h: home
RUN adduser -S -h /data znc && chmod a+x /data
RUN chown -R znc /data