Skip to content

Commit

Permalink
add static linking flag to dockerfile
Browse files Browse the repository at this point in the history
  • Loading branch information
Jadit19 authored Aug 22, 2024
1 parent f7a99de commit a1a6291
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions docker/build.dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ WORKDIR /app

COPY . .

RUN mkdir build && cd build && cmake -DCMAKE_BUILD_TYPE=Release .. && make
RUN mkdir build && cd build && cmake -DCMAKE_BUILD_TYPE=Release -DCMAKE_EXE_LINKER_FLAGS="-static" .. && make

RUN chmod +x /app/build/server

Expand All @@ -18,4 +18,4 @@ COPY --from=builder /app/build/server /app/build/server

COPY --from=builder /app/assets /app/assets

ENTRYPOINT ["./server"]
ENTRYPOINT ["./server"]

0 comments on commit a1a6291

Please sign in to comment.