Skip to content

Merge branch 'main' into release #79

Merge branch 'main' into release

Merge branch 'main' into release #79

Workflow file for this run

name: Docker Image CI
on:
push:
branches: [ "release" ]
env:
IMAGE_NAME: ${{ github.repository }}
jobs:
build-and-push-image:
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v4
- name: Get current date
run: echo "CURRENT_DATE=$(date +'%Y-%m-%d')" >> $GITHUB_ENV
- name: Get short commit hash
run: echo "SHORT_COMMIT=$(echo $GITHUB_SHA | cut -c 1-7)" >> $GITHUB_ENV
- name: Docker meta
id: meta
uses: docker/metadata-action@v5
with:
images: maxscw/basler-camera-adapter
tags: |
latest
sha$${{ github.sha }}
sha$${{ env.SHORT_COMMIT }}
date$${{ env.CURRENT_DATE }}
v0.6.5
- name: Login to Docker Hub
uses: docker/login-action@v3
with:
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_ACCESS_TOKEN }}
- name: Build and push
uses: docker/build-push-action@v6
with:
context: .
file: BaslerCameraAdapter.Dockerfile
push: true
tags: ${{ steps.meta.outputs.tags }}
labels: ${{ steps.meta.outputs.labels }}