mirror of
https://github.com/processone/ejabberd.git
synced 2024-11-24 16:23:40 +01:00
d504ed8a9b
Bumps [docker/build-push-action](https://github.com/docker/build-push-action) from 3 to 4. - [Release notes](https://github.com/docker/build-push-action/releases) - [Commits](https://github.com/docker/build-push-action/compare/v3...v4) --- updated-dependencies: - dependency-name: docker/build-push-action dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] <support@github.com>
76 lines
2.0 KiB
YAML
76 lines
2.0 KiB
YAML
name: Container
|
|
|
|
on:
|
|
push:
|
|
paths-ignore:
|
|
- '.devcontainer/**'
|
|
- 'examples/**'
|
|
- 'lib/**'
|
|
- 'man/**'
|
|
- 'priv/**'
|
|
- '**.md'
|
|
|
|
env:
|
|
REGISTRY: ghcr.io
|
|
IMAGE_NAME: ${{ github.repository }}
|
|
|
|
jobs:
|
|
container:
|
|
name: Container
|
|
runs-on: ubuntu-latest
|
|
permissions:
|
|
packages: write
|
|
steps:
|
|
|
|
- name: Check out repository code
|
|
uses: actions/checkout@v3
|
|
with:
|
|
fetch-depth: 0
|
|
|
|
- name: Checkout ejabberd-contrib
|
|
uses: actions/checkout@v3
|
|
with:
|
|
repository: processone/ejabberd-contrib
|
|
path: .ejabberd-modules/sources/ejabberd-contrib
|
|
|
|
- name: Log in to the Container registry
|
|
uses: docker/login-action@v2
|
|
with:
|
|
registry: ${{ env.REGISTRY }}
|
|
username: ${{ github.actor }}
|
|
password: ${{ secrets.GITHUB_TOKEN }}
|
|
|
|
- name: Get git describe
|
|
id: gitdescribe
|
|
run: echo "ver=$(git describe --tags)" >> $GITHUB_OUTPUT
|
|
|
|
- name: Extract metadata (tags, labels) for Docker
|
|
id: meta
|
|
uses: docker/metadata-action@v4
|
|
with:
|
|
images: ${{ env.REGISTRY }}/${{ env.IMAGE_NAME }}
|
|
labels: |
|
|
org.opencontainers.image.revision=${{ steps.gitdescribe.outputs.ver }}
|
|
org.opencontainers.image.licenses=GPL-2.0
|
|
org.opencontainers.image.vendor=ProcessOne
|
|
|
|
- name: Set up QEMU
|
|
uses: docker/setup-qemu-action@v2
|
|
|
|
- name: Set up Docker Buildx
|
|
uses: docker/setup-buildx-action@v2
|
|
|
|
- name: Build and push Docker image
|
|
uses: docker/build-push-action@v4
|
|
with:
|
|
build-args: |
|
|
VERSION=${{ steps.gitdescribe.outputs.ver }}
|
|
cache-from: type=gha
|
|
cache-to: type=gha,mode=max
|
|
context: .
|
|
file: .github/container/Dockerfile
|
|
labels: ${{ steps.meta.outputs.labels }}
|
|
platforms: linux/amd64,linux/arm64
|
|
push: true
|
|
tags: ${{ steps.meta.outputs.tags }}
|