Download Dockerfile from D300274/IDE: direct link, hf CLI and curl.
- Browser
- Download file 1.09 kB
-
https://huggingface.co/spaces/D300274/IDE/resolve/main/Dockerfile
- Command line
-
hf download hf://spaces/D300274/IDE/Dockerfile
-
curl -L -o Dockerfile https://huggingface.co/spaces/D300274/IDE/resolve/main/Dockerfile
1.09 kB
| FROM debian:bookworm-slim | |
| # Prevent prompts | |
| ENV DEBIAN_FRONTEND=noninteractive | |
| # Install core dependencies | |
| RUN apt-get update && apt-get install -y \ | |
| curl \ | |
| wget \ | |
| git \ | |
| python3 \ | |
| python3-pip \ | |
| sudo \ | |
| lsb-release \ | |
| net-tools \ | |
| &> /dev/null | |
| # Install code-server (The Agent's Interface) | |
| RUN curl -fsSL https://code-server.dev/install.sh | sh | |
| # Install Cloudflared (The Tunnel) | |
| RUN curl -L --output cloudflared.deb https://github.com/cloudflare/cloudflared/releases/latest/download/cloudflared-linux-amd64.deb && \ | |
| dpkg -i cloudflared.deb && \ | |
| rm cloudflared.deb | |
| # Create a non-root user 'puppet' for HF compliance | |
| RUN useradd -m -s /bin/bash puppet && \ | |
| echo "puppet ALL=(ALL) NOPASSWD:ALL" >> /etc/sudoers | |
| USER puppet | |
| WORKDIR /home/puppet | |
| # Prepare Agent workspace | |
| RUN mkdir -p /home/puppet/agent_workspace | |
| # Copy the orchestration script | |
| COPY --chown=puppet:puppet entrypoint.sh /home/puppet/entrypoint.sh | |
| RUN chmod +x /home/puppet/entrypoint.sh | |
| # HF Spaces default port is 7860 | |
| EXPOSE 7860 | |
| ENTRYPOINT ["/home/puppet/entrypoint.sh"] |