Closed kpaulisse closed 1 month ago
Welcome @kpaulisse! It looks like this is your first PR to falcosecurity/falcoctl 🎉
LGTM label has been added.
[APPROVALNOTIFIER] This PR is APPROVED
This pull-request has been approved by: alacuku, kpaulisse
The full list of commands accepted by this bot can be found here.
The pull request process is described here
What type of PR is this?
/kind failing-test
/kind feature
Any specific area of the project related to this PR?
/area cli
What this PR does / why we need it:
This PR adds a
--platform
CLI option to theartifact install
command.For example:
falcoctl artifact install --platform linux/amd64 ...
There are various other commands that accept a
--platform
argument so I implemented this in the same way.Reason: We are deploying Falco into environments that may be air gapped so we want to produce a single OCI image with the appropriate rule sets and plugins. We want to use
falcoctl
to download the artifacts. However, this always downloads the artifacts for the architecture that the CI system (or developer laptop) is running, and this often produces errors, e.g. "unable to find a manifest matching the given platform: darwin/arm64". With this new option it's possible to specify--platform=linux/amd64
and have this work even on an ARM build host or a local mac environment.Additionally, when I was building this, I noticed that the tests for
artifact install
were failing on my local Mac machine, so I added this new--platform
CLI flag to the tests that were failing so it would align with thelinux/amd64
that is hard-coded elsewhere in the test. I marked this as solving a failing test for that reason.Which issue(s) this PR fixes:
N/A
Special notes for your reviewer:
N/A