mirror of
https://github.com/webrecorder/pywb.git
synced 2025-03-14 15:53:28 +01:00
* js rewriting: default to moden js-proxy based rewriting by default, use legacy rewriting only if browsers are older than minimum, as suggested in #707 * user-agent detection: use ua_parser for user-agent detection instead of obsolete werkzeug.useragent, which also did not support browsers >=100 * tests: additional tests for rewriting with various user-agents, defaulting to new-style rewriting for unknown browsers * dockerfile: Update Dockerfile to use py3.8 * tests: skip s3 tests dependent on commoncrawl data (for now, need better s3 tests). * bump to 2.6.6, update CHANGES
35 lines
619 B
Docker
Executable File
35 lines
619 B
Docker
Executable File
ARG PYTHON=python:3.8
|
|
|
|
FROM $PYTHON
|
|
|
|
WORKDIR /pywb
|
|
|
|
COPY requirements.txt extra_requirements.txt ./
|
|
|
|
RUN pip install --no-cache-dir -r requirements.txt -r extra_requirements.txt
|
|
|
|
COPY . ./
|
|
|
|
RUN python setup.py install \
|
|
&& mv ./docker-entrypoint.sh / \
|
|
&& mkdir /uwsgi && mv ./uwsgi.ini /uwsgi/ \
|
|
&& mkdir /webarchive && mv ./config.yaml /webarchive/
|
|
|
|
WORKDIR /webarchive
|
|
|
|
# auto init collection
|
|
ENV INIT_COLLECTION ''
|
|
|
|
ENV VOLUME_DIR /webarchive
|
|
|
|
#USER archivist
|
|
COPY docker-entrypoint.sh ./
|
|
|
|
# volume and port
|
|
VOLUME /webarchive
|
|
EXPOSE 8080
|
|
|
|
ENTRYPOINT ["/docker-entrypoint.sh"]
|
|
CMD ["uwsgi", "/uwsgi/uwsgi.ini"]
|
|
|