#Cpp, docker, cmake, websockets
9 messages · Page 1 of 1 (latest)
Here is my error during the build
This is my Dockerfile
Étape 1 : Base image
FROM ubuntu:24.04
Étape 2 : Installer les dépendances système
RUN apt update && apt install -y
build-essential
git
curl
zip
unzip
pkg-config
libssl-dev
libuv1-dev
zlib1g-dev
ca-certificates
cmake
&& rm -rf /var/lib/apt/lists/*
Étape 3 : Cloner et configurer vcpkg
WORKDIR /opt
RUN git clone https://github.com/microsoft/vcpkg.git
WORKDIR /opt/vcpkg
RUN ./bootstrap-vcpkg.sh
ENV VCPKG_ROOT=/opt/vcpkg
ENV PATH="${VCPKG_ROOT}:${PATH}"
Étape 4 : Installer les dépendances avec vcpkg
RUN ./vcpkg install uwebsockets:x64-linux
Étape 5 : Copier et builder ton projet
WORKDIR /app
COPY . .
RUN cmake -B build -S .
-DCMAKE_TOOLCHAIN_FILE=/opt/vcpkg/scripts/buildsystems/vcpkg.cmake
-DCMAKE_BUILD_TYPE=Release
RUN cmake --build build
Étape 6 : Préparer l’exécution
EXPOSE 8080
CMD ["./build/GameServer/GameServer"]
I'm pretty new to setting up this kind of architecture, so I may have done some really stupid things, but I can't seem to find a solution.
I can run my project from visual studio without problem
@stray karma has reached level 1. GG!