mirror of
https://github.com/marcogll/AnchorOS.git
synced 2026-03-15 22:24:34 +00:00
- Move Resend client instantiation from module level to function - Add validation to skip placeholder API keys - Set empty RESEND_API_KEY and GOOGLE_SERVICE_ACCOUNT_JSON during build
37 lines
683 B
Docker
37 lines
683 B
Docker
# Dockerfile simplificado para Coolify
|
|
FROM node:20-alpine
|
|
|
|
WORKDIR /app
|
|
|
|
# Instalar dependencias
|
|
COPY package.json package-lock.json ./
|
|
RUN npm ci --ignore-scripts
|
|
|
|
# Copiar código fuente
|
|
COPY . .
|
|
|
|
# Variables de entorno
|
|
ENV NEXT_TELEMETRY_DISABLED=1
|
|
ENV NODE_ENV=production
|
|
ENV NEXT_PUBLIC_SUPABASE_URL=https://placeholder.supabase.co
|
|
ENV NEXT_PUBLIC_SUPABASE_ANON_KEY=placeholder-anon-key
|
|
|
|
# Aumentar memoria para build
|
|
ENV NODE_OPTIONS="--max-old-space-size=4096"
|
|
|
|
# Build
|
|
RUN npm run build
|
|
|
|
# Configurar usuario
|
|
RUN addgroup --system --gid 1001 nodejs
|
|
RUN adduser --system --uid 1001 nextjs
|
|
|
|
USER nextjs
|
|
|
|
EXPOSE 3000
|
|
|
|
ENV PORT=3000
|
|
ENV HOSTNAME="0.0.0.0"
|
|
|
|
CMD ["npm", "start"]
|