Skip to content

Commit

Permalink
ci: only push to ghcr and use owner variable
Browse files Browse the repository at this point in the history
  • Loading branch information
gartnera committed Sep 26, 2024
1 parent dfecde3 commit e0cc984
Showing 1 changed file with 3 additions and 9 deletions.
12 changes: 3 additions & 9 deletions .github/workflows/docker-master.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ name: Build and Publish Docker Images after push to master branch
on:
push:
branches: [master]
workflow_dispatch:

jobs:
build-and-push-docker-image:
Expand All @@ -24,17 +25,10 @@ jobs:
uses: docker/metadata-action@v3
with:
images: |
lablabs/cloudflare_exporter
ghcr.io/lablabs/cloudflare_exporter
ghcr.io/${{ github.repository_owner }}/cloudflare_exporter
# generate Docker tags based on the following events/attributes
tags: type=raw,value=latest

- name: Login to DockerHub
uses: docker/login-action@v3
with:
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_TOKEN }}


- name: Login to Github Packages
uses: docker/login-action@v3
with:
Expand Down

0 comments on commit e0cc984

Please sign in to comment.