2020-01-02 11:05:51 -08:00
|
|
|
name: Docker Image CI
|
|
|
|
|
|
|
|
on:
|
|
|
|
push:
|
|
|
|
tags:
|
|
|
|
- n8n@*
|
|
|
|
|
|
|
|
jobs:
|
|
|
|
build:
|
|
|
|
runs-on: ubuntu-latest
|
2022-12-06 08:26:53 -08:00
|
|
|
|
|
|
|
strategy:
|
|
|
|
matrix:
|
|
|
|
docker-context: ['', '-debian']
|
|
|
|
|
2020-01-02 11:05:51 -08:00
|
|
|
steps:
|
2022-09-21 01:50:15 -07:00
|
|
|
- uses: actions/checkout@v3
|
|
|
|
|
2022-08-19 06:34:02 -07:00
|
|
|
- name: Get the version
|
|
|
|
id: vars
|
|
|
|
run: echo ::set-output name=tag::$(echo ${GITHUB_REF:14})
|
2022-09-21 01:50:15 -07:00
|
|
|
|
2022-08-19 06:34:02 -07:00
|
|
|
- name: Set up QEMU
|
2022-09-21 01:50:15 -07:00
|
|
|
uses: docker/setup-qemu-action@v2
|
|
|
|
|
2022-08-19 06:34:02 -07:00
|
|
|
- name: Set up Docker Buildx
|
2022-09-21 01:50:15 -07:00
|
|
|
uses: docker/setup-buildx-action@v2
|
|
|
|
|
2022-08-19 06:34:02 -07:00
|
|
|
- name: Login to DockerHub
|
2022-09-21 01:50:15 -07:00
|
|
|
uses: docker/login-action@v2
|
2022-08-19 06:34:02 -07:00
|
|
|
with:
|
|
|
|
username: ${{ secrets.DOCKER_USERNAME }}
|
|
|
|
password: ${{ secrets.DOCKER_PASSWORD }}
|
2022-09-21 01:50:15 -07:00
|
|
|
|
2022-08-19 06:34:02 -07:00
|
|
|
- name: Build
|
|
|
|
uses: docker/build-push-action@v2
|
|
|
|
with:
|
2022-12-06 08:26:53 -08:00
|
|
|
context: ./docker/images/n8n${{ matrix.docker-context }}
|
2022-08-19 06:34:02 -07:00
|
|
|
build-args: |
|
|
|
|
N8N_VERSION=${{ steps.vars.outputs.tag }}
|
2022-12-07 03:42:52 -08:00
|
|
|
platforms: linux/amd64,linux/arm64,linux/arm/v7
|
2022-08-19 06:34:02 -07:00
|
|
|
push: true
|
|
|
|
tags: |
|
2022-12-06 08:26:53 -08:00
|
|
|
${{ secrets.DOCKER_USERNAME }}/n8n:${{ steps.vars.outputs.tag }}${{ matrix.docker-context }}
|
|
|
|
${{ secrets.DOCKER_USERNAME }}/n8n:latest${{ matrix.docker-context }}
|