cleaner registry name and url
This commit is contained in:
@@ -24,25 +24,24 @@ on:
|
|||||||
|
|
||||||
env:
|
env:
|
||||||
IMAGE_NAME: zola-pwsh-s3
|
IMAGE_NAME: zola-pwsh-s3
|
||||||
|
REGISTRY_URL: ${{ gitea.server_url }}
|
||||||
|
REGISTRY_HOST: ${{ replace(replace(gitea.server_url, 'https://', ''), 'http://', '') }}
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
build-container:
|
build-container:
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
env:
|
|
||||||
# Strip protocol from server URL for registry usage
|
|
||||||
REGISTRY: ${{ replace(gitea.server_url, 'https://', '') }}
|
|
||||||
|
|
||||||
steps:
|
steps:
|
||||||
- name: Checkout repository
|
- name: Checkout repository
|
||||||
uses: actions/checkout@v4
|
uses: actions/checkout@v4
|
||||||
|
|
||||||
- name: Set up Docker Buildx
|
- name: Set up Docker Build
|
||||||
uses: docker/setup-buildx-action@v3
|
uses: docker/setup-buildx-action@v3
|
||||||
|
|
||||||
- name: Login to Gitea Container Registry
|
- name: Login to Gitea Container Registry
|
||||||
uses: docker/login-action@v3
|
uses: docker/login-action@v3
|
||||||
with:
|
with:
|
||||||
registry: https://${{ env.REGISTRY }}
|
registry: ${{ env.REGISTRY_HOST }}
|
||||||
username: ${{ gitea.actor }}
|
username: ${{ gitea.actor }}
|
||||||
password: ${{ secrets.CONTAINER_TOKEN }}
|
password: ${{ secrets.CONTAINER_TOKEN }}
|
||||||
|
|
||||||
@@ -50,7 +49,7 @@ jobs:
|
|||||||
id: meta
|
id: meta
|
||||||
uses: docker/metadata-action@v5
|
uses: docker/metadata-action@v5
|
||||||
with:
|
with:
|
||||||
images: ${{ env.REGISTRY }}/${{ gitea.repository }}/${{ env.IMAGE_NAME }}
|
images: ${{ env.REGISTRY_HOST }}/${{ gitea.repository }}/${{ env.IMAGE_NAME }}
|
||||||
tags: |
|
tags: |
|
||||||
type=raw,value=latest
|
type=raw,value=latest
|
||||||
type=sha,prefix=
|
type=sha,prefix=
|
||||||
|
|||||||
Reference in New Issue
Block a user