Merge pull request #5 from aoudiamoncef/dev #5
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Docker Image CI | |
on: | |
push: | |
branches: | |
- 'main' | |
pull_request: | |
branches: | |
- 'main' | |
jobs: | |
build-check: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout repository | |
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 | |
- name: Extract metadata (tags, labels) for Docker | |
id: meta | |
uses: docker/metadata-action@v5 | |
with: | |
images: | | |
aoudiamoncef/ubuntu-sshd | |
ghcr.io/${{ github.repository }}/ubuntu-sshd | |
- name: Build Docker image | |
uses: docker/build-push-action@v6 | |
with: | |
context: . | |
push: false | |
tags: aoudiamoncef/ubuntu-sshd:pr-${{ github.event.number }} | |
labels: ${{ steps.meta.outputs.labels }} |