1
2
mirror of https://github.com/vimagick/dockerfiles synced 2024-06-25 00:08:49 +00:00

add pillow to scrapyd to handle images

This commit is contained in:
kev 2016-05-26 20:30:59 +08:00
parent f2bd0904bd
commit d05e246d0c
2 changed files with 25 additions and 2 deletions

@ -5,7 +5,8 @@
FROM debian:jessie
MAINTAINER kev <noreply@easypi.info>
RUN apt-get update \
RUN set -xe \
&& apt-get update \
&& apt-get install -y autoconf \
build-essential \
curl \
@ -16,6 +17,17 @@ RUN apt-get update \
python \
python-dev \
vim-tiny \
&& apt-get install -y libtiff5 \
libtiff5-dev \
libfreetype6-dev \
libjpeg62-turbo \
libjpeg62-turbo-dev \
liblcms2-2 \
liblcms2-dev \
libwebp5 \
libwebp-dev \
zlib1g \
zlib1g-dev \
&& mkdir libxml2 \
&& curl -sSL ftp://xmlsoft.org/libxml2/libxml2-2.9.2.tar.gz | tar xz --strip 1 -C libxml2 \
&& cd libxml2 \
@ -39,6 +51,7 @@ RUN apt-get update \
git+https://github.com/scrapy/scrapyd.git \
git+https://github.com/scrapy/scrapyd-client.git \
git+https://github.com/scrapinghub/scrapy-splash.git \
git+https://github.com/python-pillow/Pillow.git \
&& curl -sSL https://github.com/scrapy/scrapy/raw/master/extras/scrapy_bash_completion -o /etc/bash_completion.d/scrapy_bash_completion \
&& echo 'source /etc/bash_completion.d/scrapy_bash_completion' >> /root/.bashrc \
&& apt-get purge -y --auto-remove autoconf \
@ -47,9 +60,15 @@ RUN apt-get update \
libssl-dev \
libtool \
python-dev \
&& apt-get purge -y --auto-remove libtiff5-dev \
libfreetype6-dev \
libjpeg62-turbo-dev \
liblcms2-dev \
libwebp-dev \
zlib1g-dev \
&& rm -rf /var/lib/apt/lists/*
ADD ./scrapyd.conf /etc/scrapyd/
COPY ./scrapyd.conf /etc/scrapyd/
VOLUME /etc/scrapyd/ /var/lib/scrapyd/
EXPOSE 6800

@ -14,6 +14,8 @@ utility which allows you to deploy your project to a Scrapyd server.
[ScrapyJS][4] provides Scrapy+JavaScript integration using Splash.
[Pillow][5] is the Python Imaging Library to support the ImagesPipeline.
This image is based on `debian:jessie` without any useless packages installed.
Only 4 latest python packages are installed:
@ -21,6 +23,7 @@ Only 4 latest python packages are installed:
- `scrapyd`: git+https://github.com/scrapy/scrapyd.git
- `scrapyd-client`: git+https://github.com/scrapy/scrapyd-client.git
- `scrapyjs`: git+https://github.com/scrapinghub/scrapy-splash.git
- `pillow`: git+https://github.com/python-pillow/Pillow.git
Please use this image as base for your own project.
@ -66,3 +69,4 @@ $ docker run -it --rm -v `pwd`:/code -w /code vimagick/scrapyd bash
[2]: https://github.com/scrapy/scrapyd
[3]: https://github.com/scrapy/scrapyd-client
[4]: https://github.com/scrapinghub/scrapy-splash
[5]: https://github.com/python-pillow/Pillow