Spaces:
Running
Running
fuxialexander
commited on
Commit
·
d6cd62b
1
Parent(s):
0b8f533
fix docker
Browse files- Dockerfile +8 -8
Dockerfile
CHANGED
@@ -2,7 +2,7 @@
|
|
2 |
FROM mambaorg/micromamba
|
3 |
|
4 |
# Set the working directory in the container to /app
|
5 |
-
WORKDIR /
|
6 |
|
7 |
|
8 |
# Create a new environment using mamba with specified packages
|
@@ -12,33 +12,33 @@ ARG MAMBA_DOCKERFILE_ACTIVATE=1
|
|
12 |
RUN pip3 install gradio
|
13 |
|
14 |
USER root
|
15 |
-
|
16 |
RUN apt-get update && apt-get install -y --no-install-recommends \
|
17 |
git \
|
18 |
ssh \
|
19 |
&& apt-get clean \
|
20 |
&& rm -rf /var/lib/apt/lists/*
|
21 |
-
|
22 |
USER $MAMBA_USER
|
23 |
|
24 |
# copy modules from local to container
|
25 |
-
COPY --chown=$MAMBA_USER:$MAMBA_USER modules /modules
|
26 |
|
27 |
# copy modules from local to container
|
28 |
-
COPY --chown=$MAMBA_USER:$MAMBA_USER app /app
|
29 |
|
30 |
# copy modules from local to container
|
31 |
# COPY --chown=$MAMBA_USER:$MAMBA_USER data /app/data
|
32 |
|
33 |
# Clone a specific git repository and install it as an editable package
|
34 |
-
RUN cd
|
35 |
pip3 install .
|
36 |
|
37 |
-
WORKDIR /
|
38 |
|
39 |
# Make port 80 available to the world outside this container
|
40 |
EXPOSE 7681
|
41 |
# Set the working directory where your app resides
|
42 |
|
43 |
# Command to run the Gradio app automatically
|
44 |
-
CMD ["python", "
|
|
|
2 |
FROM mambaorg/micromamba
|
3 |
|
4 |
# Set the working directory in the container to /app
|
5 |
+
WORKDIR /app
|
6 |
|
7 |
|
8 |
# Create a new environment using mamba with specified packages
|
|
|
12 |
RUN pip3 install gradio
|
13 |
|
14 |
USER root
|
15 |
+
RUN mkdir /data
|
16 |
RUN apt-get update && apt-get install -y --no-install-recommends \
|
17 |
git \
|
18 |
ssh \
|
19 |
&& apt-get clean \
|
20 |
&& rm -rf /var/lib/apt/lists/*
|
21 |
+
|
22 |
USER $MAMBA_USER
|
23 |
|
24 |
# copy modules from local to container
|
25 |
+
COPY --chown=$MAMBA_USER:$MAMBA_USER modules /app/modules
|
26 |
|
27 |
# copy modules from local to container
|
28 |
+
COPY --chown=$MAMBA_USER:$MAMBA_USER app /app/app
|
29 |
|
30 |
# copy modules from local to container
|
31 |
# COPY --chown=$MAMBA_USER:$MAMBA_USER data /app/data
|
32 |
|
33 |
# Clone a specific git repository and install it as an editable package
|
34 |
+
RUN cd modules/proscope && \
|
35 |
pip3 install .
|
36 |
|
37 |
+
WORKDIR /app
|
38 |
|
39 |
# Make port 80 available to the world outside this container
|
40 |
EXPOSE 7681
|
41 |
# Set the working directory where your app resides
|
42 |
|
43 |
# Command to run the Gradio app automatically
|
44 |
+
CMD ["python", "app/main.py", "-p", "7681", "-s", "-d", "/data"]
|