66 lines
1.6 KiB
YAML
66 lines
1.6 KiB
YAML
name: Publish Feature Branch
|
|
|
|
on:
|
|
push:
|
|
branches:
|
|
- main
|
|
- feature-**
|
|
- release/*
|
|
|
|
jobs:
|
|
publish-feature:
|
|
runs-on: ubuntu-latest
|
|
strategy:
|
|
matrix:
|
|
targets:
|
|
- backend
|
|
- frontend
|
|
- onlyoffice-connector
|
|
- ldap-sync
|
|
- nextcloud-migration
|
|
fail-fast: false
|
|
steps:
|
|
- name: Checkout
|
|
uses: actions/checkout@v4
|
|
|
|
- name: Set up QEMU
|
|
uses: docker/setup-qemu-action@v3
|
|
|
|
- name: Set up Docker Buildx
|
|
uses: docker/setup-buildx-action@v3
|
|
with:
|
|
version: v0.19.0
|
|
|
|
- name: Echo
|
|
run: echo Publish images with tag ${{ github.head_ref || github.ref_name }}
|
|
|
|
- name: Docker meta
|
|
id: meta
|
|
uses: docker/metadata-action@v5
|
|
with:
|
|
tags: |
|
|
${{ github.head_ref || github.ref_name }}
|
|
|
|
- name: Login to Docker Hub
|
|
uses: docker/login-action@v3
|
|
with:
|
|
username: ${{ secrets.DOCKERHUB_USERNAME }}
|
|
password: ${{ secrets.DOCKERHUB_PASSWORD }}
|
|
|
|
- name: Login to Linagora Registry
|
|
uses: docker/login-action@v3
|
|
with:
|
|
registry: docker-registry.linagora.com
|
|
username: ${{ secrets.REGISTRY_USERNAME }}
|
|
password: ${{ secrets.REGISTRY_PASSWORD }}
|
|
|
|
- name: Build and push
|
|
uses: docker/bake-action@v6
|
|
with:
|
|
files: |
|
|
./docker-bake.hcl
|
|
${{ steps.meta.outputs.bake-file-annotations }}
|
|
${{ steps.meta.outputs.bake-file }}
|
|
push: true
|
|
targets: ${{ matrix.targets }}
|