mirror of
https://github.com/linuxserver/docker-pidgin.git
synced 2026-01-14 17:02:00 +08:00
162 lines
4.0 KiB
Docker
162 lines
4.0 KiB
Docker
# syntax=docker/dockerfile:1
|
|
|
|
# build stage
|
|
FROM ghcr.io/linuxserver/baseimage-alpine:arm64v8-3.23 AS plugins
|
|
|
|
RUN \
|
|
echo "**** install dev deps ****" && \
|
|
apk add --no-cache \
|
|
alpine-sdk \
|
|
discount-dev \
|
|
git \
|
|
glib-dev \
|
|
imagemagick \
|
|
imagemagick-svg \
|
|
json-glib-dev \
|
|
libgcrypt-dev \
|
|
libpng-dev \
|
|
libqrencode-dev \
|
|
libwebp-dev \
|
|
nss-dev \
|
|
openssl-dev \
|
|
pidgin-dev && \
|
|
mkdir /buildout
|
|
|
|
RUN \
|
|
echo "**** grab telegram plugin source ****" && \
|
|
TELEGRAM_RELEASE=$(curl -sX GET "https://api.github.com/repos/majn/telegram-purple/releases/latest" \
|
|
| awk '/tag_name/{print $4;exit}' FS='[""]') && \
|
|
git clone https://github.com/majn/telegram-purple.git && \
|
|
cd telegram-purple && \
|
|
git checkout ${TELEGRAM_RELEASE} && \
|
|
git submodule update --init --recursive
|
|
|
|
RUN \
|
|
echo "**** build telegram plugin ****" && \
|
|
cd /telegram-purple && \
|
|
./configure \
|
|
--prefix=/usr && \
|
|
make && \
|
|
make DESTDIR="/buildout" install
|
|
|
|
RUN \
|
|
echo "**** grab discord plugin source ****" && \
|
|
git clone https://github.com/EionRobb/purple-discord.git
|
|
|
|
RUN \
|
|
echo "**** build discord plugin ****" && \
|
|
cd /purple-discord && \
|
|
make && \
|
|
make DESTDIR="/buildout" install
|
|
|
|
RUN \
|
|
echo "**** grab slack plugin source ****" && \
|
|
git clone https://github.com/EionRobb/slack-libpurple.git
|
|
|
|
RUN \
|
|
echo "**** build discord plugin ****" && \
|
|
cd /slack-libpurple && \
|
|
make && \
|
|
make DESTDIR="/buildout" install
|
|
|
|
RUN \
|
|
echo "**** grab skype plugin source ****" && \
|
|
SKYPE_RELEASE=$(curl -sX GET "https://api.github.com/repos/EionRobb/skype4pidgin/releases/latest" \
|
|
| awk '/tag_name/{print $4;exit}' FS='[""]') && \
|
|
git clone https://github.com/EionRobb/skype4pidgin.git && \
|
|
cd skype4pidgin && \
|
|
git checkout ${SKYPE_RELEASE}
|
|
|
|
RUN \
|
|
echo "**** build skype plugin ****" && \
|
|
cd /skype4pidgin/skypeweb && \
|
|
make && \
|
|
make DESTDIR="/buildout" install
|
|
|
|
RUN \
|
|
echo "**** grab ICQ wim source ****" && \
|
|
git clone https://github.com/EionRobb/icyque.git
|
|
|
|
RUN \
|
|
echo "**** build ICQ wim plugin ****" && \
|
|
cd /icyque && \
|
|
make && \
|
|
make DESTDIR="/buildout" install
|
|
|
|
RUN \
|
|
echo "**** grab rocketchat source ****" && \
|
|
git clone https://github.com/EionRobb/purple-rocketchat.git
|
|
|
|
RUN \
|
|
echo "**** build rocketchat plugin ****" && \
|
|
cd /purple-rocketchat && \
|
|
make && \
|
|
make DESTDIR="/buildout" install
|
|
|
|
RUN \
|
|
echo "**** grab instagram source ****" && \
|
|
git clone https://github.com/EionRobb/purple-instagram.git
|
|
|
|
RUN \
|
|
echo "**** build instagram plugin ****" && \
|
|
cd /purple-instagram && \
|
|
make && \
|
|
make DESTDIR="/buildout" install
|
|
|
|
# runtime stage
|
|
FROM ghcr.io/linuxserver/baseimage-selkies:arm64v8-alpine323
|
|
|
|
# set version label
|
|
ARG BUILD_DATE
|
|
ARG VERSION
|
|
ARG PIDGIN_VERSION
|
|
LABEL build_version="Linuxserver.io version:- ${VERSION} Build-date:- ${BUILD_DATE}"
|
|
LABEL maintainer="thelamer"
|
|
|
|
# title
|
|
ENV TITLE=Pidgin \
|
|
NO_FULL=true
|
|
|
|
# copy over all plugin libs
|
|
COPY --from=plugins /buildout/ /
|
|
|
|
RUN \
|
|
echo "**** add icon ****" && \
|
|
curl -o \
|
|
/usr/share/selkies/www/icon.png \
|
|
https://raw.githubusercontent.com/linuxserver/docker-templates/master/linuxserver.io/img/pidgin-logo.png && \
|
|
echo "**** install packages ****" && \
|
|
if [ -z ${PIDGIN_VERSION+x} ]; then \
|
|
PIDGIN_VERSION=$(curl -sL "http://dl-cdn.alpinelinux.org/alpine/v3.23/community/x86_64/APKINDEX.tar.gz" | tar -xz -C /tmp \
|
|
&& awk '/^P:pidgin$/,/V:/' /tmp/APKINDEX | sed -n 2p | sed 's/^V://'); \
|
|
fi && \
|
|
apk add --no-cache \
|
|
discount \
|
|
firefox \
|
|
libqrencode \
|
|
libwebp \
|
|
nss \
|
|
pidgin==${PIDGIN_VERSION} \
|
|
pidgin-lang \
|
|
pidgin-otr \
|
|
pidgin-otr-lang \
|
|
pidgin-sipe \
|
|
pidgin-sipe-lang \
|
|
purple-carbons \
|
|
purple-lurch \
|
|
purple-xmpp-http-upload && \
|
|
apk add --no-cache --repository=http://dl-cdn.alpinelinux.org/alpine/edge/testing \
|
|
purple-facebook \
|
|
purple-hangouts && \
|
|
echo "**** cleanup ****" && \
|
|
rm -rf \
|
|
/tmp/*
|
|
|
|
# add local files
|
|
COPY /root /
|
|
|
|
# ports and volumes
|
|
EXPOSE 3001
|
|
|
|
VOLUME /config
|