Skip to content

Commit

Permalink
add CONFIG_PATH build arg
Browse files Browse the repository at this point in the history
  • Loading branch information
riordanp committed Nov 5, 2024
1 parent 2702566 commit 8c89601
Show file tree
Hide file tree
Showing 4 changed files with 8 additions and 29 deletions.
3 changes: 2 additions & 1 deletion bin/autobahn-router/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -16,10 +16,11 @@ COPY . .
RUN cargo build --release --bin autobahn-router

FROM debian:bookworm-slim as run
ARG CONFIG_PATH=/app/bin/autobahn-router/template-config.toml
RUN apt-get update && apt-get -y install ca-certificates libc6 libssl3 libssl-dev openssl

COPY --from=build /app/target/release/autobahn-router /usr/local/bin/
COPY --from=build /app/bin/autobahn-router/template-config.toml /usr/local/bin/template-config.toml
COPY --from=build $CONFIG_PATH /usr/local/bin/template-config.toml

RUN adduser --system --group --no-create-home mangouser
USER mangouser
25 changes: 0 additions & 25 deletions bin/autobahn-router/eclipse/Dockerfile

This file was deleted.

9 changes: 6 additions & 3 deletions fly-eclipse.toml
Original file line number Diff line number Diff line change
Expand Up @@ -4,13 +4,16 @@ kill_signal = "SIGTERM"
kill_timeout = "30s"

[build]
dockerfile = 'bin/autobahn-router/eclipse/Dockerfile'
dockerfile = 'bin/autobahn-router/Dockerfile'

[build.args]
CONFIG_PATH="/app/bin/autobahn-router/template-config-eclipse.toml"

[experimental]
cmd = ["autobahn-router", "/usr/local/bin/template-config-eclipse.toml"]
cmd = ["autobahn-router", "/usr/local/bin/template-config.toml"]

[[vm]]
size = "shared-4x"
size = "shared-cpu-4x"
memory = "8gb"

[[restart]]
Expand Down

0 comments on commit 8c89601

Please sign in to comment.