mirror of
https://github.com/pixelfed/pixelfed.git
synced 2024-11-09 16:24:51 +00:00
push build cache to registry as well
This commit is contained in:
parent
ae358e47cb
commit
9c26bf26dd
1 changed files with 22 additions and 1 deletions
23
.github/workflows/docker.yml
vendored
23
.github/workflows/docker.yml
vendored
|
@ -173,6 +173,27 @@ jobs:
|
||||||
env:
|
env:
|
||||||
DOCKER_METADATA_ANNOTATIONS_LEVELS: manifest,index
|
DOCKER_METADATA_ANNOTATIONS_LEVELS: manifest,index
|
||||||
|
|
||||||
|
- name: Docker meta (Cache))
|
||||||
|
uses: docker/metadata-action@v5
|
||||||
|
id: cache
|
||||||
|
with:
|
||||||
|
images: |
|
||||||
|
name=ghcr.io/${{ github.repository }}-cache,enable=true
|
||||||
|
name=${{ env.DOCKER_HUB_ORGANISATION }}/${{ env.DOCKER_HUB_REPO }}-cache,enable=${{ env.HAS_DOCKER_HUB_CONFIGURED }}
|
||||||
|
flavor: |
|
||||||
|
latest=auto
|
||||||
|
suffix=-${{ matrix.target_runtime }}-${{ matrix.php_version }}
|
||||||
|
tags: |
|
||||||
|
type=raw,value=dev,enable=${{ github.ref == format('refs/heads/{0}', 'dev') }}
|
||||||
|
type=raw,value=staging,enable=${{ github.ref == format('refs/heads/{0}', 'staging') }}
|
||||||
|
type=pep440,pattern={{raw}}
|
||||||
|
type=pep440,pattern=v{{major}}.{{minor}}
|
||||||
|
type=ref,event=branch,prefix=branch-
|
||||||
|
type=ref,event=pr,prefix=pr-
|
||||||
|
type=ref,event=tag
|
||||||
|
env:
|
||||||
|
DOCKER_METADATA_ANNOTATIONS_LEVELS: manifest,index
|
||||||
|
|
||||||
- name: Build and push Docker image
|
- name: Build and push Docker image
|
||||||
uses: docker/build-push-action@v5
|
uses: docker/build-push-action@v5
|
||||||
with:
|
with:
|
||||||
|
@ -193,7 +214,7 @@ jobs:
|
||||||
type=gha,scope=${{ matrix.target_runtime }}-${{ matrix.php_base }}-${{ matrix.php_version }}
|
type=gha,scope=${{ matrix.target_runtime }}-${{ matrix.php_base }}-${{ matrix.php_version }}
|
||||||
cache-to: |
|
cache-to: |
|
||||||
type=gha,mode=max,scope=${{ matrix.target_runtime }}-${{ matrix.php_base }}-${{ matrix.php_version }}
|
type=gha,mode=max,scope=${{ matrix.target_runtime }}-${{ matrix.php_base }}-${{ matrix.php_version }}
|
||||||
type=registry,ref=ghcr.io/${{ github.repository }}-cache:${{ steps.meta.outputs.tags }}
|
${{ steps.cache.outputs.tags }}
|
||||||
|
|
||||||
# goss validate the image
|
# goss validate the image
|
||||||
#
|
#
|
||||||
|
|
Loading…
Reference in a new issue