We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
2 parents 10f8411 + 5865383 commit e5e44a4Copy full SHA for e5e44a4
1 file changed
Dockerfile
@@ -27,7 +27,7 @@ ENV NODE_ENV=production
27
ENV NODE_PATH='dist'
28
29
# Install dependencies
30
-RUN apk --no-cache add python3 git jq openssh
+RUN apk --no-cache add python3 git jq openssh tini
31
32
# Install app
33
RUN mkdir /app
@@ -42,4 +42,7 @@ RUN echo 'nouser:x:999:999::/home/nouser:/bin/sh' >> /etc/passwd
42
USER node
43
EXPOSE 8080
44
45
+# tini is used as PID 1 to reap zombie child processes (e.g. git-remote-http)
46
+# that Node.js would otherwise leave unreaped, causing PID exhaustion over time
47
+ENTRYPOINT ["/sbin/tini", "--"]
48
CMD ["node", "--max-http-header-size", "16384", "dist/src/app.js"]
0 commit comments