Update Dockerfile
Browse files- Dockerfile +7 -4
Dockerfile
CHANGED
|
@@ -2,18 +2,21 @@ FROM node:18-alpine
|
|
| 2 |
|
| 3 |
WORKDIR /app
|
| 4 |
|
| 5 |
-
# Install git
|
| 6 |
RUN apk add --no-cache git
|
| 7 |
|
| 8 |
# Clone specific version
|
| 9 |
-
RUN git clone --branch v1.11.2 https://github.com/ItzCrazyKns/Vane.git .
|
| 10 |
|
| 11 |
-
# Install
|
| 12 |
RUN npm install
|
| 13 |
|
| 14 |
-
#
|
|
|
|
|
|
|
|
|
|
| 15 |
ENV PORT=7860
|
| 16 |
ENV HOSTNAME=0.0.0.0
|
|
|
|
| 17 |
|
| 18 |
EXPOSE 7860
|
| 19 |
|
|
|
|
| 2 |
|
| 3 |
WORKDIR /app
|
| 4 |
|
|
|
|
| 5 |
RUN apk add --no-cache git
|
| 6 |
|
| 7 |
# Clone specific version
|
| 8 |
+
RUN git clone --depth 1 --branch v1.11.2 https://github.com/ItzCrazyKns/Vane.git .
|
| 9 |
|
| 10 |
+
# Install deps
|
| 11 |
RUN npm install
|
| 12 |
|
| 13 |
+
# Build Next.js app (CRITICAL)
|
| 14 |
+
RUN npm run build
|
| 15 |
+
|
| 16 |
+
# Spaces requirements
|
| 17 |
ENV PORT=7860
|
| 18 |
ENV HOSTNAME=0.0.0.0
|
| 19 |
+
ENV NODE_ENV=production
|
| 20 |
|
| 21 |
EXPOSE 7860
|
| 22 |
|