Skip to content

Commit

Permalink
Use entrypoint script
Browse files Browse the repository at this point in the history
  • Loading branch information
gregbell26 committed Jul 3, 2024
1 parent 7393f19 commit f51befa
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 1 deletion.
3 changes: 2 additions & 1 deletion Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -19,5 +19,6 @@ RUN apt-get update && \
apt-get install -y libgbm-dev xvfb

COPY --from=builder /app/dist /dist
ADD --chmod=777 entrypoint.sh /entrypoint.sh

ENTRYPOINT [ "xvfb-run", "-e", "/dev/stdout","--server-args='-screen 0 1200x800x24'", "node", "/dist/index.js"]
ENTRYPOINT /entrypoint.sh
7 changes: 7 additions & 0 deletions entrypoint.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
#!/bin/sh

Xvfb -ac :99 -screen 0 1280x1024x16 > /dev/null 2>&1 &

export DISPLAY=:99.0
echo $@
node /dist/index.js $@

0 comments on commit f51befa

Please sign in to comment.