Skip to content

Add webhook delivery to certman (#1131) #3708

Add webhook delivery to certman (#1131)

Add webhook delivery to certman (#1131) #3708

Workflow file for this run

name: CI
on:
push:
branches:
- main
- "v*"
tags:
- "v*"
pull_request:
jobs:
lint:
name: Go Lint
runs-on: ubuntu-latest
steps:
- name: Set up Go
uses: actions/setup-go@v3
with:
go-version: 1.19
- name: Install Staticcheck
run: go install honnef.co/go/tools/cmd/[email protected]
- name: Checkout Code
uses: actions/checkout@v3
- name: Lint Go Code
run: staticcheck ./...
test:
name: Go Test
runs-on: ubuntu-latest
env:
GOPATH: ${{ github.workspace }}/go
GOBIN: ${{ github.workspace }}/go/bin
defaults:
run:
working-directory: ${{ env.GOPATH }}/src/github.com/trisacrypto/directory
steps:
- name: Set up Go
uses: actions/setup-go@v3
with:
go-version: 1.19
- name: Cache Speedup
uses: actions/cache@v3
with:
path: ${{ github.workspace }}/go/pkg/mod
key: ${{ runner.os }}-go-${{ hashFiles('**/go.sum') }}
restore-keys: |
${{ runner.os }}-go-
- name: Checkout Code
uses: actions/checkout@v3
with:
path: ${{ env.GOPATH }}/src/github.com/trisacrypto/directory
- name: Install Protoc
uses: arduino/setup-protoc@v1
with:
version: "3.x"
repo-token: ${{ secrets.GITHUB_TOKEN }}
- name: Install Dependencies
run: |
go version
go install github.com/kevinburke/go-bindata/[email protected]
go install google.golang.org/protobuf/cmd/[email protected]
go install google.golang.org/grpc/cmd/[email protected]
go install github.com/swaggo/swag/cmd/[email protected]
- name: Clone TRISA repository
uses: actions/checkout@v3
with:
repository: trisacrypto/trisa
ref: main
path: ${{ env.GOPATH }}/src/github.com/trisacrypto/trisa
- name: Code Generation
run: go generate ./...
- name: Run Unit Tests
run: go test -v -coverprofile=coverage.txt -covermode=atomic --race ./...
gds_admin_test:
name: GDS Admin UI Tests
runs-on: ubuntu-latest
steps:
- name: Checkout Code
uses: actions/checkout@v3
- name: Set up Node
uses: actions/setup-node@v3
with:
node-version: "16.x.x"
cache: "yarn"
cache-dependency-path: ./web/gds-admin-ui/yarn.lock
- name: Install Dependencies
working-directory: ./web/gds-admin-ui
run: yarn
- name: Run Tests
working-directory: ./web/gds-admin-ui
env:
REACT_APP_GDS_API_ENDPOINT: http://localhost:4434/v2
REACT_APP_GDS_IS_TESTNET: true
run: yarn test
gds_user_ui_test:
name: GDS User UI Tests
runs-on: ubuntu-latest
steps:
- name: Checkout Code
uses: actions/checkout@v3
- name: Set up Node
uses: actions/setup-node@v3
with:
node-version: "16.x.x"
cache: "yarn"
cache-dependency-path: ./web/gds-user-ui/yarn.lock
- name: Install Dependencies
working-directory: ./web/gds-user-ui
run: yarn
- name: Run Tests
working-directory: ./web/gds-user-ui
env:
REACT_APP_TRISA_BASE_URL: http://localhost:4437/v1/
REACT_APP_GDS_IS_TESTNET: true
run: yarn test
lingui_gds_ui:
name: Lingui Extract && Build
runs-on: ubuntu-latest
steps:
- name: Checkout Code
uses: actions/checkout@v3
- name: Set up Node
uses: actions/setup-node@v3
with:
node-version: 16.8.0
cache: "yarn"
cache-dependency-path: ./web/gds-ui/yarn.lock
- name: Install Dependencies
working-directory: ./web/gds-ui
run: yarn
- name: Extract
working-directory: ./web/gds-ui
run: yarn extract-c
- name: Compile
working-directory: ./web/gds-ui
run: yarn compile
build:
name: Go Build
runs-on: ubuntu-latest
env:
GOPATH: ${{ github.workspace }}/go
GOBIN: ${{ github.workspace }}/go/bin
defaults:
run:
working-directory: ${{ env.GOPATH }}/src/github.com/trisacrypto/directory
steps:
- name: Set up Go
uses: actions/setup-go@v2
with:
go-version: 1.19
- name: Cache Speedup
uses: actions/cache@v3
with:
path: ${{ github.workspace }}/go/pkg/mod
key: ${{ runner.os }}-go-${{ hashFiles('**/go.sum') }}
restore-keys: |
${{ runner.os }}-go-
- name: Checkout Code
uses: actions/checkout@v3
with:
path: ${{ env.GOPATH }}/src/github.com/trisacrypto/directory
- name: Install Protoc
uses: arduino/setup-protoc@v1
with:
version: "3.x"
repo-token: ${{ secrets.GITHUB_TOKEN }}
- name: Install Dependencies
run: |
go version
go install github.com/kevinburke/go-bindata/[email protected]
go install google.golang.org/protobuf/cmd/[email protected]
go install google.golang.org/grpc/cmd/[email protected]
go install github.com/swaggo/swag/cmd/[email protected]
- name: Clone TRISA repository
uses: actions/checkout@v3
with:
repository: trisacrypto/trisa
ref: main
path: ${{ env.GOPATH }}/src/github.com/trisacrypto/trisa
- name: Code Generation
run: go generate ./...
- name: Build
run: go build ./cmd/...