Skip to content

Commit

Permalink
Add GitHub Action to build image
Browse files Browse the repository at this point in the history
  • Loading branch information
navarr committed Dec 17, 2024
1 parent 2a5f535 commit f55d082
Showing 1 changed file with 43 additions and 0 deletions.
43 changes: 43 additions & 0 deletions .github/workflows/ngrok-caddy.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,43 @@
name: Docker Image Ngrok-Caddy
on:
workflow_dispatch:
schedule:
- cron: "0 6 * * *" # 6 am Daily
push:
branches:
- main
paths:
- caddy-ngrok/**
- .github/workflows/ngrok-caddy.yml

jobs:
ngrok-caddy:
name: NGrok Caddy
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v3
- uses: docker/setup-qemu-action@v3
- uses: docker/setup-buildx-action@v3

- name: Login to Github Container Registry
uses: docker/login-action@v2
with:
registry: ghcr.io
username: ${{ github.repository_owner }}
password: ${{ secrets.GITHUB_TOKEN }}
if: ${{ !env.ACT }}

- name: Login to Docker Hub
uses: docker/login-action@v2
with:
username: ${{ secrets.DOCKER_USERNAME }}
password: ${{ secrets.DOCKER_PASSWORD }}
if: ${{ !env.ACT }}

- uses: docker/build-push-action@v3
with:
context: dnsmasq
platforms: linux/amd64,linux/arm64
push: ${{ github.ref == 'refs/heads/main' && !env.ACT }}
tags: ghcr.io/${{ github.repository_owner }}/caddy-ngrok:latest, wardenenv/caddy-ngrok:latest

0 comments on commit f55d082

Please sign in to comment.