Update dependencies and improve Docker image build workflow
Some checks failed
Build docker image / Build-Docker-Image (push) Has been cancelled

- Update Rust dependencies in Cargo.lock to latest versions - Add git
SHA tag to Docker image for traceability - Pass deployment hook the
built image tag for improved automation - Refactor GitHub Actions YAML
for cleaner syntax
This commit is contained in:
2025-06-21 23:24:53 +02:00
parent a6044a1734
commit 673d014cf5
2 changed files with 564 additions and 404 deletions

View File

@@ -3,18 +3,16 @@ name: Build docker image
on:
push:
branches:
- 'main'
- "main"
jobs:
Build-Docker-Image:
runs-on: ubuntu-latest
steps:
-
name: Checkout
- name: Checkout
uses: actions/checkout@v4
-
name: Set up Docker Buildx
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v3
- id: repository_name
@@ -22,16 +20,14 @@ jobs:
with:
string: ${{ github.repository }}
-
name: Login to ghcr.io
- name: Login to ghcr.io
uses: docker/login-action@v3
with:
registry: ghcr.io
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}
-
name: Build and push
- name: Build and push
id: docker_build
uses: docker/build-push-action@v6
env:
@@ -39,12 +35,11 @@ jobs:
with:
push: true
platforms: linux/amd64
tags: ghcr.io/${{ env.IMAGE }}:latest
tags: ghcr.io/${{ env.IMAGE }}:latest,ghcr.io/${{ env.IMAGE }}:${{ github.sha }}
context: .
file: ./docker/build.dockerfile
-
name: Invoke deployment hook
- name: Invoke deployment hook
uses: joelwmale/webhook-action@master
with:
url: ${{ secrets.WEBHOOK_URL }}
url: ${{ secrets.WEBHOOK_URL }}?USERS_SETTINGS_SERVER_TAG=${{ github.sha }}