-
Notifications
You must be signed in to change notification settings - Fork 125
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #501 from sumpfork/dockerfile
Initial Dockerfile
- Loading branch information
Showing
3 changed files
with
63 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
.dockerignore | ||
.dockerfile | ||
README.md | ||
requirements.txt | ||
.github | ||
tools | ||
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
FROM python:3.9-slim AS compile-image | ||
|
||
# get fonts | ||
COPY --from=pacodrokad/fonts /fonts /fonts | ||
|
||
# Add git for hooks | ||
RUN apt-get update && apt-get install -y --no-install-recommends git | ||
|
||
# get pip tools for computing requirements, and compile them | ||
RUN python -m pip install pip-tools | ||
|
||
# Set the working directory in the container (creating it in the process) | ||
WORKDIR /app | ||
|
||
# compile our requirements and then install them | ||
COPY requirements.in . | ||
RUN pip-compile --no-emit-index-url requirements.in && \ | ||
pip install -r requirements.txt | ||
|
||
# Copy the local directory contents into the container at /app | ||
COPY . . | ||
|
||
# install the application | ||
RUN python setup.py develop | ||
|
||
ENTRYPOINT ["/usr/local/bin/dominion_dividers"] | ||
CMD ["--help"] |