This commit is contained in:
parent
379ec94274
commit
2721ceb82c
1 changed files with 16 additions and 21 deletions
|
@ -8,7 +8,6 @@ on:
|
||||||
- main
|
- main
|
||||||
|
|
||||||
env:
|
env:
|
||||||
REGISTRY: forge.niblock.tech
|
|
||||||
REGISTRY_USERNAME: ${{ github.actor }}
|
REGISTRY_USERNAME: ${{ github.actor }}
|
||||||
REGISTRY_PASSWORD: ${{ secrets.REGISTRY_TOKEN }}
|
REGISTRY_PASSWORD: ${{ secrets.REGISTRY_TOKEN }}
|
||||||
REGISTRY_IMAGE_NAME: ${{ github.repository }}
|
REGISTRY_IMAGE_NAME: ${{ github.repository }}
|
||||||
|
@ -20,25 +19,21 @@ jobs:
|
||||||
steps:
|
steps:
|
||||||
- name: Checkout the repository
|
- name: Checkout the repository
|
||||||
uses: actions/checkout@v4
|
uses: actions/checkout@v4
|
||||||
|
|
||||||
- name: Login to the GitHub Container Registry
|
- name: Build the container image using Buildah
|
||||||
uses: actions/docker-login-action@v3
|
id: build-image
|
||||||
|
uses: https://forge.niblock.tech/actions/buildah-build@v2
|
||||||
with:
|
with:
|
||||||
registry: ${{ env.REGISTRY }}
|
image: alpine
|
||||||
|
tags: latest
|
||||||
|
containerfiles: ./docker/latest/Dockerfile
|
||||||
|
|
||||||
|
- name: Publish to NibTech Forge Registry
|
||||||
|
id: publish-image
|
||||||
|
uses: https://forge.niblock.tech/actions/push-to-registry@v2
|
||||||
|
with:
|
||||||
|
image: ${{ steps.build-image.outputs.image }}
|
||||||
|
tags: ${{ steps.build-image.outputs.tags }}
|
||||||
|
registry: forge.niblock.tech/containers
|
||||||
username: ${{ env.REGISTRY_USERNAME }}
|
username: ${{ env.REGISTRY_USERNAME }}
|
||||||
password: ${{ env.REGISTRY_PASSWORD }}
|
password: ${{ env.REGISTRY_PASSWORD }}
|
||||||
|
|
||||||
- name: Extract repository metadata (tags, labels)
|
|
||||||
id: meta
|
|
||||||
uses: actions/docker-metadata-action@v5
|
|
||||||
with:
|
|
||||||
images: ${{ env.REGISTRY }}/${{ env.REGISTRY_IMAGE_NAME }}
|
|
||||||
|
|
||||||
- name: Build and publish Alpine Latest
|
|
||||||
uses: actions/docker-build-push-action@v5
|
|
||||||
with:
|
|
||||||
context: .docker/latest
|
|
||||||
push: true
|
|
||||||
tags: |
|
|
||||||
${{ env.REGISTRY }}/${{ env.REGISTRY_IMAGE_NAME }}:latest
|
|
||||||
labels: ${{ steps.meta.outputs.labels }}
|
|
Loading…
Reference in a new issue