mirror of
https://github.com/n8n-io/n8n.git
synced 2024-12-25 12:44:07 -08:00
🔀 Merge branch 'caarlos0-images'
This commit is contained in:
commit
b387196291
|
@ -14,3 +14,7 @@ indent_size = 2
|
|||
|
||||
[*.ts]
|
||||
quote_type = single
|
||||
|
||||
[*.yml]
|
||||
indent_style = space
|
||||
indent_size = 2
|
||||
|
|
40
.github/workflows/docker-images-rpi.yml
vendored
40
.github/workflows/docker-images-rpi.yml
vendored
|
@ -1,40 +0,0 @@
|
|||
name: Docker Image CI - Rpi
|
||||
|
||||
on:
|
||||
push:
|
||||
tags:
|
||||
- n8n@*
|
||||
workflow_dispatch:
|
||||
inputs:
|
||||
version:
|
||||
description: 'n8n version to build docker image for.'
|
||||
required: true
|
||||
default: '0.112.0'
|
||||
|
||||
jobs:
|
||||
armv7_job:
|
||||
runs-on: ubuntu-18.04
|
||||
name: Build on ARMv7 (Rpi)
|
||||
steps:
|
||||
- uses: actions/checkout@v1
|
||||
- name: Get the version
|
||||
id: vars
|
||||
run: echo ::set-output name=tag::$(echo ${GITHUB_REF:14})
|
||||
|
||||
- name: Log in to Docker registry
|
||||
run: docker login -u ${{ secrets.DOCKER_USERNAME }} -p ${{ secrets.DOCKER_PASSWORD }}
|
||||
|
||||
- name: Set up Docker Buildx
|
||||
uses: crazy-max/ghaction-docker-buildx@v3
|
||||
with:
|
||||
buildx-version: latest
|
||||
qemu-version: latest
|
||||
- name: Run Buildx (push image)
|
||||
if: success()
|
||||
run: |
|
||||
docker buildx build \
|
||||
--platform linux/arm/v7 \
|
||||
--build-arg N8N_VERSION=${{github.event.inputs.version || steps.vars.outputs.tag}} \
|
||||
-t ${{ secrets.DOCKER_USERNAME }}/n8n:${{github.event.inputs.version || steps.vars.outputs.tag}}-rpi \
|
||||
-t ${{ secrets.DOCKER_USERNAME }}/n8n:latest-rpi \
|
||||
--output type=image,push=true docker/images/n8n-rpi
|
54
.github/workflows/docker-images.yml
vendored
54
.github/workflows/docker-images.yml
vendored
|
@ -6,33 +6,41 @@ on:
|
|||
- n8n@*
|
||||
|
||||
jobs:
|
||||
|
||||
build:
|
||||
|
||||
runs-on: ubuntu-latest
|
||||
|
||||
steps:
|
||||
- uses: actions/checkout@v1
|
||||
- name: Get the version
|
||||
id: vars
|
||||
run: echo ::set-output name=tag::$(echo ${GITHUB_REF:14})
|
||||
- name: Log in to Docker registry
|
||||
run: docker login -u ${{ secrets.DOCKER_USERNAME }} -p ${{ secrets.DOCKER_PASSWORD }}
|
||||
|
||||
- name: Build the Docker image of version
|
||||
run: docker build --build-arg N8N_VERSION=${{steps.vars.outputs.tag}} -t n8nio/n8n:${{steps.vars.outputs.tag}} docker/images/n8n
|
||||
- name: Push Docker image of version
|
||||
run: docker push n8nio/n8n:${{steps.vars.outputs.tag}}
|
||||
- name: Tag Docker image with latest
|
||||
run: docker tag n8nio/n8n:${{steps.vars.outputs.tag}} n8nio/n8n:latest
|
||||
- name: Push docker images of latest
|
||||
run: docker push n8nio/n8n:latest
|
||||
|
||||
- name: Build the Docker image of version (Debian)
|
||||
run: docker build --build-arg N8N_VERSION=${{steps.vars.outputs.tag}} -t n8nio/n8n:${{steps.vars.outputs.tag}}-debian docker/images/n8n-debian
|
||||
- name: Push Docker image of version (Debian)
|
||||
run: docker push n8nio/n8n:${{steps.vars.outputs.tag}}-debian
|
||||
- name: Tag Docker image with latest (Debian)
|
||||
run: docker tag n8nio/n8n:${{steps.vars.outputs.tag}}-debian n8nio/n8n:latest-debian
|
||||
- name: Push docker images of latest (Debian)
|
||||
run: docker push n8nio/n8n:latest-debian
|
||||
- name: Set up QEMU
|
||||
uses: docker/setup-qemu-action@v1
|
||||
- name: Set up Docker Buildx
|
||||
uses: docker/setup-buildx-action@v1
|
||||
- name: Login to DockerHub
|
||||
uses: docker/login-action@v1
|
||||
with:
|
||||
username: ${{ secrets.DOCKER_USERNAME }}
|
||||
password: ${{ secrets.DOCKER_PASSWORD }}
|
||||
- name: Build
|
||||
uses: docker/build-push-action@v2
|
||||
with:
|
||||
context: ./docker/images/n8n
|
||||
build-args: |
|
||||
N8N_VERSION=${{steps.vars.outputs.tag}}
|
||||
platforms: linux/amd64,linux/arm64,linux/arm/v7
|
||||
push: true
|
||||
tags: |
|
||||
${{ secrets.DOCKER_USERNAME }}/n8n:${{ steps.vars.outputs.tag }}
|
||||
${{ secrets.DOCKER_USERNAME }}/n8n:latest
|
||||
- name: Build (debian)
|
||||
uses: docker/build-push-action@v2
|
||||
with:
|
||||
context: ./docker/images/n8n-debian
|
||||
build-args: |
|
||||
N8N_VERSION=${{ steps.vars.outputs.tag }}
|
||||
platforms: linux/amd64,linux/arm64,linux/arm/v7
|
||||
push: true
|
||||
tags: |
|
||||
${{ secrets.DOCKER_USERNAME }}/n8n:${{ steps.vars.outputs.tag }}-debian
|
||||
${{ secrets.DOCKER_USERNAME }}/n8n:latest-debian
|
||||
|
|
|
@ -1,21 +0,0 @@
|
|||
FROM arm32v7/node:14.15
|
||||
|
||||
ARG N8N_VERSION
|
||||
|
||||
RUN if [ -z "$N8N_VERSION" ] ; then echo "The N8N_VERSION argument is missing!" ; exit 1; fi
|
||||
|
||||
RUN \
|
||||
apt-get update && \
|
||||
apt-get -y install graphicsmagick gosu git
|
||||
|
||||
RUN npm_config_user=root npm install -g full-icu n8n@${N8N_VERSION}
|
||||
|
||||
ENV NODE_ICU_DATA /usr/local/lib/node_modules/full-icu
|
||||
ENV NODE_ENV production
|
||||
|
||||
WORKDIR /data
|
||||
|
||||
USER root
|
||||
|
||||
CMD chown -R node:node /home/node/.n8n \
|
||||
&& gosu node n8n
|
|
@ -1,22 +0,0 @@
|
|||
## n8n - Raspberry PI Docker Image
|
||||
|
||||
Dockerfile to build n8n for Raspberry PI.
|
||||
|
||||
For information about how to run n8n with Docker check the generic
|
||||
[Docker-Readme](https://github.com/n8n-io/n8n/tree/master/docker/images/n8n/README.md)
|
||||
|
||||
|
||||
```
|
||||
docker build --build-arg N8N_VERSION=<VERSION> -t n8nio/n8n:<VERSION> .
|
||||
|
||||
# For example:
|
||||
docker build --build-arg N8N_VERSION=0.43.0 -t n8nio/n8n:0.43.0-rpi .
|
||||
```
|
||||
|
||||
```
|
||||
docker run -it --rm \
|
||||
--name n8n \
|
||||
-p 5678:5678 \
|
||||
-v ~/.n8n:/home/node/.n8n \
|
||||
n8nio/n8n:0.70.0-rpi
|
||||
```
|
|
@ -227,10 +227,10 @@ docker run -it --rm \
|
|||
## Build Docker-Image
|
||||
|
||||
```
|
||||
docker build --build-arg N8N_VERSION=<VERSION> -t n8nio/n8n:<VERSION> .
|
||||
docker buildx build --platform linux/amd64,linux/arm64,linux/arm/v7 --build-arg N8N_VERSION=<VERSION> -t n8nio/n8n:<VERSION> .
|
||||
|
||||
# For example:
|
||||
docker build --build-arg N8N_VERSION=0.18.1 -t n8nio/n8n:0.18.1 .
|
||||
docker buildx build --platform linux/amd64,linux/arm64,linux/arm/v7 --build-arg N8N_VERSION=0.114.0 -t n8nio/n8n:0.114.0 .
|
||||
```
|
||||
|
||||
|
||||
|
|
Loading…
Reference in a new issue