Update fly.io deployment (#71)

This commit is contained in:
Mike English 2023-09-15 16:10:13 -04:00 committed by GitHub
parent 88542e266c
commit 7f402bd070
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 12 additions and 1 deletions

View File

@ -15,5 +15,8 @@ RUN --mount=type=cache,target=/usr/local/cargo/registry \
# Runtime image
FROM rust:latest
# Fly.io entrypoint
ADD fly-relay.sh .
# Copy the compiled binaries
COPY --from=builder /usr/local/cargo/bin /usr/local/cargo/bin

8
fly-relay.sh Executable file
View File

@ -0,0 +1,8 @@
#!/usr/bin/env sh
mkdir cert
# Nothing to see here...
echo "$MOQ_CRT" | base64 -d > dev/moq-demo.crt
echo "$MOQ_KEY" | base64 -d > dev/moq-demo.key
RUST_LOG=info /usr/local/cargo/bin/moq-relay --cert dev/moq-demo.crt --key dev/moq-demo.key

View File

@ -6,7 +6,7 @@ kill_timeout = 5
PORT = "4443"
[experimental]
cmd = "./entrypoint.sh"
cmd = "./fly-relay.sh"
[[services]]
internal_port = 4443