mirror of
https://github.com/Abdulazizzn/n8n-enterprise-unlocked.git
synced 2025-12-18 02:21:13 +00:00
🐳 Improve automatic docker build
This commit is contained in:
@@ -1,5 +1,9 @@
|
|||||||
FROM mhart/alpine-node:10
|
FROM mhart/alpine-node:10
|
||||||
|
|
||||||
|
ARG N8N_VERSION
|
||||||
|
|
||||||
|
RUN if [ -z "$N8N_VERSION" ] ; then echo "The N8N_VERSION argument is missing!" ; exit 1; fi
|
||||||
|
|
||||||
# Update everything and install needed dependencies
|
# Update everything and install needed dependencies
|
||||||
RUN apk add --update \
|
RUN apk add --update \
|
||||||
graphicsmagick
|
graphicsmagick
|
||||||
@@ -10,7 +14,7 @@ USER root
|
|||||||
# Install n8n and the also temporary all the packages
|
# Install n8n and the also temporary all the packages
|
||||||
# it needs to build it correctly.
|
# it needs to build it correctly.
|
||||||
RUN apk --update add --virtual build-dependencies python build-base && \
|
RUN apk --update add --virtual build-dependencies python build-base && \
|
||||||
npm_config_user=root npm install -g n8n && \
|
npm_config_user=root npm install -g n8n@${N8N_VERSION} && \
|
||||||
apk del build-dependencies
|
apk del build-dependencies
|
||||||
|
|
||||||
WORKDIR /data
|
WORKDIR /data
|
||||||
|
|||||||
2
docker/images/n8n/hooks/build
Normal file
2
docker/images/n8n/hooks/build
Normal file
@@ -0,0 +1,2 @@
|
|||||||
|
#!/bin/bash
|
||||||
|
docker build --build-arg N8N_VERSION=$DOCKER_TAG -f $DOCKERFILE_PATH -t $IMAGE_NAME .
|
||||||
Reference in New Issue
Block a user