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

Intalling certificate for local codesign assets #150

Merged
merged 2 commits into from
Jan 20, 2022

Conversation

lpusok
Copy link
Contributor

@lpusok lpusok commented Jan 19, 2022

Checklist

  • I've read and followed the Contribution Guidelines
  • step.yml and README.md is updated with the changes (if needed)

Version

Requires a PATCH version update

Context

Make sure the certificate is installed when a matching local profile is found.

Resolves: https://bitrise.atlassian.net/browse/STEP-1715

Changes

  • Install certificate for locally found provisioning profiles. An alternative could have been to check weather certificate is already installed in the Keychain, always installing is the easier solution.
    There was no check earlier that the selected certificate (or any certificate in the profile) was installed. This could have led to an error:
    • A Step with automatic code signing installs Profile1, this induces Cert1 and Cert2. Cert1 is selected (to be set as signing certificate in the project). Profile1 is added, Cert1 is added to the Keychain. (Cert2 is not added.)
    • xcodebuild archive runs successfully
    • Another Step with automatic code signing is run. This time the previously added Profile1 is found. However now Cert2 is selected (randomly), it is not installed due to missing check.
    • xcodebuild archive fails with error:
❌  error: No certificate for team 'AAABBBCCC' matching 'dcdcdc' found: Select a different signing certificate for CODE_SIGN_IDENTITY, a team that matches your selected certificate, or switch to automatic provisioning. (...)

Investigation details

Decisions

shams-ahmed
shams-ahmed previously approved these changes Jan 19, 2022
Copy link
Contributor

@ofalvai ofalvai left a comment

Choose a reason for hiding this comment

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

LGTM, kudos for the extra tests 🚀

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants