ci: migrate to buildkit
This commit is contained in:
parent
3fd6fca3fc
commit
e31918d7a2
1 changed files with 12 additions and 17 deletions
|
@ -13,7 +13,7 @@ concurrency:
|
|||
jobs:
|
||||
publish:
|
||||
if: github.repository == 'teidesu/tei.su' # do not run on forks
|
||||
runs-on: docker-dind
|
||||
runs-on: buildkit
|
||||
permissions:
|
||||
contents: write
|
||||
packages: write
|
||||
|
@ -24,16 +24,10 @@ jobs:
|
|||
- name: Prepare
|
||||
env:
|
||||
DONATE_PAGE_DATA: ${{ vars.DONATE_PAGE_DATA }}
|
||||
run: |
|
||||
echo "$DONATE_PAGE_DATA" > src/components/pages/PageDonate/data.json
|
||||
/opt/start-dockerd.sh
|
||||
run: echo "$DONATE_PAGE_DATA" > src/components/pages/PageDonate/data.json
|
||||
|
||||
- name: Login to GitHub Container Registry
|
||||
uses: docker/login-action@v3
|
||||
with:
|
||||
registry: git.stupid.fish
|
||||
username: ${{ github.actor }}
|
||||
password: ${{ secrets.PACKAGES_PAT }}
|
||||
run: /opt/registry-login.sh git.stupid.fish "${{ github.actor }}" "${{ secrets.PACKAGES_PAT }}"
|
||||
|
||||
- name: Docker meta
|
||||
id: meta
|
||||
|
@ -42,14 +36,15 @@ jobs:
|
|||
images: git.stupid.fish/teidesu/tei.su
|
||||
tags: type=sha
|
||||
flavor: latest=true
|
||||
sep-tags: ',name='
|
||||
- name: Build and push
|
||||
uses: docker/build-push-action@v5
|
||||
with:
|
||||
context: .
|
||||
push: true
|
||||
platforms: linux/amd64
|
||||
tags: ${{ steps.meta.outputs.tags }}
|
||||
labels: ${{ steps.meta.outputs.labels }}
|
||||
run: |
|
||||
buildctl build \
|
||||
--frontend dockerfile.v0 \
|
||||
--local context=. \
|
||||
--local dockerfile=. \
|
||||
--opt platform=amd64 \
|
||||
--output type=image,oci-mediatypes=true,compression=zstd,rewrite-timestamp=true,push=true,name=${{ steps.meta.outputs.tags }}
|
||||
|
||||
deploy:
|
||||
runs-on: node22
|
||||
|
|
Loading…
Reference in a new issue