FROM ghcr.io/martialbe/one-api as builder FROM --platform=$BUILDPLATFORM caddy:2.6.2-alpine AS runner RUN apk update \ && apk upgrade \ && apk add --no-cache ca-certificates tzdata \ && update-ca-certificates 2>/dev/null || true COPY --from=builder /one-api /usr/local/bin/one-api WORKDIR /data COPY Caddyfile ./Caddyfile RUN chmod 777 -R /data EXPOSE 3001 CMD ["sh", "-c", "caddy run --config /data/Caddyfile & /usr/local/bin/one-api"]