chore: add Fly.io deployment config for `git-ents-server`
commit
57ad3f1chore: add Fly.io deployment config for `git-ents-server`
feat: add crates/git-ents-server/Dockerfile with cargo-chef build
feat: add .config/fly.toml targeting IAD, 512 MB VM
chore: add .dockerignore at repo root
Assisted-by: Claude:claude-sonnet-4-6
Reviews
No reviews of this commit yet — record a verdict below.
Start a review
.config/fly.toml
@@ -1,0 +1,26 @@
+# fly.toml app configuration file generated for git-ents-server on 2026-06-20T12:17:33-04:00
+#
+# See https://fly.io/docs/reference/configuration/ for information about how to use this file.
+#
+
+app = 'git-ents-server'
+primary_region = 'iad'
+
+[build]
+ dockerfile = "crates/git-ents-server/Dockerfile"
+
+[env]
+ PORT = '8080'
+
+[http_service]
+ internal_port = 8080
+ force_https = true
+ auto_stop_machines = 'stop'
+ auto_start_machines = true
+ min_machines_running = 0
+ processes = ['app']
+
+[[vm]]
+ memory = '512mb'
+ cpus = 1
+ memory_mb = 512
.dockerignore
@@ -1,0 +1,2 @@
+fly.toml
+.git/
crates/git-ents-server/Dockerfile
@@ -1,0 +1,20 @@
+FROM lukemathwalker/cargo-chef:latest-rust-1 AS chef
+WORKDIR /app
+
+FROM chef AS planner
+COPY . .
+RUN cargo chef prepare --recipe-path recipe.json
+
+FROM chef AS builder
+COPY --from=planner /app/recipe.json recipe.json
+# Build dependencies - this is the caching Docker layer!
+RUN cargo chef cook --release --recipe-path recipe.json
+# Build application
+COPY . .
+RUN cargo build --release --bin git-ents-server
+
+# We do not need the Rust toolchain to run the binary!
+FROM debian:bookworm-slim AS runtime
+WORKDIR /app
+COPY --from=builder /app/target/release/git-ents-server /usr/local/bin
+ENTRYPOINT ["/usr/local/bin/git-ents-server"]