as title stated, in order to deploy the server on to other cloud platform, i have split up my core (server logic) and database into 2 different container instead of using compose to group them together.
and when doing that, the debugger seems failed to connect with the following error message.
2024-04-13T15:47:39Z error layer=rpc writing response:write tcp 172.17.0.3:4000->172.17.0.1:56738: use of closed network connection
FROM heroiclabs/nakama-pluginbuilder:3.21.1 AS go-builder
ENV GO111MODULE on
ENV CGO_ENABLED 1
WORKDIR /backend
COPY go.mod ./
COPY src/*.go ./
COPY vendor/ vendor/
RUN go build --trimpath --mod=vendor --buildmode=plugin -o ./backend.so
FROM registry.heroiclabs.com/heroiclabs/nakama:3.21.1
COPY --from=go-builder /backend/backend.so /nakama/data/modules/
COPY local.yml /nakama/data/
EXPOSE 7349
EXPOSE 7350
EXPOSE 7351
EXPOSE 2345
EXPOSE 8080
ENTRYPOINT ["/bin/sh", "-ecx", "/nakama/nakama migrate up --database.address postgres:[email protected]:5432/nakama && exec /nakama/nakama --config /nakama/data/local.yml --database.address postgres:[email protected]:5432/nakama"]
the database part should be fine because i have a Docker_release file which build my server without dlv and it can connect to database and i can enter the admin portal as usual.