Skip to content

Commit 8434a6c

Browse files
committed
dependabot go module support
1 parent e67e877 commit 8434a6c

2 files changed

Lines changed: 10 additions & 6 deletions

File tree

.github/workflows/.github/dependabot.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3,10 +3,10 @@ updates:
33
- package-ecosystem: "gomod" # For Go modules
44
directory: "/" # Location of go.mod
55
schedule:
6-
interval: "monthly" # Check for updates weekly (or daily, monthly)
7-
open-pull-requests-limit: 10 # Max number of open PRs
6+
interval: "monthly" # Check weekly (adjust to daily/monthly as needed)
7+
open-pull-requests-limit: 10 # Max concurrent PRs
88
commit-message:
99
prefix: "deps" # Prefix for commit messages
1010
include: "scope" # Include scope in commit message
1111
labels:
12-
- "dependencies" # Add label to PRs
12+
- "dependencies" # Label for PRs

.github/workflows/docker-build-push.yml

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,9 @@ on:
44
push:
55
branches:
66
- master
7+
pull_request:
8+
branches:
9+
- master # Trigger on PRs to master (e.g., Dependabot PRs)
710

811
jobs:
912
build-and-push:
@@ -13,7 +16,7 @@ jobs:
1316
uses: actions/checkout@v4
1417

1518
- name: Set up QEMU
16-
uses: docker/setup-qemu-action@v3 # For potential multi-arch support
19+
uses: docker/setup-qemu-action@v3 # Required for multi-arch builds
1720

1821
- name: Set up Docker Buildx
1922
uses: docker/setup-buildx-action@v3
@@ -23,11 +26,12 @@ jobs:
2326
with:
2427
username: ${{ secrets.DOCKERHUB_USERNAME }}
2528
password: ${{ secrets.DOCKERHUB_TOKEN }}
29+
if: github.event_name == 'push' # Only login for push events
2630

2731
- name: Build and push Docker image
2832
uses: docker/build-push-action@v6
2933
with:
3034
context: .
31-
platforms: linux/amd64,linux/arm64 # Multi-arch
32-
push: true
35+
platforms: linux/amd64,linux/arm64 # Multi-arch support
36+
push: ${{ github.event_name == 'push' }} # Push only on push events
3337
tags: ${{ secrets.DOCKERHUB_USERNAME }}/goduckbot:latest

0 commit comments

Comments
 (0)