Skip to content

Commit

Permalink
fix windows build
Browse files Browse the repository at this point in the history
  • Loading branch information
zhangzujian committed Jan 5, 2023
1 parent 05801fa commit c92af9b
Showing 1 changed file with 20 additions and 20 deletions.
40 changes: 20 additions & 20 deletions .github/workflows/build-windows.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -15,9 +15,13 @@ on:
- 'docs/**'
- '**.md'

concurrency:
group: "${{ github.workflow }}-${{ github.ref }}"
cancel-in-progress: true

env:
GO_VERSION: '1.18'
GOSEC_VERSION: '2.12.0'
GO_VERSION: '1.19'
GOSEC_VERSION: '2.14.0'

jobs:
build-ovs-and-ovn:
Expand Down Expand Up @@ -128,31 +132,28 @@ jobs:
name: Build Kube-OVN
runs-on: windows-2019
steps:
- name: Set up Go 1.x
uses: actions/setup-go@v3
- uses: actions/checkout@v3
- uses: actions/setup-go@v3
with:
go-version: '${{ env.GO_VERSION }}'
check-latest: true
id: go

- name: Check out code
uses: actions/checkout@v3

- name: Go Build Cache
uses: actions/cache@v3
with:
path: /home/runner/.cache/go-build
key: ${{ runner.os }}-go-x86-build-${{ hashFiles('**/go.sum') }}
restore-keys: |
${{ runner.os }}-go-x86-build-
- name: Export Go full version
run: |
$goVersion = (go version).Split()[2]
$entry = [string]::Format("GO_FULL_VER={0}", $goVersion)
Add-Content -Path $env:GITHUB_ENV -Value $entry
- name: Go Mod Cache
- name: Go Cache
uses: actions/cache@v3
with:
path: ~/go/pkg/mod
key: ${{ runner.os }}-go-${{ hashFiles('**/go.sum') }}
path: |
~\AppData\Local\go-build
~\go\pkg\mod
key: ${{ runner.os }}-${{ env.GO_FULL_VER }}-${{ hashFiles('**/go.sum') }}
restore-keys: |
${{ runner.os }}-go-
${{ runner.os }}-${{ env.GO_FULL_VER }}-
- name: Install gosec
run: |
Expand Down Expand Up @@ -182,8 +183,7 @@ jobs:
- build-kube-ovn
runs-on: windows-2019
steps:
- name: Check out code
uses: actions/checkout@v3
- uses: actions/checkout@v3

- name: Download Kube-OVN binaries
uses: actions/download-artifact@v3
Expand Down

0 comments on commit c92af9b

Please sign in to comment.