Download Dockerfile from mnpx/hostb: direct link, hf CLI and curl.
- Browser
- Download file 1.15 kB
-
https://huggingface.co/spaces/mnpx/hostb/resolve/main/Dockerfile
- Command line
-
hf download hf://spaces/mnpx/hostb/Dockerfile
-
curl -L -o Dockerfile https://huggingface.co/spaces/mnpx/hostb/resolve/main/Dockerfile
1.15 kB
| FROM golang:1.24 AS builder | |
| RUN git clone https://gitlab.torproject.org/tpo/anti-censorship/pluggable-transports/snowflake.git /snowflake && \ | |
| cd /snowflake && \ | |
| echo "=== Directory listing ===" && \ | |
| ls -la && \ | |
| echo "=== CMD folder ===" && \ | |
| ls -la cmd/ 2>/dev/null || echo "No cmd folder" && \ | |
| echo "=== Looking for main packages ===" && \ | |
| find . -name "main.go" | head -10 && \ | |
| echo "=== Building... ===" && \ | |
| go build -o /usr/local/bin/snowflake-proxy ./cmd/snowflake-proxy || \ | |
| go build -o /usr/local/bin/snowflake-proxy ./cmd/proxy || \ | |
| go build -o /usr/local/bin/snowflake-proxy ./proxy || \ | |
| echo "Build failed - no main found" | |
| FROM ubuntu:22.04 | |
| RUN apt-get update && apt-get install -y --no-install-recommends \ | |
| ca-certificates \ | |
| python3 \ | |
| python3-pip \ | |
| && rm -rf /var/lib/apt/lists/* \ | |
| && pip3 install --no-cache-dir fastapi uvicorn | |
| COPY --from=builder /usr/local/bin/snowflake-proxy /usr/local/bin/ | |
| WORKDIR /app | |
| COPY app.py . | |
| EXPOSE 7860 | |
| CMD ["sh", "-c", "snowflake-proxy -verbose -relay https://snowflake.torproject.org/ & uvicorn app:app --host 0.0.0.0 --port 7860"] |