Use marketplace actions
This commit is contained in:
parent
f420e5cc97
commit
82c488ed75
1 changed files with 20 additions and 10 deletions
|
@ -13,18 +13,28 @@ jobs:
|
||||||
build:
|
build:
|
||||||
runs-on: self-hosted
|
runs-on: self-hosted
|
||||||
steps:
|
steps:
|
||||||
- run: echo $${{ github.token }} | docker login --username flohoss --password-stdin ${{ env.REGISTRY }}
|
- name: Checkout repository
|
||||||
- run: |
|
uses: actions/checkout@v4
|
||||||
docker build \
|
- name: Login to GitHub Container Registry
|
||||||
--build-arg V_GOLANG=${{ vars.V_GOLANG }} \
|
uses: docker/login-action@v3
|
||||||
--build-arg V_NODE=${{ vars.V_NODE }} \
|
with:
|
||||||
--build-arg V_ALPINE=${{ vars.V_ALPINE }} \
|
registry: ghcr.io
|
||||||
--tag ${{ env.LATEST_IMAGE }} \
|
username: ${{ github.actor }}
|
||||||
--push .
|
password: ${{ github.token }}
|
||||||
|
- name: Set up Docker Buildx
|
||||||
|
uses: docker/setup-buildx-action@v3
|
||||||
|
- name: Build and push
|
||||||
|
uses: docker/build-push-action@v6
|
||||||
|
with:
|
||||||
|
push: true
|
||||||
|
tags: ${{ env.LATEST_IMAGE }}
|
||||||
|
build-args: |
|
||||||
|
V_GOLANG=${{ vars.V_GOLANG }}
|
||||||
|
V_NODE=${{ vars.V_NODE }}
|
||||||
|
V_ALPINE=${{ vars.V_ALPINE }}
|
||||||
|
|
||||||
cleanup:
|
cleanup:
|
||||||
runs-on: self-hosted
|
runs-on: self-hosted
|
||||||
needs: build
|
needs: build
|
||||||
steps:
|
steps:
|
||||||
- run: |
|
- run: docker system prune -a -f
|
||||||
docker system prune -a -f
|
|
||||||
|
|
Loading…
Reference in a new issue