Merge branch 'master' into master
This commit is contained in:
16
Dockerfile
16
Dockerfile
@@ -1,8 +1,4 @@
|
|||||||
# Bulk Downloader for Reddit
|
FROM python:3.9
|
||||||
#
|
|
||||||
# VERSION 0.0.1
|
|
||||||
|
|
||||||
FROM python:3.8-slim-buster
|
|
||||||
LABEL Description="This image enables running Buld Downloader for Reddit with in a container environment" Version="0.0.1"
|
LABEL Description="This image enables running Buld Downloader for Reddit with in a container environment" Version="0.0.1"
|
||||||
|
|
||||||
ENV PYTHONUNBUFFERED 1
|
ENV PYTHONUNBUFFERED 1
|
||||||
@@ -11,21 +7,21 @@ ENV PYTHONDONTWRITEBYTECODE 1
|
|||||||
EXPOSE 8080
|
EXPOSE 8080
|
||||||
EXPOSE 7634
|
EXPOSE 7634
|
||||||
|
|
||||||
# Install dependencies for building Python packages
|
# Install dependencies
|
||||||
RUN apt-get update \
|
RUN apt-get update \
|
||||||
&& apt-get install -y build-essential \
|
&& apt-get install -y build-essential \
|
||||||
&& apt-get purge -y --auto-remove -o APT::AutoRemove::RecommendsImportant=false \
|
&& apt-get purge -y --auto-remove -o APT::AutoRemove::RecommendsImportant=false \
|
||||||
&& rm -rf /var/lib/apt/lists/*
|
&& rm -rf /var/lib/apt/lists/*
|
||||||
|
|
||||||
# Requirements are installed here to ensure they will be cached.
|
# Python requirements
|
||||||
COPY requirements.txt /requirements.txt
|
COPY requirements.txt /requirements.txt
|
||||||
RUN pip install --no-cache-dir -r /requirements.txt \
|
RUN pip install --no-cache-dir -r /requirements.txt \
|
||||||
&& rm -rf /requirements.txt
|
&& rm -rf /requirements.txt
|
||||||
|
|
||||||
# Copy project files into container
|
# Copy over project files
|
||||||
COPY . /bdfr
|
COPY . /bdfr
|
||||||
WORKDIR /bdfr
|
WORKDIR /bdfr
|
||||||
|
|
||||||
# This is useful because the image name can double as a reference to the binary
|
# Useful so the image doubles as reference to the binary
|
||||||
ENTRYPOINT ["python", "script.py"]
|
ENTRYPOINT ["python", "script.py"]
|
||||||
CMD ["--help"]
|
CMD ["python", "script.py", "-d", "downloads"]
|
||||||
|
|||||||
Reference in New Issue
Block a user