update
This commit is contained in:
parent
1171de80a3
commit
14bb24e33a
@ -16,14 +16,15 @@ jobs:
|
||||
uses: docker/setup-buildx-action@v3
|
||||
|
||||
- name: Log in to Gitea registry
|
||||
if: ${{ secrets.GITEA_REGISTRY_USERNAME != '' && secrets.GITEA_REGISTRY_PASSWORD != '' }}
|
||||
if: ${{ secrets.REGISTRY_USERNAME != '' && secrets.REGISTRY_PASSWORD != '' }}
|
||||
uses: docker/login-action@v3
|
||||
with:
|
||||
registry: git.kogami.xyz
|
||||
username: ${{ secrets.GITEA_REGISTRY_USERNAME }}
|
||||
password: ${{ secrets.GITEA_REGISTRY_PASSWORD }}
|
||||
username: ${{ secrets.REGISTRY_USERNAME }}
|
||||
password: ${{ secrets.REGISTRY_PASSWORD }}
|
||||
|
||||
- name: Build image
|
||||
- name: Build image (with registry cache)
|
||||
if: ${{ secrets.REGISTRY_USERNAME != '' && secrets.REGISTRY_PASSWORD != '' }}
|
||||
uses: docker/build-push-action@v6
|
||||
with:
|
||||
context: .
|
||||
@ -34,6 +35,16 @@ jobs:
|
||||
cache-from: type=registry,ref=git.kogami.xyz/foglar/matrix-bot:buildcache
|
||||
cache-to: type=registry,ref=git.kogami.xyz/foglar/matrix-bot:buildcache,mode=max
|
||||
|
||||
- name: Build image (no registry cache)
|
||||
if: ${{ secrets.REGISTRY_USERNAME == '' || secrets.REGISTRY_PASSWORD == '' }}
|
||||
uses: docker/build-push-action@v6
|
||||
with:
|
||||
context: .
|
||||
platforms: linux/arm64
|
||||
push: false
|
||||
load: true
|
||||
tags: matrix-bot:latest
|
||||
|
||||
- name: Run container
|
||||
env:
|
||||
MATRIX_HOMESERVER: ${{ secrets.MATRIX_HOMESERVER }}
|
||||
|
||||
Loading…
Reference in New Issue
Block a user