Spaces:
Sleeping
Sleeping
Download frontend/Dockerfile from ApyHTML19/PaperBrainAI: direct link, hf CLI and curl.
- Browser
- Download file 711 Bytes
-
https://huggingface.co/spaces/ApyHTML19/PaperBrainAI/resolve/main/frontend/Dockerfile
- Command line
-
hf download hf://spaces/ApyHTML19/PaperBrainAI/frontend/Dockerfile
-
curl -L -o Dockerfile https://huggingface.co/spaces/ApyHTML19/PaperBrainAI/resolve/main/frontend/Dockerfile
711 Bytes
| FROM node:20-alpine AS builder | |
| WORKDIR /app | |
| ARG VITE_API_URL=http://localhost:8000/api | |
| ENV VITE_API_URL=$VITE_API_URL | |
| COPY package*.json ./ | |
| RUN npm ci | |
| COPY . . | |
| RUN npm run build | |
| # ββ Runtime Nginx βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ | |
| FROM nginx:alpine | |
| COPY --from=builder /app/dist /usr/share/nginx/html | |
| RUN echo 'server { \ | |
| listen 80; \ | |
| root /usr/share/nginx/html; \ | |
| index index.html; \ | |
| location / { \ | |
| try_files $uri $uri/ /index.html; \ | |
| } \ | |
| }' > /etc/nginx/conf.d/default.conf | |
| EXPOSE 80 | |
| CMD ["nginx", "-g", "daemon off;"] |