Skip to content

Commit 4e8e03c

Browse files
fix: OTP 28 runtime + bind 0.0.0.0 for Docker
Gleam 1.14's build image ships OTP 28, so BEAM files compiled there won't load on the OTP 27 runtime. Bumped runtime to erlang:28-alpine. Also added mist.bind("0.0.0.0") so the server listens on all interfaces — required for Docker networking (was binding 127.0.0.1).
1 parent b05fc00 commit 4e8e03c

2 files changed

Lines changed: 2 additions & 1 deletion

File tree

frameworks/gleam-mist/Dockerfile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ RUN gleam deps download
66
COPY src ./src
77
RUN gleam export erlang-shipment
88

9-
FROM erlang:27-alpine
9+
FROM erlang:28-alpine
1010
RUN apk add --no-cache sqlite-libs
1111
WORKDIR /app
1212
COPY --from=build /app/build/erlang-shipment /app

frameworks/gleam-mist/src/httparena_gleam_mist.gleam

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -575,6 +575,7 @@ pub fn main() {
575575
}
576576
|> mist.new
577577
|> mist.port(8080)
578+
|> mist.bind("0.0.0.0")
578579
|> mist.start
579580

580581
process.sleep_forever()

0 commit comments

Comments
 (0)