Skip to content

APIGOV-26106 - update golang version (#137) #542

APIGOV-26106 - update golang version (#137)

APIGOV-26106 - update golang version (#137) #542

name: Build Apigee Traceability Agent
on:
push:
branches: [main, "*"]
jobs:
testTraceabilityAgent:
env:
GOFLAGS: "-mod=mod"
GOWORK: "off"
defaults:
run:
working-directory: ${{ env.GOPATH }}/discovery
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Set up Go
uses: actions/setup-go@v3
with:
go-version: 1.21
- name: Test traceability agent
working-directory: traceability
run: go test -race -v ./...
buildTraceabilityAgent:
env:
GOFLAGS: "-mod=mod"
GOWORK: "off"
defaults:
run:
working-directory: ${{ env.GOPATH }}/traceability
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Set up Go
uses: actions/setup-go@v3
with:
go-version: 1.19
- name: Build traceability agent
working-directory: traceability
run: |
git fetch --all --tags --quiet
git branch --show-current > commit_id
git tag -l --sort='version:refname' | grep -Eo '[0-9]{1,}\.[0-9]{1,}\.[0-9]{1,3}$' | tail -1 > version
make build
- uses: actions/upload-artifact@v3
with:
name: apigee_traceability_agent
path: traceability/bin/apigee_traceability_agent
- uses: actions/upload-artifact@v3
with:
name: apigee_traceability_agent.yml
path: traceability/apigee_traceability_agent.yml