mirror of
https://github.com/Cockatrice/Cockatrice.git
synced 2025-12-05 20:39:59 -08:00
* Update Dockerfile Took 15 minutes Took 43 seconds Took 2 minutes Took 13 seconds Took 3 minutes Took 4 minutes Took 51 seconds * Update docker-release.yml * Update Dockerfile * Update Dockerfile * Update Dockerfile * Update Dockerfile * Update Dockerfile * Update Dockerfile * Update Dockerfile * Update Dockerfile * Update Dockerfile * Update Dockerfile * Multi stage build. Took 11 minutes * Add more arguments. Took 8 minutes * Remove apt cache. Took 3 minutes * Add workdir, undo tcp socket include. Took 10 minutes * Change runtime deps. Took 8 minutes --------- Co-authored-by: Lukas Brübach <Bruebach.Lukas@bdosecurity.de>
67 lines
1.9 KiB
YAML
67 lines
1.9 KiB
YAML
name: Build Docker Image
|
|
|
|
on:
|
|
push:
|
|
tags:
|
|
- '*Release*'
|
|
branches:
|
|
- master
|
|
pull_request:
|
|
branches:
|
|
- master
|
|
paths:
|
|
- '.github/workflows/docker-release.yml'
|
|
- 'Dockerfile'
|
|
|
|
jobs:
|
|
docker:
|
|
name: amd64 & arm64
|
|
runs-on: ubuntu-latest
|
|
permissions:
|
|
contents: read
|
|
packages: write
|
|
|
|
steps:
|
|
- name: Checkout
|
|
uses: actions/checkout@v5
|
|
|
|
- name: Docker metadata
|
|
id: metadata
|
|
uses: docker/metadata-action@v5
|
|
with:
|
|
images: |
|
|
ghcr.io/cockatrice/servatrice
|
|
labels: |
|
|
org.opencontainers.image.title=Servatrice
|
|
org.opencontainers.image.url=https://cockatrice.github.io/
|
|
org.opencontainers.image.description=Server for Cockatrice, a cross-platform virtual tabletop for multiplayer card games
|
|
annotations: |
|
|
org.opencontainers.image.title=Servatrice
|
|
org.opencontainers.image.url=https://cockatrice.github.io/
|
|
org.opencontainers.image.description=Server for Cockatrice, a cross-platform virtual tabletop for multiplayer card games
|
|
|
|
- name: Set up QEMU
|
|
uses: docker/setup-qemu-action@v3
|
|
|
|
- name: Set up Docker buildx
|
|
uses: docker/setup-buildx-action@v3
|
|
|
|
- name: Login to GitHub Container Registry
|
|
if: github.ref_type == 'tag'
|
|
uses: docker/login-action@v3
|
|
with:
|
|
registry: ghcr.io
|
|
username: ${{ github.actor }}
|
|
password: ${{ github.token }}
|
|
|
|
- name: Build and push Docker image
|
|
uses: docker/build-push-action@v6
|
|
with:
|
|
context: .
|
|
platforms: linux/amd64,linux/arm64
|
|
push: ${{ github.ref_type == 'tag' }}
|
|
tags: ${{ steps.metadata.outputs.tags }}
|
|
labels: ${{ steps.metadata.outputs.labels }}
|
|
cache-from: type=gha
|
|
cache-to: type=gha,mode=max
|