Skip to content

v2.7.5-caddy2-naive2 #16

v2.7.5-caddy2-naive2

v2.7.5-caddy2-naive2 #16

Workflow file for this run

name: Build
on:
push:
branches: [naive]
paths-ignore: [README.md]
release:
types: [published]
defaults:
run:
shell: bash
jobs:
build_caddy_with_naive:
runs-on: ubuntu-22.04
env:
BUNDLE: caddy-forwardproxy-naive
steps:
- uses: actions/checkout@v4
- uses: actions/setup-go@v4
with:
go-version: ^1.21.3
- run: go install github.com/caddyserver/xcaddy/cmd/xcaddy@latest
- run: ~/go/bin/xcaddy build --with github.com/caddyserver/forwardproxy@caddy2=$PWD
- name: Pack naiveproxy assets
run: |
mkdir ${{ env.BUNDLE }}
cp caddy LICENSE README.md ${{ env.BUNDLE }}
tar cJf ${{ env.BUNDLE }}.tar.xz ${{ env.BUNDLE }}
openssl sha256 ./caddy >sha256sum.txt
echo "SHA256SUM=$(cut -d' ' -f2 sha256sum.txt)" >>$GITHUB_ENV
- uses: actions/upload-artifact@v3
with:
name: ${{ env.BUNDLE }}.tar.xz caddy executable sha256 ${{ env.SHA256SUM }}
path: sha256sum.txt
- name: Upload caddy assets
if: ${{ github.event_name == 'release' }}
run: gh release upload "${GITHUB_REF##*/}" ${{ env.BUNDLE }}.tar.xz --clobber
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}