Spaces:
Sleeping
Sleeping
ftshijt
commited on
Commit
·
58914ff
1
Parent(s):
02afb34
set port for docker
Browse files- Dockerfile +5 -1
- app.py +1 -1
Dockerfile
CHANGED
|
@@ -19,7 +19,7 @@ RUN pip install --no-cache-dir -U pip && \
|
|
| 19 |
pip install --no-cache-dir -r requirements.txt
|
| 20 |
|
| 21 |
# Clone VERSA repository
|
| 22 |
-
RUN git clone https://github.com/
|
| 23 |
cd versa && \
|
| 24 |
pip install -e .
|
| 25 |
|
|
@@ -35,6 +35,10 @@ COPY app.py .
|
|
| 35 |
# Create installation complete indicator
|
| 36 |
RUN touch /app/versa/.installation_complete
|
| 37 |
|
|
|
|
|
|
|
|
|
|
|
|
|
| 38 |
# Set environment variables
|
| 39 |
ENV PYTHONUNBUFFERED=1
|
| 40 |
|
|
|
|
| 19 |
pip install --no-cache-dir -r requirements.txt
|
| 20 |
|
| 21 |
# Clone VERSA repository
|
| 22 |
+
RUN git clone https://github.com/wavlab-speech/versa.git && \
|
| 23 |
cd versa && \
|
| 24 |
pip install -e .
|
| 25 |
|
|
|
|
| 35 |
# Create installation complete indicator
|
| 36 |
RUN touch /app/versa/.installation_complete
|
| 37 |
|
| 38 |
+
# Set port
|
| 39 |
+
EXPOSE 7860
|
| 40 |
+
ENV GRADIO_SERVER_NAME="0.0.0.0"
|
| 41 |
+
|
| 42 |
# Set environment variables
|
| 43 |
ENV PYTHONUNBUFFERED=1
|
| 44 |
|
app.py
CHANGED
|
@@ -524,4 +524,4 @@ def create_gradio_demo():
|
|
| 524 |
if __name__ == "__main__":
|
| 525 |
demo = create_gradio_demo()
|
| 526 |
# Use 0.0.0.0 to listen on all interfaces, which is required for Docker
|
| 527 |
-
demo.launch(server_name="0.0.0.0", server_port=7860)
|
|
|
|
| 524 |
if __name__ == "__main__":
|
| 525 |
demo = create_gradio_demo()
|
| 526 |
# Use 0.0.0.0 to listen on all interfaces, which is required for Docker
|
| 527 |
+
demo.launch(server_name="0.0.0.0", server_port=7860, share=True, allow_flagging=False)
|