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

Update CFBundleShortVersionString in tsh for MacOS #25085

Closed
pschisa opened this issue Apr 24, 2023 · 5 comments
Closed

Update CFBundleShortVersionString in tsh for MacOS #25085

pschisa opened this issue Apr 24, 2023 · 5 comments
Assignees
Labels
c-dx Internal Customer Reference feature-request Used for new features in Teleport, improvements to current should be #enhancements release-engineering tsh tsh - Teleport's command line tool for logging into nodes running Teleport.

Comments

@pschisa
Copy link
Contributor

pschisa commented Apr 24, 2023

What would you like Teleport to do?
Update the CFBundleShortVersionString version to the correct tsh version in the MacOS build. It currently is set to 1.0

What problem does this solve?
When using Jamf to deploy the tsh client for macOS, Jamf appears to be using the using the path /Applications/tsh.app for version verification, and more specifically seems to be reading from the CFBundleShortVersionString within /Applications/tsh.app/Contents/Info.plist.
The string associated with that key reads 1.0 in each release, which makes patching the client difficult.

If a workaround exists, please include it.
call tsh version in a separate script for accurate reporting information.

@pschisa pschisa added feature-request Used for new features in Teleport, improvements to current should be #enhancements tsh tsh - Teleport's command line tool for logging into nodes running Teleport. c-dx Internal Customer Reference labels Apr 24, 2023
@r0mant
Copy link
Collaborator

r0mant commented Apr 24, 2023

@camscale Can you see how difficult it is to set the correct tsh.app's version string in our new GHA darwin workflow?

@camscale
Copy link
Contributor

camscale commented May 2, 2023

I'll look to do it when make update-version (make version) is run as we do with other files in the repo that contain the version. I'll add a recipe to version.mk to do this update.

@camscale
Copy link
Contributor

camscale commented May 4, 2023

I have a branch that does this, but I think I need to alter it a little bit. According to the Apple docs on CFBundleShortVersionString, the value must be three dot-separated integers, so the semver additional labels for pre-release versions, etc are not allowed.

This wont matter for released versions as they are in the form X.Y.Z. I am thinking of leaving 1 as as the CFBundleShortVersionString value when there is a semver pre-release tag. I did test and I can sign and notarize with a tag in the version, so it does not appear that Apple are enforcing the rule, but I still think it is best to adhere to it in case Apple do start enforcing it, or other parts of the system assume it follows the required pattern.

Do you think it's ok to leave the value as 1 if there is a semver prerelease tag on th version?

@r0mant
Copy link
Collaborator

r0mant commented May 4, 2023

Do you think it's ok to leave the value as 1 if there is a semver prerelease tag on th version?

@camscale Yes, I think that's fine.

@camscale
Copy link
Contributor

This has now been merged to all supported branches. The next release on each branch will have the Teleport version number set on the tsh bundle.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
c-dx Internal Customer Reference feature-request Used for new features in Teleport, improvements to current should be #enhancements release-engineering tsh tsh - Teleport's command line tool for logging into nodes running Teleport.
Projects
None yet
Development

No branches or pull requests

4 participants