Archived
1
0
Fork 0

Prosody: Replace hg with curl

a more efficient way to get prosody. Thanks to zash
This commit is contained in:
Joerg Elfring 2019-01-01 18:29:15 +01:00
parent e8f2bfddc3
commit d1ad412c59

View file

@ -15,30 +15,42 @@ RUN apk add --no-cache \
## Install build envirnoment, build and remove unneeded things ## Install build envirnoment, build and remove unneeded things
## This is done in one step to reduce image size ## This is done in one step to reduce image size
RUN apk add --update \ RUN set -x \
--no-cache \ ##
--virtual .build-deps \ ## Build Environment
alpine-sdk \ && apk add --update \
mercurial \ --no-cache \
libidn-dev \ --virtual .build-deps \
linux-headers \ alpine-sdk \
lua5.2-busted \ libidn-dev \
lua5.2-dev \ linux-headers \
openssl-dev \ lua5.2-busted \
&& set -x \ lua5.2-dev \
openssl-dev \
&& ln -s /usr/bin/busted-5.2 /usr/local/bin/busted \ && ln -s /usr/bin/busted-5.2 /usr/local/bin/busted \
&& hg clone https://hg.prosody.im/0.11 /prosody-src \ ##
&& cd /prosody-src \ ## Prosody
&& curl --silent --output /prosody-trunk.tar.gz "https://hg.prosody.im/trunk/archive/0.11.tar.gz" \
&& mkdir /prosody-src \
&& cd /prosody-src \
&& tar xzf /prosody-trunk.tar.gz --strip 1 \
&& ./configure --no-example-certs \ && ./configure --no-example-certs \
--cflags='-fPIC -Wall -std=c99 -pedantic -DWITHOUT_MALLINFO' \ --cflags='-fPIC -Wall -std=c99 -pedantic -DWITHOUT_MALLINFO' \
&& make \ && make \
&& make test \ && make test \
&& make install \ && make install \
&& cd / \ && cd / \
##
## Prosody Community Modules
&& curl --silent --output /prosody-modules.tar.gz "https://hg.prosody.im/prosody-modules/archive/default.tar.gz" \
&& mkdir /usr/local/lib/prosody-community-modules \
&& cd /usr/local/lib/prosody-community-modules \
&& tar xzf /prosody-modules.tar.gz --strip 1 \
##
## Cleanup
&& rm -rf /prosody-src \ && rm -rf /prosody-src \
&& hg clone https://hg.prosody.im/prosody-modules/ /usr/local/lib/prosody-community-modules \ && rm -f /prosody-src.tar.gz \
&& rm -rf /usr/local/lib/prosody-community-modules/.hg \ && rm -f /prosody-modules.tar.gz \
&& rm -rf /usr/local/lib/prosody-community-modules/.hgtags \
&& rm -f /usr/local/bin/busted \ && rm -f /usr/local/bin/busted \
&& apk del .build-deps && apk del .build-deps