kptdev / kpt

Automate Kubernetes Configuration Editing
https://kpt.dev
Apache License 2.0
1.7k stars 227 forks source link

macOS - Kpt Cannot be Opened Because it is from an Unidentified Developer #1455

Open runewake2 opened 3 years ago

runewake2 commented 3 years ago

When kpt releases are downloaded from the Releases page running these builds on MacOS triggers an error that "kpt" cannot be opened because it is from an unidentified developer. I believe this is caused by increased security in newer versions of macOS.

image

This error blocks running kpt until the security exception is granted, even when kpt is run from the terminal.

GoReleaser provides a way to sign binaries that we may want to adopt to avoid this.

Work Arounds

Apple has documentation on how to open an app from an unidentified developer here. Switching security settings to allow apps from the App Store and identified developers does not appear to be enough here.

image

Alternatively installing kpt from other tooling like Homebrew should avoid this.

mikebz commented 3 years ago

This could help:

sudo spctl --master-disable
runewake2 commented 3 years ago

If we can, I think we'll want to start signing the binaries eventually (if someone else runs into this). Windows SmartScreen catches kpt as well right now.

For Windows the workaround that works is either to "Run Anyways" if you have permissions, alternatively installing kpt via go get ... worked for me.

image

For now hopefully the workarounds we've shared are enough.