Files
CatsOfMastodon/.gitea/workflows/gitea-ci.yml
Mohammad Mahdi Mohammadi 4a1bee3b94
All checks were successful
release / Build and push Docker image (push) Successful in 1m11s
Minor fix
2025-01-04 17:49:42 +03:30

45 lines
1.1 KiB
YAML
Executable File

name: release
on:
push:
branches: [ "main" ]
pull_request:
branches: [ "main" ]
env:
ASPNETCORE_ENVIRONMENT: Production
jobs:
docker:
name: Build and push Docker image
runs-on: ubuntu-latest
permissions:
packages: write
steps:
- name: Checkout repository
uses: actions/checkout@v4
- name: Log in to the Container registry
uses: docker/login-action@v3
with:
registry: git.mahdium.ir
username: ${{ secrets.USERNAME }}
password: ${{ secrets.PASSWORD }}
- name: Extract Docker metadata
id: meta
uses: docker/metadata-action@v5
with:
images: git.mahdium.ir/mahdium/cats-of-mastodon-telegram-bot
- name: Build and push Docker image
uses: docker/build-push-action@v6
with:
context: .
push: true
tags: git.mahdium.ir/mahdium/cats-of-mastodon-telegram-bot:${{gitea.sha}},git.mahdium.ir/mahdium/cats-of-mastodon-telegram-bot:latest
labels: ${{ steps.meta.outputs.labels }}
#tags: ${{ steps.meta.outputs.tags }}
#labels: ${{ steps.meta.outputs.labels }}