chore(build): fix broken build logic
Standardizes project structure so the dockerbuild works
This commit is contained in:
parent
688217f3cd
commit
fa959332cb
12
Dockerfile
12
Dockerfile
@ -19,10 +19,10 @@ ENV PATH="$POETRY_HOME/bin:$PATH"
|
||||
|
||||
RUN curl -sSL https://install.python-poetry.org | python3 -
|
||||
|
||||
COPY ./data ./data
|
||||
COPY ./cv_analysis ./cv_analysis
|
||||
COPY ./scripts ./scripts
|
||||
COPY pyproject.toml poetry.lock ./src ./
|
||||
COPY ./src ./src
|
||||
COPY ./config ./config
|
||||
COPY pyproject.toml poetry.lock ./
|
||||
|
||||
|
||||
RUN ls -hal
|
||||
RUN echo "${USERNAME} ${TOKEN} ${PYPI_REGISTRY_RED} ${POETRY_SOURCE_REF_RED} "
|
||||
@ -33,9 +33,9 @@ RUN poetry config virtualenvs.create false && \
|
||||
poetry config http-basic.${POETRY_SOURCE_REF_RESEARCH} ${USERNAME} ${TOKEN} && \
|
||||
poetry config repositories.${POETRY_SOURCE_REF_RED} ${PYPI_REGISTRY_RED} && \
|
||||
poetry config http-basic.${POETRY_SOURCE_REF_RED} ${USERNAME} ${TOKEN} && \
|
||||
poetry install --without=test -vv --no-interaction --no-root
|
||||
poetry install --without=test -vv --no-interaction
|
||||
|
||||
EXPOSE 5000
|
||||
EXPOSE 8080
|
||||
|
||||
CMD [ "python", "serve.py"]
|
||||
CMD [ "python", "src/serve.py"]
|
||||
|
||||
@ -4,7 +4,7 @@ version = "2.0.0"
|
||||
description = ""
|
||||
authors = []
|
||||
readme = "README.md"
|
||||
packages = [{ include = "cv_analysis" }]
|
||||
packages = [{ include = "cv_analysis", from = "src" }]
|
||||
|
||||
[tool.poetry.dependencies]
|
||||
python = ">=3.10,<3.11"
|
||||
|
||||
@ -1,16 +1,13 @@
|
||||
import argparse
|
||||
import timeit
|
||||
from time import process_time
|
||||
from itertools import starmap
|
||||
from pathlib import Path
|
||||
|
||||
from PIL import Image
|
||||
from funcy import lmap
|
||||
|
||||
from cv_analysis.figure_detection.figure_detection import detect_figures
|
||||
from cv_analysis.layout_parsing import parse_layout
|
||||
from cv_analysis.table_parsing import parse_tables
|
||||
from cv_analysis.utils.draw import draw_rectangles
|
||||
from funcy import lmap
|
||||
from itertools import starmap
|
||||
from pathlib import Path
|
||||
from pdf2img.conversion import convert_pages_to_images
|
||||
|
||||
|
||||
|
||||
@ -4,6 +4,6 @@ from pyinfra.config.loader import load_settings
|
||||
|
||||
|
||||
def get_config():
|
||||
local_root_path = Path(__file__).parents[1]
|
||||
local_root_path = Path(__file__).parents[2]
|
||||
settings = load_settings(root_path=local_root_path, settings_path="config")
|
||||
return settings
|
||||
@ -1,6 +1,5 @@
|
||||
from sys import stdout
|
||||
|
||||
import IPython
|
||||
from kn_utils.logging import logger
|
||||
from pyinfra.examples import start_standard_queue_consumer
|
||||
from pyinfra.queue.callback import make_download_process_upload_callback
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user