mirror of
https://github.com/nestriness/nestri.git
synced 2025-12-12 08:45:38 +02:00
## Description This PR will work on adding port muxing (share single port for HTTP/WS + WebRTC connections), along with API communication. ## Type of Change - [x] Bug fix (non-breaking change) - [x] New feature (non-breaking change) ## Checklist - [ ] I have updated relevant documentation - [x] My code follows the project's coding style - [x] My changes generate no new warnings/errors --------- Co-authored-by: DatCaptainHorse <DatCaptainHorse@users.noreply.github.com>
29 lines
702 B
Docker
29 lines
702 B
Docker
FROM docker.io/golang:1.24-alpine AS go-build
|
|
WORKDIR /builder
|
|
COPY packages/relay/ /builder/
|
|
RUN go build
|
|
|
|
FROM docker.io/golang:1.24-alpine
|
|
COPY --from=go-build /builder/relay /relay/relay
|
|
WORKDIR /relay
|
|
|
|
# TODO: Switch running layer to just alpine (doesn't need golang dev stack)
|
|
|
|
# ENV flags
|
|
ENV VERBOSE=false
|
|
ENV DEBUG=false
|
|
ENV ENDPOINT_PORT=8088
|
|
ENV WEBRTC_UDP_START=10000
|
|
ENV WEBRTC_UDP_END=20000
|
|
ENV STUN_SERVER="stun.l.google.com:19302"
|
|
ENV WEBRTC_UDP_MUX=8088
|
|
ENV WEBRTC_NAT_IPS=""
|
|
ENV AUTO_ADD_LOCAL_IP=true
|
|
ENV TLS_CERT=""
|
|
ENV TLS_KEY=""
|
|
|
|
EXPOSE $ENDPOINT_PORT
|
|
EXPOSE $WEBRTC_UDP_START-$WEBRTC_UDP_END/udp
|
|
EXPOSE $WEBRTC_UDP_MUX/udp
|
|
|
|
ENTRYPOINT ["/relay/relay"] |