Skip to content

Commit a956fc7

Browse files
authored
Use go 1.16 and build darwin-arm64 (#114)
1 parent b57a013 commit a956fc7

File tree

4 files changed

+15
-12
lines changed

4 files changed

+15
-12
lines changed

.github/workflows/go.yml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ jobs:
1616
- name: Set up Go
1717
uses: actions/setup-go@v2
1818
with:
19-
go-version: 1.15
19+
go-version: 1.16
2020

2121
- name: Go modules cache
2222
uses: actions/cache@v2
@@ -72,7 +72,7 @@ jobs:
7272
- name: Set up Go
7373
uses: actions/setup-go@v2
7474
with:
75-
go-version: 1.15
75+
go-version: 1.16
7676

7777
- name: Restore the compiled binary for smoke testing
7878
uses: actions/cache@v2
@@ -120,7 +120,7 @@ jobs:
120120
- name: Set up Go
121121
uses: actions/setup-go@v2
122122
with:
123-
go-version: 1.15
123+
go-version: 1.16
124124

125125
- name: Restore the compiled binary for smoke testing
126126
uses: actions/cache@v2
@@ -171,7 +171,7 @@ jobs:
171171
- name: Set up Go
172172
uses: actions/setup-go@v2
173173
with:
174-
go-version: 1.15
174+
go-version: 1.16
175175

176176
- name: Restore compiled binary for smoke testing
177177
uses: actions/cache@v2

.github/workflows/release.yaml

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -12,26 +12,26 @@ jobs:
1212
steps:
1313
- name: Check out code into the Go module directory
1414
uses: actions/checkout@v2
15-
15+
1616
# Ugly hack to get the tag name
1717
# github.ref gives the full reference like refs.tags.v0.0.1-beta1
1818
- name: Branch name
1919
id: branch_name
2020
run: |
2121
echo ::set-output name=TAG_NAME::${GITHUB_REF#refs/tags/}
22-
22+
2323
- name: Set up Go
2424
uses: actions/setup-go@v2
2525
with:
26-
go-version: 1.15
26+
go-version: 1.16
2727

2828
- name: Build bins
2929
id: build_bins
3030
env:
3131
SEGMENT_WRITE_KEY: ${{ secrets.SEGMENT_WRITE_KEY }}
3232
TAG_NAME: ${{ steps.branch_name.outputs.TAG_NAME }}
3333
run: make build-all
34-
34+
3535
- name: Create Release in Github
3636
id: create_release
3737
uses: actions/create-release@v1
@@ -42,11 +42,11 @@ jobs:
4242
release_name: ${{ github.ref }}
4343
draft: true # So we can manually edit before publishing
4444
prerelease: ${{ contains(github.ref, '-') }} # v0.1.2-beta1, 1.2.3-rc1
45-
45+
4646
- name: Upload artifacts
4747
id: upload
4848
env:
4949
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} # This token is provided by Actions
5050
TAG_NAME: ${{ steps.branch_name.outputs.TAG_NAME }}
5151
run: make upload
52-
52+

Makefile

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,11 +18,14 @@ bin/k0sctl-win-x64.exe: $(GO_SRCS)
1818
bin/k0sctl-darwin-x64: $(GO_SRCS)
1919
GOOS=darwin GOARCH=amd64 go build $(BUILD_FLAGS) -o bin/k0sctl-darwin-x64 main.go
2020

21+
bin/k0sctl-darwin-arm64: $(GO_SRCS)
22+
GOOS=darwin GOARCH=arm64 go build $(BUILD_FLAGS) -o bin/k0sctl-darwin-arm64 main.go
23+
2124
bin/%.sha256: bin/%
2225
sha256sum -b $< | sed 's/bin\///' > $@.tmp
2326
mv $@.tmp $@
2427

25-
bins := k0sctl-linux-x64 k0sctl-win-x64.exe k0sctl-darwin-x64
28+
bins := k0sctl-linux-x64 k0sctl-win-x64.exe k0sctl-darwin-x64 k0sctl-darwin-arm64
2629
checksums := $(addsuffix .sha256,$(bins))
2730

2831
.PHONY: build-all

go.mod

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
module github.com/k0sproject/k0sctl
22

3-
go 1.15
3+
go 1.16
44

55
replace github.com/segmentio/analytics-go v3.1.0+incompatible => github.com/kke/analytics-go v1.2.1-0.20210209122110-10364370169e
66

0 commit comments

Comments
 (0)