Fetch application from PyPI instead of local
setuptools_scm barfs because it can't find the version, because Docker hub retrieves the application from Github in a way that omits the necessary details. I suppose there is a certain logic to Docker only using the tagged released versions from PyPI, so go with it. The other attractive option is to nix setuptools_scm.
This commit is contained in:
+1
-3
@@ -41,13 +41,11 @@ RUN rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/* /root/*
|
||||
RUN pyvenv /appenv \
|
||||
&& pyvenv --system-site-packages /appenv
|
||||
|
||||
COPY . /application/
|
||||
|
||||
# Install application and dependencies
|
||||
# In this arrangement Pillow and reportlab will be provided by the system
|
||||
RUN . /appenv/bin/activate; \
|
||||
pip install --upgrade pip \
|
||||
&& pip install --no-cache-dir /application \
|
||||
&& pip install ocrmypdf \
|
||||
&& pip install --no-cache-dir -r /application/test_requirements.txt
|
||||
|
||||
USER docker
|
||||
|
||||
Reference in New Issue
Block a user