Hemang Thakur commited on
Commit
24d8240
·
1 Parent(s): 447e5a4

updated dockerfile

Browse files
Files changed (1) hide show
  1. Dockerfile +4 -0
Dockerfile CHANGED
@@ -67,6 +67,10 @@ COPY . .
67
  # Copy the built React app from the builder stage into the same folder structure as used in your FastAPI code
68
  COPY --from=builder /app/frontend/build ./frontend/build
69
 
 
 
 
 
70
  # Expose the port
71
  EXPOSE ${PORT:-7860}
72
 
 
67
  # Copy the built React app from the builder stage into the same folder structure as used in your FastAPI code
68
  COPY --from=builder /app/frontend/build ./frontend/build
69
 
70
+ # Run HuggingFace Spaces as a root user
71
+ RUN useradd -m spaces-user && chown -R spaces-user:spaces-user /tmp/huggingface /app/workspace
72
+ USER spaces-user
73
+
74
  # Expose the port
75
  EXPOSE ${PORT:-7860}
76