mirror of
https://github.com/maptiler/tileserver-gl.git
synced 2024-09-11 03:55:27 +03:00
Use simplified entrypoint script
This commit is contained in:
parent
6b96f224ae
commit
16de5be673
@ -3,4 +3,4 @@
|
||||
!public
|
||||
!package.json
|
||||
!package-lock.json
|
||||
!run.sh
|
||||
!docker-entrypoint.sh
|
||||
|
@ -40,12 +40,12 @@ RUN export DEBIAN_FRONTEND=noninteractive \
|
||||
libprotobuf17 \
|
||||
libxxf86vm1 \
|
||||
xvfb \
|
||||
x11-utils \
|
||||
xauth \
|
||||
&& apt-get -y --purge autoremove \
|
||||
&& apt-get clean \
|
||||
&& rm -rf /var/lib/apt/lists/*
|
||||
|
||||
COPY --from=builder /usr/src/app /usr/src/app
|
||||
COPY --from=builder /usr/src/app /app
|
||||
|
||||
ENV NODE_ENV="production"
|
||||
ENV CHOKIDAR_USEPOLLING=1
|
||||
@ -56,4 +56,6 @@ WORKDIR /data
|
||||
|
||||
EXPOSE 80
|
||||
|
||||
ENTRYPOINT ["/usr/src/app/run.sh"]
|
||||
ENTRYPOINT ["/app/docker-entrypoint.sh"]
|
||||
|
||||
CMD ["-p", "80"]
|
||||
|
11
docker-entrypoint.sh
Executable file
11
docker-entrypoint.sh
Executable file
@ -0,0 +1,11 @@
|
||||
#!/bin/sh
|
||||
|
||||
set -e
|
||||
|
||||
if ! which -- "${1}"; then
|
||||
# first arg is not an executable
|
||||
xvfb-run --server-args="-screen 0 1024x768x24" -- node /app/ "$@"
|
||||
exit $?
|
||||
fi
|
||||
|
||||
exec "$@"
|
Loading…
Reference in New Issue
Block a user