Skip to content

Commit

Permalink
Added support for arm64 in install.sh (flyteorg#209)
Browse files Browse the repository at this point in the history
* Added install.sh script for arm

Signed-off-by: Yuvraj <code@evalsocket.dev>
  • Loading branch information
yindia authored Oct 25, 2021
1 parent 6453fab commit 0a2ddb2
Show file tree
Hide file tree
Showing 4 changed files with 35 additions and 12 deletions.
11 changes: 5 additions & 6 deletions flytectl/.github/workflows/build.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -20,27 +20,26 @@ jobs:
~/.cache/go-build
~/go/pkg/mod
key: ${{ runner.os }}-go-${{ hashFiles('go.sum') }}
- uses: actions/setup-go@v2
with:
go-version: '1.16'
- name: Run GoReleaser dry run
uses: goreleaser/goreleaser-action@v2
with:
version: latest
args: --snapshot --skip-publish --rm-dist
- name: Unit Tests
uses: cedrickring/golang-action@1.5.2
env:
GO111MODULE: "on"
CI_ENV: "true"
with:
args: make install && make test_unit_without_flag
run: make install && make test_unit_without_flag
- name: Push CodeCov
uses: codecov/codecov-action@v1.0.5
with:
file: coverage.txt
flags: unittests
fail_ci_if_error: true
- name: Lint
uses: cedrickring/golang-action@1.5.2
env:
GO111MODULE: "on"
with:
args: make install && make lint
run: make install && make lint
3 changes: 3 additions & 0 deletions flytectl/.github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,9 @@ jobs:
uses: actions/checkout@v2
with:
fetch-depth: "0"
- uses: actions/setup-go@v2
with:
go-version: '1.16'
- name: Run GoReleaser dry run
uses: goreleaser/goreleaser-action@v2
with:
Expand Down
27 changes: 24 additions & 3 deletions flytectl/.goreleaser.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,10 +6,33 @@ builds:
- CGO_ENABLED=0
main: ./main.go
binary: flytectl
id: flytectl-darwin
goos:
- darwin
goarch:
- arm64
- amd64
ldflags:
- -s -w -X github.com/flyteorg/flytestdlib/version.Version={{.Version}} -X github.com/flyteorg/flytestdlib/version.Build={{.ShortCommit}} -X github.com/flyteorg/flytestdlib/version.BuildTime={{.Date}}
- env:
- CGO_ENABLED=0
main: ./main.go
binary: flytectl
id: flytectl-linux
goos:
- linux
goarch:
- arm64
- amd64
ldflags:
- -s -w -X github.com/flyteorg/flytestdlib/version.Version={{.Version}} -X github.com/flyteorg/flytestdlib/version.Build={{.ShortCommit}} -X github.com/flyteorg/flytestdlib/version.BuildTime={{.Date}}
- env:
- CGO_ENABLED=0
main: ./main.go
binary: flytectl
id: flytectl-windows
goos:
- windows
- darwin
ldflags:
- -s -w -X github.com/flyteorg/flytestdlib/version.Version={{.Version}} -X github.com/flyteorg/flytestdlib/version.Build={{.ShortCommit}} -X github.com/flyteorg/flytestdlib/version.BuildTime={{.Date}}
archives:
Expand All @@ -23,8 +46,6 @@ archives:
format_overrides:
- goos: windows
format: zip
universal_binaries:
- replace: false
checksum:
name_template: 'checksums.txt'
snapshot:
Expand Down
6 changes: 3 additions & 3 deletions flytectl/install.sh
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#!/bin/sh
set -e
# Code generated by godownloader on 2021-04-03T07:49:04Z. DO NOT EDIT.
# Code generated by godownloader on 2021-10-24T11:29:26Z. DO NOT EDIT.
#

usage() {
Expand Down Expand Up @@ -62,10 +62,10 @@ execute() {
}
get_binaries() {
case "$PLATFORM" in
darwin/386) BINARIES="flytectl" ;;
darwin/amd64) BINARIES="flytectl" ;;
linux/386) BINARIES="flytectl" ;;
darwin/arm64) BINARIES="flytectl" ;;
linux/amd64) BINARIES="flytectl" ;;
linux/arm64) BINARIES="flytectl" ;;
windows/386) BINARIES="flytectl" ;;
windows/amd64) BINARIES="flytectl" ;;
*)
Expand Down

0 comments on commit 0a2ddb2

Please sign in to comment.