Skip to content

Commit

Permalink
ci(dockerfile): fix port and binds (#67)
Browse files Browse the repository at this point in the history
  • Loading branch information
ZigBalthazar authored Oct 12, 2024
1 parent f15617f commit 7a7e25c
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 8 deletions.
8 changes: 4 additions & 4 deletions config/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,10 +14,10 @@ environment: "prod"
ws_server:
# bind is the IP address to be bind and listen on.
# default if local host.
bind: "localhost"
bind: "0.0.0.0"
# port is websocket port to be listen on.
# default is 7777.
port: 7777
port: 9090
# known_bloom_size is the size of bloom filter to check and avoid trying to store/broadcast existing events.
# default is 1M events.
known_bloom_size: 1000000
Expand All @@ -29,10 +29,10 @@ ws_server:
http_server:
# bind is the IP address to be bind and listen on.
# default if local host.
bind: "localhost"
bind: "0.0.0.0"
# port is websocket port to be listen on.
# default is 8888.
port: 8888
port: 8080

# database contains details of database connections and limitations.
database:
Expand Down
4 changes: 2 additions & 2 deletions config/config_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,6 @@ func TestLoadfromFile(t *testing.T) {
cfg, err := config.Load("./config.yml")
require.NoError(t, err, "error must be nil.")

assert.Equal(t, uint16(7777), cfg.WebsocketServer.Port)
assert.Equal(t, "127.0.0.1", cfg.WebsocketServer.Bind)
assert.Equal(t, uint16(9090), cfg.WebsocketServer.Port)
assert.Equal(t, "0.0.0.0", cfg.WebsocketServer.Bind)
}
4 changes: 2 additions & 2 deletions dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -34,8 +34,8 @@ COPY --from=builder /app/build/immortal .
COPY --from=builder /app/config/config.yml .

#* Expose necessary ports for the application
EXPOSE 7777
EXPOSE 8888
EXPOSE 9090
EXPOSE 8080

#* Set the entrypoint to run the application
ENTRYPOINT ["./immortal", "run", "./config.yml"]

0 comments on commit 7a7e25c

Please sign in to comment.