2015-12-10 19:30:03 +01:00
|
|
|
#
|
2016-08-19 19:04:33 +02:00
|
|
|
# This Dockerfile builds a recent curl with HTTP/2 client support, using
|
|
|
|
# a recent nghttp2 build.
|
2015-12-10 19:30:03 +01:00
|
|
|
#
|
2016-08-19 19:04:33 +02:00
|
|
|
# See the Makefile for how to tag it. If Docker and that image is found, the
|
|
|
|
# Go tests use this curl binary for integration tests.
|
|
|
|
#
|
|
|
|
|
2018-07-13 22:13:48 +02:00
|
|
|
FROM alpine:latest
|
2016-08-19 19:04:33 +02:00
|
|
|
|
|
|
|
RUN apk add --no-cache \
|
|
|
|
ca-certificates \
|
|
|
|
nghttp2 \
|
|
|
|
openssl
|
|
|
|
|
2019-07-24 23:54:24 +02:00
|
|
|
ENV CURL_VERSION 7.65.3
|
2015-12-10 19:30:03 +01:00
|
|
|
|
2016-08-19 19:04:33 +02:00
|
|
|
RUN set -x \
|
|
|
|
&& apk add --no-cache --virtual .build-deps \
|
|
|
|
g++ \
|
|
|
|
make \
|
|
|
|
nghttp2-dev \
|
|
|
|
openssl-dev \
|
|
|
|
perl \
|
2019-09-16 20:36:11 +02:00
|
|
|
gnupg \
|
2016-08-19 19:04:33 +02:00
|
|
|
&& wget https://curl.haxx.se/download/curl-$CURL_VERSION.tar.bz2 \
|
2019-09-16 20:36:11 +02:00
|
|
|
&& wget https://curl.haxx.se/download/curl-$CURL_VERSION.tar.bz2.asc \
|
|
|
|
&& gpg --keyserver ha.pool.sks-keyservers.net --recv-keys 27EDEAF22F3ABCEB50DB9A125CC908FDB71E12C2 \
|
|
|
|
&& gpg --verify curl-$CURL_VERSION.tar.bz2.asc \
|
2016-08-19 19:04:33 +02:00
|
|
|
&& tar xjvf curl-$CURL_VERSION.tar.bz2 \
|
|
|
|
&& rm curl-$CURL_VERSION.tar.bz2 \
|
|
|
|
&& ( \
|
|
|
|
cd curl-$CURL_VERSION \
|
|
|
|
&& ./configure \
|
|
|
|
--with-nghttp2=/usr \
|
|
|
|
--with-ssl \
|
|
|
|
--enable-ipv6 \
|
|
|
|
--enable-unix-sockets \
|
|
|
|
--without-libidn \
|
|
|
|
--disable-static \
|
|
|
|
--disable-ldap \
|
|
|
|
--with-pic \
|
|
|
|
&& make \
|
|
|
|
&& make install \
|
|
|
|
) \
|
|
|
|
&& rm -r curl-$CURL_VERSION \
|
|
|
|
&& rm -r /usr/share/man \
|
|
|
|
&& apk del .build-deps
|
2015-12-10 19:30:03 +01:00
|
|
|
|
2016-08-19 19:04:33 +02:00
|
|
|
ENTRYPOINT ["/usr/local/bin/curl"]
|
|
|
|
CMD ["-h"]
|