mirror of
https://github.com/typemill/typemill.git
synced 2025-07-25 00:02:28 +02:00
Create docker-image.yml
Automatically create and push an image to docker
This commit is contained in:
32
.github/workflows/docker-image.yml
vendored
Normal file
32
.github/workflows/docker-image.yml
vendored
Normal file
@@ -0,0 +1,32 @@
|
||||
name: Build and Push Docker Image on Release
|
||||
|
||||
on:
|
||||
push:
|
||||
tags:
|
||||
- 'v*.*.*' # Triggers only on semantic version tags like v2.2.2
|
||||
|
||||
jobs:
|
||||
build-and-push:
|
||||
runs-on: ubuntu-latest
|
||||
|
||||
steps:
|
||||
- name: Checkout code
|
||||
uses: actions/checkout@v4
|
||||
|
||||
- name: Set up Docker Buildx
|
||||
uses: docker/setup-buildx-action@v3
|
||||
|
||||
- name: Log in to Docker Hub
|
||||
uses: docker/login-action@v3
|
||||
with:
|
||||
username: ${{ secrets.DOCKER_USERNAME }}
|
||||
password: ${{ secrets.DOCKER_PASSWORD }}
|
||||
|
||||
- name: Build and push Docker image
|
||||
uses: docker/build-push-action@v5
|
||||
with:
|
||||
context: .
|
||||
push: true
|
||||
tags: |
|
||||
kixote/typemill:${{ github.ref_name }}
|
||||
kixote/typemill:latest
|
Reference in New Issue
Block a user