Download Dockerfile from st3v3x/FALCON: direct link, hf CLI and curl.
- Browser
- Download file 954 Bytes
-
https://huggingface.co/spaces/st3v3x/FALCON/resolve/main/Dockerfile
- Command line
-
hf download hf://spaces/st3v3x/FALCON/Dockerfile
-
curl -L -o Dockerfile https://huggingface.co/spaces/st3v3x/FALCON/resolve/main/Dockerfile
954 Bytes
| # Stage 1: Compilación ultraligera en Go | |
| FROM golang:1.24-alpine AS builder | |
| WORKDIR /app | |
| COPY go.mod go.sum ./ | |
| RUN go mod download | |
| COPY . . | |
| RUN CGO_ENABLED=0 GOOS=linux go build -ldflags="-s -w" -o /app/omnivision-server . | |
| # Stage 2: Runtime con FFmpeg y procesamiento multimedia para Hugging Face Spaces | |
| FROM alpine:3.20 | |
| RUN apk add --no-cache ca-certificates ffmpeg tzdata ttf-dejavu fontconfig | |
| WORKDIR /app | |
| RUN adduser -D -u 1000 user || true | |
| COPY --from=builder /app/omnivision-server /app/omnivision-server | |
| RUN mkdir -p /app/temp && chown -R 1000:1000 /app | |
| ENV PORT=7860 | |
| ENV WORK_DIR=/app/temp | |
| ENV AI_MODEL=omnivision-neural-media-v2 | |
| ENV INFERENCE_BACKEND=cpu | |
| EXPOSE 7860 | |
| # Healthcheck: endpoint de salud del servidor web interno | |
| HEALTHCHECK --interval=30s --timeout=5s --start-period=30s --retries=3 \ | |
| CMD wget -q -O /dev/null "http://127.0.0.1:${PORT:-7860}/api/v1/health" || exit 1 | |
| USER user | |
| ENTRYPOINT ["/app/omnivision-server"] | |