Skip to content

Commit

Permalink
Create docker-publish-hub.yml
Browse files Browse the repository at this point in the history
  • Loading branch information
BattlefieldDuck committed Nov 2, 2024
1 parent 034624a commit dfde3f1
Showing 1 changed file with 43 additions and 0 deletions.
43 changes: 43 additions & 0 deletions .github/workflows/docker-publish-hub.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,43 @@
name: Publish Docker Image (Hub)

on:
workflow_dispatch:
schedule:
- cron: '0 0 * * *'

env:
IMAGE_NAME: doctorserver/steamcmd

jobs:
build:
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v4

- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v3

- name: Log in to the Container registry
uses: docker/login-action@v3
with:
username: ${{ secrets.DOCKER_USERNAME }}
password: ${{ secrets.DOCKER_PASSWORD }}

- name: Extract metadata (tags, labels) for Docker
id: meta
uses: docker/metadata-action@v5
with:
images: ${{ env.IMAGE_NAME }}
tags: |
type=raw,value=latest
- name: Push Docker image
uses: docker/build-push-action@v6
with:
context: .
push: true
provenance: false
tags: ${{ steps.meta.outputs.tags }}
labels: ${{ steps.meta.outputs.labels }}
annotations: ${{ steps.meta.outputs.annotations }}

0 comments on commit dfde3f1

Please sign in to comment.