Skip to content

Instantly share code, notes, and snippets.

@gquintard
Created May 3, 2019 23:44
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save gquintard/f3627a2860331efdea0aea356316c2c3 to your computer and use it in GitHub Desktop.
Save gquintard/f3627a2860331efdea0aea356316c2c3 to your computer and use it in GitHub Desktop.
FROM debian:stretch-slim
RUN apt update && \
echo > /etc/apt/sources.list.d/varnish.list deb https://packagecloud.io/varnishcache/varnish62/debian/ stretch main && \
echo >> /etc/apt/sources.list.d/varnish.list deb-src https://packagecloud.io/varnishcache/varnish62/debian/ stretch main && \
apt-get install devscripts dpkg-dev curl gnupg apt-transport-https -y && \
curl -L https://packagecloud.io/varnishcache/varnish62/gpgkey | apt-key add - && \
apt update && \
mkdir /tmp/workdir && \
cd /tmp/workdir && \
apt-get build-dep -y varnish=6.2.0 && \
apt-get source varnish=6.2.0 && \
cd varnish-6.2.0 && \
debuild -b -uc -us
WORKDIR /etc/varnish
COPY docker-varnish-entrypoint /usr/local/bin/
ENTRYPOINT ["docker-varnish-entrypoint"]
EXPOSE 80
CMD ["varnishd", "-F", "-f", "/etc/varnish/default.vcl"]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment