diff --git a/Dockerfile b/Dockerfile deleted file mode 100644 index 1758702..0000000 --- a/Dockerfile +++ /dev/null @@ -1,46 +0,0 @@ -FROM ubuntu:latest - -# install chaperone -RUN set -x \ - && apt-get update \ - && apt-get install -y --no-install-recommends \ - python3 python3-pip python3-dev python3-setuptools \ - && pip3 install chaperone \ - && mkdir /etc/chaperone.d - -# install the dependencies we need for scrapy + scrapyd -RUN set -x \ - && apt-get update \ - && apt-get install -y --no-install-recommends \ - python python-dev python-pip \ - libssl-dev libxml2-dev libxslt-dev libffi-dev \ - build-essential - -# install scrapyd -ADD requirements.txt / -RUN pip3 install -r requirements.txt - -# remove the stuff we dont need to keep around -RUN apt-get remove -y \ - python-dev \ - libssl-dev libxml2-dev libxslt-dev libffi-dev \ - build-essential - -# install nginx and apache2-utils for htpasswd -RUN apt-get update && apt-get install --no-install-recommends -y \ - nginx apache2-utils - -VOLUME /scrapyd - -RUN pip3 install --upgrade setuptools - -RUN mkdir /app -ADD scrapy.cfg /app/scrapy.cfg -ADD findthatcharity_import /app/findthatcharity_import/ -ADD scrapyd.conf /etc/scrapyd/scrapyd.conf -ADD nginx.conf /etc/nginx/sites-enabled/default -ADD chaperone.conf /etc/chaperone.d/chaperone.conf - -EXPOSE 6801 - -ENTRYPOINT ["/usr/local/bin/chaperone"] \ No newline at end of file diff --git a/chaperone.conf b/chaperone.conf deleted file mode 100644 index 1a6194e..0000000 --- a/chaperone.conf +++ /dev/null @@ -1,19 +0,0 @@ -dependencies.service: - command: /bin/bash -c "pip3 install ${PACKAGES//,/ }" - type: oneshot - -password.service: - command: htpasswd -b -c /etc/nginx/htpasswd $(USERNAME:?You need to supply a USERNAME environment variable) $(PASSWORD:?You need to supply a PASSWORD environment variable) - type: oneshot - -nginx.service: - command: service nginx start - restart: true - after: "scrapyd.service" - -scrapyd.service: - command: scrapyd - after: "dependencies.service,password.service" - -console.logging: - stdout: true \ No newline at end of file diff --git a/findthatcharity_import/pipelines/__init__.py b/findthatcharity_import/pipelines/__init__.py new file mode 100644 index 0000000..e69de29 diff --git a/nginx.conf b/nginx.conf deleted file mode 100644 index d6ee17d..0000000 --- a/nginx.conf +++ /dev/null @@ -1,11 +0,0 @@ - -server { - listen 6801; - location / { - proxy_pass http://localhost:6800/; - proxy_redirect off; - proxy_set_header Authorization ""; - auth_basic "Restricted"; - auth_basic_user_file /etc/nginx/htpasswd; - } -} \ No newline at end of file diff --git a/scrapyd.conf b/scrapyd.conf deleted file mode 100644 index 06ac945..0000000 --- a/scrapyd.conf +++ /dev/null @@ -1,7 +0,0 @@ -[scrapyd] -bind_address= 127.0.0.1 -http_port = 6800 -eggs_dir = /scrapyd/eggs -logs_dir = /scrapyd/logs -# items_dir = /scrapyd/items -dbs_dir = /scrapyd/dbs \ No newline at end of file