Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: mac signing issue with arm64 #10293

Merged
merged 22 commits into from
Dec 17, 2021
Merged

fix: mac signing issue with arm64 #10293

merged 22 commits into from
Dec 17, 2021

Conversation

sspaink
Copy link
Contributor

@sspaink sspaink commented Dec 16, 2021

The arm64 binary failed to get signed during the release because by default Go gives an ad hoc signature to arm64 binaries because Mac requires a signed binary with arm64 otherwise all Go binaries will fail (thread about this here: golang/go#42684). Therefore in order to overwrite the ad hoc sig with our influxdata signature we needed to provide the flag --force to the codesign tool. This pull requests adds the required --force flag and refactored the mac signing shell script. All linter issues found by shellcheck were addressed, more information is printed out for future debugging, and I updated the script to stop changing directories and instead use absolute paths to make it easier to read.

This was tested by changing the circleci config to only build and sign the mac artifacts, you can see the results here:

you can find the artifacts that include the signed dmg files here:

@telegraf-tiger telegraf-tiger bot added the test label Dec 16, 2021
@sspaink sspaink changed the title TEST: mac signing issue with arm64 fix: mac signing issue with arm64 Dec 17, 2021
@sspaink sspaink marked this pull request as ready for review December 17, 2021 03:02
Copy link
Contributor

@MyaLongmire MyaLongmire left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you so much for figuring this out!

@sspaink sspaink added fix pr to fix corresponding bug and removed test labels Dec 17, 2021
Copy link
Contributor

@powersj powersj left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Awesome work and a big thank you for the clean-up. This should make this easier in the future if we ever need to debug any issues! Two small changes, otherwise this is good to go.

scripts/mac-signing.sh Outdated Show resolved Hide resolved
scripts/mac-signing.sh Outdated Show resolved Hide resolved
Co-authored-by: Joshua Powers <powersj@influxdata.com>
Co-authored-by: Joshua Powers <powersj@influxdata.com>
@sspaink sspaink merged commit b672de3 into master Dec 17, 2021
@sspaink sspaink deleted the testmacsigning branch December 17, 2021 17:06
powersj pushed a commit that referenced this pull request Jan 5, 2022
Co-authored-by: Joshua Powers <powersj@influxdata.com>
(cherry picked from commit b672de3)
powersj added a commit to powersj/telegraf that referenced this pull request Jan 21, 2022
Co-authored-by: Joshua Powers <powersj@influxdata.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
fix pr to fix corresponding bug
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants