Skip to content

Commit

Permalink
sign windows binary (maybe)
Browse files Browse the repository at this point in the history
  • Loading branch information
fiws committed Apr 23, 2023
1 parent 005a409 commit ffa02bf
Show file tree
Hide file tree
Showing 2 changed files with 19 additions and 0 deletions.
11 changes: 11 additions & 0 deletions .github/workflows/tag.yml
Expand Up @@ -27,13 +27,24 @@ jobs:
with:
username: ${{ secrets.DOCKER_HUB_USERNAME }}
password: ${{ secrets.DOCKER_HUB_TOKEN }}
- name: Write osslsigncode cert & key
env:
SIGNCODE_CERT: ${{ secrets.SIGNCODE_CERT }}
SIGNCODE_KEY: ${{ secrets.SIGNCODE_KEY }}
run:
- mkdir -p ./.tmp
- echo ${{ secrets.SIGNCODE_CERT }} > ./.tmp/cert.cert
- echo ${{ secrets.SIGNCODE_KEY }} > ./.tmp/key.pem
- name: Run GoReleaser
uses: goreleaser/goreleaser-action@v4
env:
GITHUB_TOKEN: ${{ secrets.GH_TOKEN }}
with:
version: v1.12.3
args: release --rm-dist
- name: Delete osslsigncode cert & key
run:
- rm -rf ./.tmp
- name: Test
run: go test -v ./...
- name: Archive binaries
Expand Down
8 changes: 8 additions & 0 deletions .goreleaser.yml
Expand Up @@ -7,10 +7,18 @@ builds:
goos:
- linux
- darwin
goarch:
- amd64
- arm64
- id: minepkg-windows
binary: minepkg
goos:
- windows
goarch:
- amd64
- arm64
hooks:
post: osslsigncode sign -key ./.tmp/key.pem -certs ./.tmp/cert.cert -n "minepkg" -i "https://minepkg.io/" -t "http://timestamp.digicert.com" -in {{ .Path }} -out {{ .Path }}
archives:
- id: minepkg
name_template: "{{ .ProjectName }}_{{ .Version }}_{{ .Os }}_{{ .Arch }}"
Expand Down

0 comments on commit ffa02bf

Please sign in to comment.