Simplified docker building

This commit is contained in:
saundersp
2024-05-01 13:36:08 +02:00
parent e5f2eac0f0
commit ac6755517b
3 changed files with 9 additions and 19 deletions

View File

@ -1,21 +1,13 @@
FROM alpine:3.19.1
RUN apk add make g++
RUN apk add --no-cache make=4.4.1-r2 g++=13.2.1_git20231014-r0 \
&& adduser --disabled-password saundersp
USER saundersp
WORKDIR /home/saundersp/sorting_algorithms
RUN adduser \
--disabled-password \
--gecos '' \
--home "$(pwd)" \
--no-create-home \
saundersp
COPY . .
RUN chown -R saundersp /home/saundersp/sorting_algorithms
USER saundersp
COPY *.cpp *.hpp Makefile ./
RUN make -j "$(nproc)"