这将导致输出看起来与此类似<?xml version="1.0" encoding="UTF-8"?> <!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<array>
<dict> ... </dict>
<dict> ... </dict>
<dict>
<key>attributeSetting</key>
<false/>
<key>choiceAttribute</key>
<string>visible</string>
<key>choiceIdentifier</key>
<string>com.teamviewer.teamviewerSilentInstaller</string>
</dict>
<dict>
<key>attributeSetting</key>
<true/>
<key>choiceAttribute</key>
<string>enabled</string>
<key>choiceIdentifier</key>
<string>com.teamviewer.teamviewerSilentInstaller</string>
</dict>
<dict>
<key>attributeSetting</key>
<integer>1</integer>
<key>choiceAttribute</key>
<string>selected</string>
<key>choiceIdentifier</key>
<string>com.teamviewer.teamviewerSilentInstaller</string>
</dict>
</array>
</plist>
通过添加参数“ -applyChoiceChangesXML <your_filename> .xml”在安装过程中应用配置
sudo installer -applyChoiceChangesXML choices.xml -pkg Install TeamViewer (Classic).pkg -target /
3) 如果您有 MDM 系统,则可以使用隐私首选项策略控制 (PPPC) 有效负载在系统首选项 --> 安全和隐私 ---> 隐私中为 TeamViewer (Classic) 推出辅助功能和完整磁盘访问权限。 您的用户仍然需要自己授予屏幕录制访问权限。 从 macOS 11 Big Sur 开始,您将需要使用带有 AllowStandardUserToSetSystemService 的 ScreenCapture PPPC 负载,以允许非管理员用户授予此权限。
配置您的MDM以推出“辅助功能”权限(根据您的MDM解决方案提供商的手册)。 可以在以下位置找到使用Mobile Iron进行MDM配置的示例:将Teamviewer应用程序添加到使用Mobile Iron的macOS Mohjave可访问性中。
更新 TeamViewer (Classic) 安装
更新TeamViewer (Classic)对应于安装所需的步骤:
- 安装Teamviewer的标准主机客户端版本
- 安装Teamviewer的自定义主机客户端版本
- 安装TeamViewer (Classic)的标准完整客户端版本
卸载 TeamViewer (Classic)
卸载TeamViewer (Classic)的原因可能是您想从TeamViewer (Classic)主机客户端版本切换到完全客户端版本。
📌注意:您只能手动卸载TeamViewer (Classic)
建议的卸载TeamViewer (Classic)的方法是使用Mac App Store中的AppCleaner:
- 启动 TeamViewer (Classic) 应用程序。
- 打开 TeamViewer (Classic) ➜ 首选项 ➜ 高级。
- 向下滚动直到卸载。
- (可选)选中删除配置文件复选框。
- 单击卸载。
- 当要求确认时单击确定。
该程序已被卸载。
执行帐户分配
先决条件
- TeamViewer (Classic)已安装。
- 启用了“从系统启动”选项。
- TeamViewer (Classic)服务正在运行!
- 分配工具和应用程序一起安装在
- /Applications/TeamViewer (Classic)Host.app/Contents/Helpers/TeamViewer (Classic)_Assignment
- (/Applications/TeamViewer (Classic).app/Contents/Helpers/TeamViewer (Classic)_Assignment)。
步骤
- 在应分配的所有设备上以sudo特权运行分配工具。 为了在大规模部署方案中执行此操作,建议您使用脚本来调用具有所需参数的分配工具。
主机版本:
sudo /Applications/TeamViewer (Classic)Host.app/Contents/Helpers/TeamViewer (Classic)_Assignment -api-token <YOUR_APITOKEN> -group <GROUP> -alias <COMPUTERNAME> -grant-easy-access
Full version:
sudo /Applications/TeamViewer (Classic).app/Contents/Helpers/TeamViewer (Classic)_Assignment -api-token <YOUR_APITOKEN>
- 设备已分配给创建“自定义TeamViewer (Classic)主机”模块的帐户。
- (可选)为设备激活EasyAccess
分配选项
下列表格显示了可能的分配选项(都是可选的)。有些参数需要一个值(-aliasMyAlias)或者不需要值(-reassign)。这些选项需要添加到命令行。
- 如果您的参数值带有空格(例如,组名称),请使用“ <GROUP_NAME_WITH_BLANK>”。
- sudo /Applications/TeamViewer (Classic).app/Contents/Helpers/TeamViewer (Classic)_Assignment -api-token <YOAPITOKEN> -group“我的群组” -alias“ $ ALIAS”
- 参数名称区分大小写
- 可以在ASSIGNMENTOPTIONS中为分配指定代理设置。 TeamViewer (Classic)连接本身还有其他代理设置(在TeamViewer (Classic)客户端选项中定义)。这些必须在ASSIGNMENTOPTIONS之外设置。
- 您还可以在命令中插入环境变量以进行安装/分配,以添加动态值,例如为别名。您可以使用$符号来使用环境变量。变量值中不应包含以下字符:$,@,`,´,并且变量应始终用引号引起来。
- 示例:
- 1. 导出 GROUP =“ MyGroup”
- 2. 导出 ALIAS =“ MyDevicename”
- 3. sudo /Applications/TeamViewer (Classic).app/Contents/Helpers/TeamViewer (Classic)_Assignment -api-token <YOAPITOKEN> -group“ $ GROUP” -alias“ $ ALIAS”
选项
便于您复制粘贴:
Option - 选项
Description - 描述
-api-token <YOUR_APITOKEN>
API Token in order to do the assignment to the correct account
-alias [<name>]
Alias for the new device in the computers & contacts list. If the device is already in the contact list, no alias will be applied. The parameter can take the following values:
- -alias (without value) → alias of the computer will be the teamviewerID sudo
/Applications/TeamViewer (Classic)Host.app/Contents/Helpers/TeamViewer (Classic)_Assignment -api-token <YOUR_APITOKEN> -alias -group MyGroup
- -alias hallo → alias of the computer will be "hallo"
sudo /Applications/TeamViewer (Classic)Host.app/Contents/Helpers/TeamViewer (Classic)_Assignment -api-token <YOUR_APITOKEN> -alias hello -group MyGroup
- alias parameter not specified → alias of this computer will be %computername%
sudo /Applications/TeamViewer (Classic)Host.app/Contents/Helpers/TeamViewer (Classic)_Assignment -api-token <YOUR_APITOKEN> -group MyGroup
If you set this option, easy access is granted after the assignment (same as the "Grant easy access" option in the TeamViewer (Classic) main window).
sudo /Applications/TeamViewer (Classic)Host.app/Contents/Helpers/TeamViewer (Classic)_Assignment -api-token <YOUR_APITOKEN> -grant-easy-access -group MyGroup
Assigns the device to the account even if the device is already assigned to an account.
sudo /Applications/TeamViewer (Classic)Host.app/Contents/Helpers/TeamViewer (Classic)_Assignment -api-token <YOUR_APITOKEN> -reassign -group MyGroup
Name of the group to which the device will be added.
When the group doesn't exist, it will be automatically created.
If the device is already in the computers & contacts list in a different group, it won't be moved to the group.
sudo /Applications/TeamViewer (Classic)Host.app/Contents/Helpers/TeamViewer (Classic)_Assignment -api-token <YOUR_APITOKEN> -group MyGroup
Only required if no custom host is used, as a default group is already defined in the custom configuration.
This option is an alternative to using the --group parameter if the group's id is known.
This might be useful in large customer environments as it speeds up the assignment process. Usually, using --group is sufficient.
Note that the ID must be prepended with a literal "g".
sudo /Applications/TeamViewer (Classic)Host.app/Contents/Helpers/TeamViewer (Classic)_Assignment -api-token <YOUR_APITOKEN> -group-id g123
With this parameter, the waiting time for the assignment can be specified in seconds. The default value of 30 (secs) should usually be sufficient.
sudo /Applications/TeamViewer (Classic)Host.app/Contents/Helpers/TeamViewer (Classic)_Assignment -api-token <YOUR_APITOKEN> -wait 45 -group MyGroup
Url of your proxy (only for the assignment) in the format <name>:<port>, e. g. --proxy yourproxy:3201
sudo /Applications/TeamViewer (Classic)Host.app/Contents/Helpers/TeamViewer (Classic)_Assignment -api-token <YOUR_APITOKEN> -proxy yourproxy:3201 -proxy-user FooBar -proxy-pw mypass -group MyGroup
⚠注意: URL without http://
Username which is used for authentication against the proxy (only for the assignment).
sudo /Applications/TeamViewer (Classic)Host.app/Contents/Helpers/TeamViewer (Classic)_Assignment -api-token <YOUR_APITOKEN> -proxy yourproxy:3201 -proxy-user FooBar -proxy-pw mypass -group MyGroup
Password which is used for authentication against the proxy (only for the assignment).
sudo /Applications/TeamViewer (Classic)Host.app/Contents/Helpers/TeamViewer (Classic)_Assignment -api-token <YOUR_APITOKEN> -proxy yourproxy:3201 -proxy-user FooBar -proxy-pw mypass -group MyGroup
- -proxy-pw-base64 <encoded_password>
Same as --proxy-pw, but the password needs to be entered as a Base64 encoded string. Useful for passwords with special characters.
sudo /Applications/TeamViewer (Classic)Host.app/Contents/Helpers/TeamViewer (Classic)_Assignment -api-token <YOUR_APITOKEN> -proxy yourproxy:3201 -proxy-user FooBar -proxy-pw-base64 bXlwYXNz -group MyGroup