Skip to content

Merge pull request #21 from dlcs/feature/jp2_only #26

Merge pull request #21 from dlcs/feature/jp2_only

Merge pull request #21 from dlcs/feature/jp2_only #26

Workflow file for this run

name: Build and push Appetiser docker image
on:
push:
branches:
- master
tags:
- "*"
pull_request:
jobs:
build-push:
runs-on: ubuntu-latest
steps:
- name: Set up Docker Buildx
id: buildx
uses: docker/setup-buildx-action@v1
- name: Cache Docker layers
uses: actions/cache@v3
with:
path: /tmp/.buildx-cache
key: ${{ runner.os }}-buildx-${{ github.sha }}
restore-keys: |
${{ runner.os }}-buildx-
- name: Check out code
id: checkout
uses: actions/checkout@v3
- name: Login to GitHub Container Registry
uses: docker/login-action@v2
with:
registry: ghcr.io
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}
- name: Docker meta
id: docker_meta
uses: docker/metadata-action@v4
with:
images: ghcr.io/dlcs/appetiser
tags: |
type=ref,event=branch
type=ref,event=pr
type=semver,pattern={{version}}
type=semver,pattern={{major}}.{{minor}}
type=sha,enable=true,prefix=,format=long
- name: Build and push
id: docker_build
uses: docker/build-push-action@v2
with:
context: .
builder: ${{ steps.buildx.outputs.name }}
push: true
labels: ${{ steps.docker_meta.outputs.labels }}
tags: ${{ steps.docker_meta.outputs.tags }}