Files
webserv/Dockerfile
2025-08-23 20:10:47 +02:00

28 lines
420 B
Docker

FROM alpine:3.22 AS builder
COPY ./ /build
ENV PKGS=true
ENV TTY=true
RUN apk add --no-cache bash clang make
RUN cd /build \
&& CXXFLAGS="-std=c++98" PKGS=true make -j re
FROM alpine:3.22
RUN apk add --no-cache libstdc++
COPY --from=builder /build/webserv /bin/webserv
RUN chmod +x /bin/webserv
WORKDIR /
RUN /bin/webserv --generate
STOPSIGNAL SIGINT
CMD [ "webserv", "/sample.toml"]