Fix resource leak with http request response body & fix docker file (#16)

* Add support for videoId query flags

* Update README examples

* Fix resource leak

* Close body on 429 & fix docker file with use of fiber prefork

* Add dumb-init to line 12
This commit is contained in:
Ward 2024-04-28 00:30:35 +12:00 committed by GitHub
parent 4d364ec4fc
commit a6ec5b17e4
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
2 changed files with 12 additions and 7 deletions

View file

@ -9,11 +9,13 @@ RUN --mount=type=cache,target=/root/.cache/go-build \
FROM alpine
RUN apk --no-cache add --no-check-certificate ca-certificates \
RUN apk --no-cache add --no-check-certificate ca-certificates dumb-init \
&& update-ca-certificates
COPY --from=build /app/main /ryd-proxy
ENTRYPOINT ["/usr/bin/dumb-init", "--"]
EXPOSE 3000
CMD [ "/ryd-proxy" ]
CMD "/ryd-proxy"