From 0395091d44f8da7a128e4e9226b4d3cf0eeafe84 Mon Sep 17 00:00:00 2001 From: Daniel Gibbs Date: Sat, 8 Feb 2025 18:26:52 +0000 Subject: [PATCH] test --- .github/workflows/docker-publish.yml | 32 ++++++++++++++++++++++------ 1 file changed, 25 insertions(+), 7 deletions(-) diff --git a/.github/workflows/docker-publish.yml b/.github/workflows/docker-publish.yml index f7911aa..18e7b24 100644 --- a/.github/workflows/docker-publish.yml +++ b/.github/workflows/docker-publish.yml @@ -12,6 +12,11 @@ jobs: build-ubuntu-2404: name: Build Ubuntu 24.04 runs-on: ubuntu-latest + permissions: + packages: write + contents: read + attestations: write + id-token: write steps: - name: Checkout uses: actions/checkout@v4 @@ -19,13 +24,7 @@ jobs: - name: Setup QEMU uses: docker/setup-qemu-action@v3 - - name: Setup Docker Buildx - uses: docker/setup-buildx-action@v3 - - - name: Build - run: docker build -t gameservermanagers/steamcmd:ubuntu-24.04 -f ./Dockerfile.ubuntu-2404 . - - - name: Login to DockerHub + - name: Login to Docker Hub uses: docker/login-action@v3 with: username: ${{ secrets.DOCKER_HUB_USERNAME }} @@ -38,6 +37,15 @@ jobs: username: ${{ github.actor }} password: ${{ secrets.GITHUB_TOKEN }} + - name: Setup Docker Buildx + uses: docker/setup-buildx-action@v3 + + - name: Extract metadata (tags, labels) for Docker + id: meta + uses: docker/metadata-action@9ec57ed1fcdbf14dcef7dfbe97b2010124a938b7 + with: + images: my-docker-hub-namespace/my-docker-hub-repository + - name: Build and push (Ubuntu 24.04) uses: docker/build-push-action@v6 with: @@ -56,6 +64,11 @@ jobs: build-ubuntu-2204: name: Build Ubuntu 22.04 runs-on: ubuntu-latest + permissions: + packages: write + contents: read + attestations: write + id-token: write steps: - name: Checkout uses: actions/checkout@v4 @@ -96,6 +109,11 @@ jobs: build-ubuntu-2004: name: Build Ubuntu 20.04 runs-on: ubuntu-latest + permissions: + packages: write + contents: read + attestations: write + id-token: write steps: - name: Checkout uses: actions/checkout@v4