ProfouzorsLinx/.github/workflows/build.yaml

37 lines
868 B
YAML
Raw Normal View History

2022-06-25 14:02:10 +02:00
name: build
on:
push:
2022-06-25 14:01:06 +02:00
branches:
- master
tags:
2020-08-14 09:39:53 +02:00
- 'v*'
jobs:
2022-06-25 14:02:10 +02:00
build:
runs-on: ubuntu-latest
steps:
2022-06-25 14:01:06 +02:00
- name: Checkout
uses: actions/checkout@v2
2022-06-25 14:01:06 +02:00
2022-06-25 14:10:04 +02:00
- name: Docker meta
id: meta
uses: docker/metadata-action@v4
with:
images: ghcr.io/${{ github.repository_owner }}/linx-server
2022-06-25 14:01:06 +02:00
- name: Login to GHCR
uses: docker/login-action@v2
if: github.event_name != 'pull_request'
with:
registry: ghcr.io
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}
2022-06-25 14:10:04 +02:00
- name: Build and push
uses: docker/build-push-action@v3
with:
context: .
push: ${{ github.event_name != 'pull_request' }}
tags: ${{ steps.meta.outputs.tags }}
labels: ${{ steps.meta.outputs.labels }}