fossas / fossa-cli

Fast, portable and reliable dependency analysis for any codebase. Supports license & vulnerability scanning for large monoliths. Language-agnostic; integrates with 20+ build systems.
https://fossa.com
Other
1.26k stars 173 forks source link

Add Mac arm64 executable #1426

Closed csasarak closed 4 months ago

csasarak commented 4 months ago

Overview

This adds an arm build of the CLI for Mac. You can get binaries from the build macOS-aarch64-build action below.

I will relax and replace some of the required checks for this branch before and after the merge to master.

Acceptance criteria

A build that works on Mac M1.

Testing plan

I set up an ARM EC2 instance, copied the binaries there and ran them. Additionally I ran a direct license-scan to verify that the license scan program worked correctly.

If you are on an ARM mac, downloading the binaries from the release step and running them should also test this.

I tested the install script to make sure that it correctly selects the arm build if it's fetching a valid version. Otherwise it falls back to the intel version of the CLI like before. Screenshot 2024-05-07 at 2 35 06 PM

Currently, running the cli and just getting the latest fails with a 404, but the generated URL is what I expect it to be: Screenshot 2024-05-07 at 2 38 58 PM

Risks

Costs will increase since we will be allocating two runners for Mac per build. Caching may become less reliable as we make more cache data as well.

Metrics

References

ANE-572

Checklist

csasarak commented 4 months ago

Did you test that themis works from it? It did in my testing but it's good to get another check. @spatten I'll incorporate your suggestions.

spatten commented 4 months ago

Did you test that themis works from it? It did in my testing but it's good to get another check. @spatten I'll incorporate your suggestions.

I hadn't, but I just did and it works. Good call!

~/Downloads/macOS-arm64-binaries/fossa license-scan direct

results in output from Themis