File size: 1,131 Bytes
f9f9da6 | 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 | FROM node:24-slim
# 1. Instalar dependencias del sistema vitales
RUN apt-get update && apt-get install -y curl bash git python3 python3-pip && rm -rf /var/lib/apt/lists/*
# 2. Preparar directorios y permisos para Hugging Face (UID 1000)
RUN mkdir -p /data/openchamber /data/opencode/share /data/opencode/config /data/ssh /workspace
RUN chown -R node:node /data /workspace
# 3. Cambiar al usuario sin privilegios requerido por Hugging Face
USER node
WORKDIR /workspace
# 4. Configurar el PATH para los binarios globales
ENV NPM_CONFIG_PREFIX=/home/node/.npm-global
ENV PATH=$PATH:/home/node/.npm-global/bin:/home/node/.local/bin
# 5. Instalar OpenCode CLI con el nombre de paquete correcto
RUN npm install -g opencode-ai
RUN npm install -g hevy-mcp yazio-mcp
# 7. Instalación oficial de OpenChamber vía script
RUN curl -fsSL https://raw.githubusercontent.com/btriapitsyn/openchamber/main/scripts/install.sh | bash
# 8. Variables de entorno y arranque
EXPOSE 7860
# Iniciar OpenChamber expuesto a todas las interfaces y en el puerto de HF
CMD ["openchamber", "serve", "--port", "7860", "--host", "0.0.0.0", "--foreground"] |