17 lines
No EOL
375 B
Docker
17 lines
No EOL
375 B
Docker
FROM alpine:latest
|
|
|
|
# Install all necessary tools: git, musl-gcc (which is just gcc in Alpine), make
|
|
RUN apk add --no-cache \
|
|
git \
|
|
build-base \
|
|
musl-dev
|
|
|
|
# Create a non-root user to run the build (best practice)
|
|
RUN adduser -D builder
|
|
WORKDIR /home/builder
|
|
|
|
# The default command will be the build script
|
|
COPY build.sh .
|
|
|
|
USER builder
|
|
CMD ["/bin/sh", "build.sh"] |