Supertictactoe / Dockerfile
ausername-12345
Run as root (HF Spaces default) so /data storage bucket is writable
372b670
Raw
History Blame Contribute Delete
413 Bytes
FROM node:20-alpine
WORKDIR /app
# Copy package files and install dependencies
COPY package*.json ./
RUN npm ci --omit=dev
# Copy application files
COPY server.js ./
COPY public/ ./public/
COPY ai/ ./ai/
# Hugging Face Spaces runs containers as root by default,
# which gives us write access to the /data persistent storage bucket
CMD ["node", "server.js"]
EXPOSE 7860
ENV PORT=7860
ENV NODE_ENV=production