WIP changes
continuous-integration/drone the build was successful
Details
continuous-integration/drone the build was successful
Details
parent
6752b55a6b
commit
acf5baaad5
12
Dockerfile
12
Dockerfile
|
@ -14,8 +14,8 @@ RUN apk update && \
|
||||||
curl -sSL "https://www.acme.com/software/thttpd/thttpd-$THTTPD_VER.tar.gz" | \
|
curl -sSL "https://www.acme.com/software/thttpd/thttpd-$THTTPD_VER.tar.gz" | \
|
||||||
tar xzf - && \
|
tar xzf - && \
|
||||||
cd "thttpd-$THTTPD_VER" && \
|
cd "thttpd-$THTTPD_VER" && \
|
||||||
./configure && \
|
CFLAGS="-O3 -static" ./configure && \
|
||||||
make
|
make -j$(nproc)
|
||||||
|
|
||||||
|
|
||||||
# =====BUILD THE BLOG=====
|
# =====BUILD THE BLOG=====
|
||||||
|
@ -34,9 +34,9 @@ ARG THTTPD_VER
|
||||||
|
|
||||||
# Install dumb-init & create a non-root user
|
# Install dumb-init & create a non-root user
|
||||||
RUN apk update && \
|
RUN apk update && \
|
||||||
apk add --no-cache dumb-init && \
|
apk add --no-cache dumb-init
|
||||||
addgroup -g 82 -S www-data && \
|
# addgroup -g 82 -S www-data && \
|
||||||
adduser -u 82 -D -S -G www-data www-data
|
# adduser -u 82 -D -S -G www-data www-data
|
||||||
|
|
||||||
# Copy over binary & static files
|
# Copy over binary & static files
|
||||||
COPY --from=builder /usr/src/thttpd-$THTTPD_VER/thttpd /usr/local/bin/thttpd
|
COPY --from=builder /usr/src/thttpd-$THTTPD_VER/thttpd /usr/local/bin/thttpd
|
||||||
|
@ -44,7 +44,7 @@ COPY --from=builder /usr/src/app/public /var/www/html
|
||||||
COPY thttpd.conf /etc/thttpd.conf
|
COPY thttpd.conf /etc/thttpd.conf
|
||||||
|
|
||||||
# A static file server doesn't need root
|
# A static file server doesn't need root
|
||||||
USER www-data:www-data
|
USER 82:82
|
||||||
|
|
||||||
ENTRYPOINT [ "dumb-init", "--" ]
|
ENTRYPOINT [ "dumb-init", "--" ]
|
||||||
CMD [ "/usr/local/bin/thttpd", "-D", "-C", "/etc/thttpd.conf" ]
|
CMD [ "/usr/local/bin/thttpd", "-D", "-C", "/etc/thttpd.conf" ]
|
||||||
|
|
Reference in New Issue