mirror of
https://github.com/by-jp/www.byjp.me.git
synced 2025-08-09 09:46:11 +01:00
This puts the framework for building a statically compiled agate into a scratch Docker image which can be run from fly.io (as well as the fly.toml that sets it up correctly). This doesn't seem to work on fly.io itself at the moment, so more tinkering soon, but it works locally.
11 lines
420 B
Docker
11 lines
420 B
Docker
FROM ghcr.io/rust-cross/rust-musl-cross:x86_64-unknown-linux-musl as agate
|
|
|
|
RUN cargo install agate
|
|
|
|
FROM scratch
|
|
COPY --from=agate /root/.cargo/bin/agate /bin/agate
|
|
COPY ./public/ /var/agate/content/
|
|
|
|
EXPOSE 1965
|
|
|
|
ENTRYPOINT ["/bin/agate", "--content", "/var/agate/content/", "--addr", "0.0.0.0:1965", "--only-tls13", "--central-conf", "--lang", "en-GB", "--certs", "/var/agate/certificates/", "--hostname", "byjp.cc"]
|