-
Notifications
You must be signed in to change notification settings - Fork 4
39 lines (33 loc) · 943 Bytes
/
main.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
name: build
on:
push:
branches:
- main
- release-*
pull_request:
workflow_dispatch:
jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Git Checkout
uses: actions/checkout@v4
with:
persist-credentials: false
- name: Install Go
uses: actions/setup-go@v5
with:
go-version-file: ./go.mod
- name: Install Ziti CI
uses: openziti/ziti-ci@v1
- name: Build and Test
run: go test ./... --tags apitests
- name: Release
env:
gh_ci_key: ${{ secrets.GH_CI_KEY }}
ziti_ci_gpg_key: ${{ secrets.ZITI_CI_GPG_KEY }}
ziti_ci_gpg_key_id: ${{ secrets.ZITI_CI_GPG_KEY_ID }}
if: github.ref == 'refs/heads/main' || startsWith(github.ref, 'refs/heads/release-')
run: |
$(go env GOPATH)/bin/ziti-ci configure-git
$(go env GOPATH)/bin/ziti-ci tag -v -f version