Skip to content

chore: added test file #4

chore: added test file

chore: added test file #4

Workflow file for this run

name: CI
on:
push:
branches:
- main
- develop
tags:
- v*.*.*
env:
REGISTRY: docker.io
IMAGE_NAME: 4lch4/narb
IMAGE_TAG: ${{ github.ref == 'refs/heads/main' && 'latest' || github.ref == 'refs/heads/develop' && 'dev' || github.ref == 'refs/tags/v*' && github.ref }}
jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v3
- name: Setup Docker buildx
uses: docker/setup-buildx-action@v1
- name: Log into registry
if: github.event_name != 'pull_request'
uses: docker/login-action@v2
with:
username: 4lch4
password: ${{ secrets.DOCKER_HUB_TOKEN }}
- name: Extract Docker metadata
id: meta
uses: docker/metadata-action@v4
with:
images: ${{ env.REGISTRY }}/${{ env.IMAGE_NAME }}
- name: Build and push Docker image
id: build-and-push
uses: docker/build-push-action@v2
with:
context: .
push: ${{ github.event_name != 'pull_request' }}
tags: ${{ env.IMAGE_TAG }}
labels: ${{ steps.meta.outputs.labels }}
cache-from: type=gha
cache-to: type=gha,mode=max