Skip to content

docker/proxy: set global email #16

docker/proxy: set global email

docker/proxy: set global email #16

Workflow file for this run

name: Caddy
on:
push:
branches: ["main"]
paths:
- "docker/proxy/**"
workflow_dispatch:
jobs:
format:
name: Format Caddyfile
runs-on: ubuntu-22.04
steps:
- name: Checkout
uses: actions/checkout@v2
- name: Setup Docker
uses: docker/setup-qemu-action@v3
- name: Format Caddyfile
run: docker run --rm -v $(pwd)/docker/proxy/Caddyfile:/Caddyfile caddy:2 caddy fmt /Caddyfile
- name: Commit changes
run: |
git config --global user.name "GitHub Actions"
git config --global user.email ""
git add docker/proxy/Caddyfile
git commit -m "Auto Format Caddyfile"
git push
build-image:
name: Build Caddy (custom image w/ Cloudflare)
runs-on: ubuntu-22.04
defaults:
run:
working-directory: "./docker/proxy"
steps:
- name: Checkout
uses: actions/checkout@v2
- name: Setup Docker Buildx
uses: docker/setup-buildx-action@v1
- name: "Login to GitHub Container Registry"
uses: docker/login-action@v1
with:
registry: ghcr.io
username: ${{github.actor}}
password: ${{secrets.GITHUB_TOKEN}}
- name: Build Image
run: |
docker build . --tag ghcr.io/orangeunilabs/caddy:latest
- name: Push Image
run: |
docker push ghcr.io/orangeunilabs/caddy:latest