mirror of
https://github.com/n8n-io/n8n.git
synced 2025-01-15 06:47:29 -08:00
41cb0eec6e
* feat(cli): Setup error tracking using Sentry * make error reporting available in the workflows package * address some of the PR comments * create a ErrorReporterProxy like LoggerProxy * remove the `captureError` helper. use ErrorReporterProxy directly * fix linting issues * remove ErrorReporterProxy warnings in tests * check for NODE_ENV === 'production' instead * IErrorReporter -> ErrorReporter * ErrorReporterProxy.getInstance() -> ErrorReporter * allow capturing stacks in warnings as well * make n8n debugging consistent with `npm start` * IReportingOptions -> ReportingOptions * use consistent signature for `error` and `warn` * use Logger instead of console.log
27 lines
841 B
Docker
27 lines
841 B
Docker
ARG NODE_VERSION=16
|
|
FROM n8nio/base:${NODE_VERSION}
|
|
|
|
ARG N8N_VERSION
|
|
RUN if [ -z "$N8N_VERSION" ] ; then echo "The N8N_VERSION argument is missing!" ; exit 1; fi
|
|
|
|
ENV N8N_VERSION=${N8N_VERSION}
|
|
ENV NODE_ENV=production
|
|
RUN set -eux; \
|
|
apkArch="$(apk --print-arch)"; \
|
|
case "$apkArch" in \
|
|
'armv7') apk --no-cache add --virtual build-dependencies python3 build-base;; \
|
|
esac && \
|
|
npm install -g --omit=dev n8n@${N8N_VERSION} && \
|
|
case "$apkArch" in \
|
|
'armv7') apk del build-dependencies;; \
|
|
esac && \
|
|
find /usr/local/lib/node_modules/n8n -type f -name "*.ts" -o -name "*.js.map" -o -name "*.vue" | xargs rm && \
|
|
rm -rf /root/.npm
|
|
|
|
# Set a custom user to not have n8n run as root
|
|
USER root
|
|
WORKDIR /data
|
|
RUN apk --no-cache add su-exec
|
|
COPY docker-entrypoint.sh /docker-entrypoint.sh
|
|
ENTRYPOINT ["tini", "--", "/docker-entrypoint.sh"]
|