mirror of
https://github.com/rr-/szurubooru.git
synced 2025-07-17 08:26:24 +00:00
client/build: Clean up build process
Fixes incorrect URIs of iOS splash screens and OpenSans font Files get gzipped inside build script Better nginx configuration build.js uses more consistent, synchronous code
This commit is contained in:
@ -8,10 +8,7 @@ COPY . ./
|
||||
|
||||
ARG BUILD_INFO="docker-latest"
|
||||
ARG CLIENT_BUILD_ARGS=""
|
||||
RUN BASE_URL="__BASEURL__" node build.js ${CLIENT_BUILD_ARGS}
|
||||
|
||||
RUN find public/ -name public/index.html -prune -o -type f -size +5k \
|
||||
-print0 | xargs -0 -- gzip -6 -k
|
||||
RUN BASE_URL="__BASEURL__" node build.js --gzip ${CLIENT_BUILD_ARGS}
|
||||
|
||||
|
||||
FROM nginx:alpine
|
||||
@ -23,7 +20,7 @@ RUN \
|
||||
echo 'sed -i "s|__BACKEND__|${BACKEND_HOST}|" /etc/nginx/nginx.conf' \
|
||||
>> /init && \
|
||||
echo 'sed -i "s|__BASEURL__|${BASE_URL:-/}|" /var/www/index.htm' >> /init && \
|
||||
echo 'exec nginx -g "daemon off;"' >> /init && \
|
||||
echo 'exec nginx' >> /init && \
|
||||
chmod a+x /init
|
||||
|
||||
CMD ["/init"]
|
||||
|
Reference in New Issue
Block a user