lerobot-visualizer-v3 / Dockerfile
HCHoongChing's picture
Create Dockerfile
802542e verified
FROM node:18-slim
# Install apt dependencies
RUN apt-get update && apt-get install -y --no-install-recommends \
build-essential \
cmake \
git \
wget \
ca-certificates \
libglib2.0-0 \
libgl1-mesa-glx \
libegl1-mesa \
ffmpeg \
&& apt-get clean && rm -rf /var/lib/apt/lists/*
# Clone the repository with depth 1 (shallow clone)
RUN git clone https://github.com/cortexairobot/lerobot-dataset-visualizer.git /lerobot-dataset-visualizer
RUN cd /lerobot-dataset-visualizer && git switch private-viewer-v3
# Change to the HTML visualizer directory
WORKDIR /lerobot-dataset-visualizer
# Install dependencies
RUN npm ci
# Build the application
RUN npm run build
# Expose port 7860
EXPOSE 7860
# Set environment variable for port
ENV PORT=7860
# Start the application
CMD ["npm", "start"]