-
Notifications
You must be signed in to change notification settings - Fork 297
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 USB config sync #890
Fix USB config sync #890
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The changes under santasyncservice/ should be reverted - the mode is retrieved during preflight but it shouldn't be applied until postflight time as the majority of the other keys do. The changes in SNTConfigurator should be enough to fix the bug, I think
I think this change is necessary if we want to be able to unblock the USB device mounts and if we want to not update the SNTConfigurator syncState if the server is not sending the key. |
Hey folks 👋 We're looking at rolling this out internally and appear to have hit the same issue - is there an update on this, or a workaround? The Santa documentation seems to suggest that it'll work with a sync server. Happy to help get this over the line if you need! |
@liamn the main issue with this PR is that the settings are being changed in the As @russellhancox calls out reverting the changes in the syncservice should enough to fix this. If the PR can be changed to do that I think it'll good to merge. |
If @np5 doesn't chime in soon I'll remind him that this is pending his response. |
Sorry for the delay. I made the change in the preflight because it was easier for me to manage the true/false/missing values in the server response. I think that "missing" or "absent" is important, because if a sync server is not yet implementing this, you do not want to overwrite the value set in the config profile. I am not really proficient with objective C, but maybe by setting the value as a pointer to a |
- get `BlockUSBMount` and `RemountUSBMode` from the `configState` and from the `syncState`. - disable `BlockUSBMount` if set to `false` in the preflight response. - only set `BlockUSBMount` in `syncState` if present in the preflight response. - Fix `keyPathsForValuesAffecting*` for `RemountUSBMode`, `RemountUSBBlockMessage` and `USBBlockMessage`. - `BlockUSBMount` and `RemountUSBMode` added to the docs. - Fix `block_usb_mount` docs.
8c2191d
to
f672833
Compare
Yes, this will work and what you have now meets our general constraint of receiving new configuration during preflight but applying it during postflight so that syncing acts like a kind of transaction. Thanks! |
BlockUSBMount
andRemountUSBMode
from theconfigState
and from thesyncState
.BlockUSBMount
if set tofalse
in the preflight response.BlockUSBMount
insyncState
if present in the preflight response.keyPathsForValuesAffecting*
forRemountUSBMode
,RemountUSBBlockMessage
andUSBBlockMessage
.BlockUSBMount
andRemountUSBMode
to the docs.block_usb_mount
docs.