mirror of
https://github.com/sablierapp/sablier.git
synced 2025-12-21 13:23:03 +01:00
ci: reuse docker image in e2e matrix jobs
This commit is contained in:
46
.github/workflows/plugins.yml
vendored
46
.github/workflows/plugins.yml
vendored
@@ -8,6 +8,30 @@ on:
|
||||
pull_request:
|
||||
|
||||
jobs:
|
||||
build:
|
||||
name: Build docker image once and share it to E2E jobs
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- name: Checkout
|
||||
uses: actions/checkout@v2
|
||||
|
||||
- name: Set up Docker Buildx
|
||||
uses: docker/setup-buildx-action@v2
|
||||
|
||||
- name: Build and push
|
||||
uses: docker/build-push-action@v2
|
||||
with:
|
||||
context: .
|
||||
file: ./Dockerfile
|
||||
tags: ghcr.io/acouvreur/sablier:local
|
||||
outputs: type=docker,dest=/tmp/sablier.tar
|
||||
|
||||
- name: Upload artifact
|
||||
uses: actions/upload-artifact@v2
|
||||
with:
|
||||
name: sablier-image-tar
|
||||
path: /tmp/sablier.tar
|
||||
|
||||
traefik:
|
||||
name: Build Sablier for Traefik middleware
|
||||
runs-on: ubuntu-latest
|
||||
@@ -29,6 +53,7 @@ jobs:
|
||||
traefik_e2e:
|
||||
name: Run Sablier E2E tests for Traefik middleware
|
||||
runs-on: ubuntu-latest
|
||||
needs: build
|
||||
strategy:
|
||||
fail-fast: false
|
||||
matrix:
|
||||
@@ -42,22 +67,17 @@ jobs:
|
||||
- name: Checkout code
|
||||
uses: actions/checkout@v2
|
||||
|
||||
- name: Set up QEMU
|
||||
uses: docker/setup-qemu-action@v2
|
||||
|
||||
- name: Set up Docker Buildx
|
||||
uses: docker/setup-buildx-action@v2
|
||||
|
||||
- name: Download artifact
|
||||
uses: actions/download-artifact@v2
|
||||
with:
|
||||
version: latest
|
||||
buildkitd-flags: --debug
|
||||
-
|
||||
name: Build and push
|
||||
id: docker_build
|
||||
uses: docker/build-push-action@v2
|
||||
with:
|
||||
load: true
|
||||
context: .
|
||||
tags: ghcr.io/acouvreur/sablier:local
|
||||
name: sablier-image-tar
|
||||
path: /tmp
|
||||
|
||||
- name: Load Docker image
|
||||
run: docker load --input /tmp/sablier.tar
|
||||
|
||||
- name: Test ${{ matrix.provider }}
|
||||
run: cd plugins/traefik/e2e && bash ./${{ matrix.provider }}.sh
|
||||
Reference in New Issue
Block a user