Citrix Virtual Apps and Desktops

发布内容

您可以发布一个应用程序,该应用程序只是指向资源的 URL 或 UNC 路径,例如 Microsoft Word 文档或网页链接。此功能称为已发布内容。发布内容的功能增加了向用户交付内容的灵活性。您可以从现有的应用程序访问控制和管理中受益。您还可以指定是使用本地应用程序还是已发布的应用程序来打开内容。

已发布内容在 StoreFront™ 和 Citrix Workspace™ 应用程序中显示方式与其他应用程序相同。用户访问它的方式与访问应用程序的方式相同。在客户端上,资源照常打开。

  • 如果本地安装的应用程序适用,则会启动它来打开资源。
  • 如果已定义文件类型关联,则会启动已发布的应用程序来打开资源。

您可以使用 PowerShell SDK 发布内容。您不能使用 Studio 发布内容。但是,您可以在内容发布后使用 Studio 编辑应用程序属性。

配置的概览和准备工作

发布内容使用 New-BrokerApplication cmdlet,其中包含以下关键属性。(有关所有 cmdlet 属性的说明,请参阅 cmdlet 帮助。)

New-BrokerApplication –ApplicationType PublishedContent -CommandLineExecutable location -Name app-name -DesktopGroup delivery-group-name
<!--NeedCopy-->

ApplicationType 属性必须为 PublishedContent

CommandLineExecutable 属性指定已发布内容的位置。支持以下格式,字符限制为 255 个。

  • HTML 网站地址(例如,http://www.citrix.com
  • Web 服务器上的文档文件(例如,https://www.citrix.com/press/pressrelease.doc
  • FTP 服务器上的目录(例如,ftp://ftp.citrix.com/code
  • FTP 服务器上的文档文件(例如,ftp://ftp.citrix.com/code/Readme.txt>)
  • UNC 目录路径(例如,file://myServer/myShare or \\\\myServer\\myShare
  • UNC 文件路径(例如,file://myServer/myShare/myFile.asf\\myServer\myShare\myFile.asf

确保您拥有正确的 SDK。

  • For Citrix DaaS (formerly Citrix Virtual Apps and Desktops service) deployments, download and install the Citrix Virtual Apps and Desktops Remote PowerShell SDK.
  • For on-premises Citrix Virtual Apps and Desktops deployments, use the PowerShell SDK that is installed with the Delivery Controller. Adding a published content application requires a minimum version 7.11 Delivery Controller.

以下过程使用示例。在示例中:

  • 已创建计算机目录。
  • 已创建名为 PublishedContentApps 的交付组。该组使用目录中的多会话操作系统计算机。WordPad 应用程序已添加到该组。
  • 已为交付组名称、CommandLineExecutable 位置和应用程序名称进行分配。

开始使用

在安装有 PowerShell SDK 的计算机上,请打开 PowerShell 命令行界面。

以下 cmdlet 添加相应的 PowerShell SDK 管理单元,并分配返回的交付组记录。

Add-PsSnapin Citrix\* $dg = Get-BrokerDesktopGroup –Name PublishedContentApps

如果您正在使用 Citrix DaaS,请通过输入您的 Citrix Cloud™ 凭据进行身份验证。如果有多个客户,请选择一个。

发布 URL

分配位置和应用程序名称后,以下 cmdlet 将 Citrix® 主页发布为应用程序。

$citrixUrl = "https://www.citrix.com/"
$appName = "Citrix Home Page"

New-BrokerApplication –ApplicationType PublishedContent –CommandLineExecutable $citrixURL –Name $appName –DesktopGroup $dg.Uid
<!--NeedCopy-->

验证成功:

发布位于 UNC 路径的资源

在此示例中,管理员已创建了一个名为 PublishedResources 的共享。分配位置和应用程序名称后,以下 cmdlet 将该共享中的 RTF 和 DOCX 文件作为资源发布。

$rtfUNC = "\\GMSXJ-EDGE0.xd.local\\PublishedResources\\PublishedRTF.rtf"
$rtfAppName = "PublishedRTF"

New-BrokerApplication –ApplicationType PublishedContent
–CommandLineExecutable $rtfUNC -Name $rtfAppName
-DesktopGroup $dg.Uid

$docxUNC = "\\GMSXJ-EDGE0.xd.local\PublishedResources\PublishedDOCX.docx"
$docxAppName = "PublishedDOCX"

New-BrokerApplication –ApplicationType PublishedContent
–CommandLineExecutable $docxUNC -Name $docxAppName
-DesktopGroup $dg.Uid
<!--NeedCopy-->

验证成功:

  • 刷新 StoreFront 窗口以查看新发布的文档。
  • 单击 PublishedRTFPublishedDOCX 应用程序。每个文档都会在本地运行的写字板中打开。

查看和编辑已发布内容应用程序

您可以使用管理其他应用程序类型的方法来管理已发布的内容。已发布的内容项显示在 Studio 的应用程序列表中,并且可以在 Studio 中进行编辑。

应用程序属性(例如用户可见性、组关联和快捷方式)适用于已发布的内容。但是,您无法在位置页面上更改命令行参数或工作目录属性。要更改资源,请修改该页面上的可执行文件路径字段。

应用程序设置中的可执行文件路径设置

要使用已发布的应用程序打开 PublishedContent 应用程序(而不是本地应用程序),请编辑已发布的应用程序的文件类型关联属性。在此示例中,已发布的写字板应用程序经过编辑,为 .rtf 文件创建了文件类型关联。

在编辑文件类型关联之前,请为交付组启用维护模式。完成后,请记住关闭维护模式。

Studio 中的文件类型关联应用程序设置

刷新 StoreFront 以加载文件类型关联更改,然后单击 PublishedRTFPublishedDOCX 应用程序。请注意区别。PublishedDOCX 仍然在本地 WordPad 中打开。但是,由于文件类型关联,PublishedRTF 现在在已发布的 WordPad 中打开。

应用程序打开位置的示例

欲了解更多信息

发布内容