|
|
|
FROM docker.io/library/python:3.10.13@sha256:d5b1fbbc00fd3b55620a9314222498bebf09c4bf606425bf464709ed6a79f202 |
|
|
|
|
|
WORKDIR /usr/src/app |
|
|
|
|
|
RUN apt-get update && apt-get install -y \ |
|
gcc-11 \ |
|
build-essential \ |
|
ffmpeg \ |
|
libsm6 \ |
|
libxext6 \ |
|
curl \ |
|
git \ |
|
&& apt-get clean \ |
|
&& rm -rf /var/lib/apt/lists/* |
|
|
|
|
|
RUN curl -fsSL https://deb.nodesource.com/setup_16.x | bash - \ |
|
&& apt-get install -y nodejs |
|
|
|
|
|
ENV CC=/usr/bin/gcc-11 |
|
|
|
|
|
COPY . . |
|
|
|
|
|
RUN pip install --no-cache-dir -r requirements.txt |
|
|
|
|
|
WORKDIR /usr/src/app/models/GroundingDINO/ops |
|
|
|
|
|
RUN python setup.py build install |
|
RUN python test.py |
|
|
|
|
|
RUN pip install gradio |
|
|
|
|
|
WORKDIR /usr/src/app |
|
RUN git clone https://github.com/niki-amini-naieni/gradio-image-prompter-visible-boxes.git \ |
|
&& cd gradio-image-prompter-visible-boxes \ |
|
&& npm install \ |
|
&& npm run build |
|
|
|
|
|
WORKDIR /usr/src/app |
|
|
|
|
|
EXPOSE 7860 |
|
|
|
|
|
CMD ["python", "app.py"] |