kube-linter icon indicating copy to clipboard operation
kube-linter copied to clipboard

[FEATURE_REQUEST] Publish a mac arm binary

Open charlesoconor opened this issue 2 years ago • 1 comments

It would be great to publish a prebuilt version of this tool for mac, darwin, arm. The old intel macs are harder to get you're hands on these days. My current workflow is using bazel to pull in the prebuilt and I have a custom-built artifact for people with arm macs.

I can try to add this functionality but it will be a little before I can get my hands on some hardware to test it.

charlesoconor avatar Sep 02 '22 00:09 charlesoconor

Hey, this makes sense. We need to:

  1. Add GOOS=darwin GOARCH=arm64 in makefile binary generation https://github.com/stackrox/kube-linter/blob/7553e83b18012e5d0ee60a548bc3af356089433b/Makefile#L84
  2. Handle arch in the build script (maybe we can handle it by concatenating $GOOS with $GOARCH 🤔 ) https://github.com/stackrox/kube-linter/blob/b614a5d808aaead38a4b92553a2f3fb738ec28db/scripts/go-build.sh#L53
  3. Handle new binary in release script https://github.com/stackrox/kube-linter/blob/8ef2f4970e5a21e2fc559183bfdb132f532cc1c1/.github/workflows/build.yaml#L288

@charlesoconor I can handle testing. I think I know somebody with Mac M1 who could run couple of commands for me 😄

janisz avatar Sep 02 '22 06:09 janisz

This is still a problem, not sure why the PR was closed. Frustrating as so many of us have arm macbooks in 2023.

adam-thomas-privitar avatar Mar 01 '23 15:03 adam-thomas-privitar

I got side tracked since I've gotten all of the devs at my company to run rosetta for other reasons. The PR was closed since it wasn't ready meant to open it onto my own fork to check how the actions would work. Probably not to much more work is needed since go is very good a cross-compilation. I or someone needs to find the time.

charlesoconor avatar Mar 02 '23 16:03 charlesoconor

For now I'm using brew to install kube-linter - but I'd like to install it from asdf plugin using the github release..

Seems like the release file name convention is changing as well (#380) so let's take it as an opportunity to add arch to the file name (or we may use amd64 as the old name)

(I don't know the status of "fat" go binary to support multiple arch)

chulkilee avatar May 01 '23 19:05 chulkilee

+1

loeffel-io avatar Oct 23 '23 00:10 loeffel-io