Create docker-image.yml v1

This commit is contained in:
Kristian Hadzhikolev 2025-04-13 11:58:37 +03:00 committed by GitHub
parent 80753ba147
commit 4f3423a6b9
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

30
.github/workflows/docker-image.yml vendored Normal file
View file

@ -0,0 +1,30 @@
name: Docker Image CI
on:
pull_request:
types: [closed]
branches: [ "master" ]
jobs:
build:
if: github.event.pull_request.merged == true && contains(github.event.pull_request.labels.*.name, 'CI:Build')
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v4
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v2
- name: Login to DockerHub
uses: docker/login-action@v2
with:
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_TOKEN }}
- uses: actions/checkout@v4
- name: Build the Docker image
run: docker build . --file Dockerfile --tag geth-assignment:$(date +%s)