退回店面

退回店面是一种弹性功能,可在工作区中断期间通过您的店面实例临时访问Citrix虚拟应用程序和台式机。您可以使用任何有效URL访问Citrix虚拟应用程序和台式机,但Citrix建议您使用以下其中一项退回到店面:

  • 单个内部URL或URL列表,解析到公司网络中的店面服务器。
  • 单个外部URL或外部URL列表,解析到Citrix Gateway,其后面部署了StoreFront。
  • 一个GSLB URL,它解析为带有店面的多个Citrix网关的GSLB层。

退回店面该功能是使用PowerShell配置的,PowerShell对Citrix云客户执行经过身份验证的REST API调用。PowerShell cmdlet在独立的PowerShell模块中提供,可以从任何具有internet访问权限的计算机下载和运行。

笔记:

下载的PowerShell模块是RemotepowersHell SDK的不同SDK,用于配置Citrix虚拟应用程序和桌面服务。

配置返回店面

使用PowerShell返回到店面配置涉及以下任务:

  1. 下载PowerShell模块
  2. 创建和存储一个Citrix云API客户端和秘密
  3. 识别GSLB,Gateway或StoreFront实例的URL
  4. 导入PowerShell模块并配置一个或多个店面回退URL
  5. 验证您的StoreFront回退URL已正确配置

下载PowerShell模块

在您配置之前退回店面,下载并解压缩提供的CitrixPowerShell模块来自GitHub。该文件包括Citrix.Workspace.FallbackConfiguration.psm1和Citrix.Workspace.FallbackConfiguration.psd1

重要的是:

提供的PowerShell脚本专为欧盟、美国和AP-S地区的客户设计。日本地区的Citrix Cloud客户必须使用.json配置文件以针对日本Citrix Cloud的REST API调用为目标。如果您的客户在Citrix Cloud Commercial EU、US和AP-S,您可以忽略此步骤并删除对$env:CTXSWSPOSHSETTINGS来自脚本的变量。

Citrix Cloud客户在日本地区也必须下载jp-production.json

需要配置详细信息

配置退回店面,您需要以下各项:

  • GSLB,Gateway或Storefront实例的URL。
  • Citrix云API客户端和机密。

如果您还没有Citrix Cloud API客户端和秘密,则可以通过以下文章创建一个:https://developer.cloud.com/explore-more-apis-and-sdk/cloud-services-platform/citrix-cloud-api-overview/docs/get-started-with-citrix-cloud-apis。安全地存储这些凭据并将其视为敏感数据。

配置StoreFront回退url

  1. 将FallbackPowershellModule.zip文件解压缩到要运行PowerShell的适当目录,例如当前用户的桌面。
  2. 打开PowerShell ISE并选择刚出现的* 在里面文件菜单。
  3. 将示例脚本复制到交互式PowerShell窗口中,以便您可以针对自己的窗口修改并运行它Citrix云顾客。
  4. 设定$ stffallbackpath.变量为将FallbackPowershellModule.zip文件解压缩到的目录的路径。
  5. 配置$ yourcustomerapikey.$YourCustomerSecretKey$ yourcustomerurl.PowerShell脚本中的变量,以及在需要配置详细信息步。

    $ yourcustomerapikey =“”$ yourcustomersecretkey =“$ yourcustomerurl =”https://  .cloud.com“<! -  caltcopy  - >
  6. 导入PowerShell模块

    如果(测试路径-路径“$STFFallbackPath\Citrix.Workspace.FallbackConfiguration.psm1”){写入主机“导入STF Fallback Powershell模块…”-ForegroundColor“绿色”导入模块-名称“$STFFallbackPath\Citrix.Workspace.FallbackConfiguration.psm1”-verbose}否则{在$STFFallbackPath中找不到写入主机“STF Fallback Powershell模块”-前底色“红色”}<<--需要复制-->
  7. 通过更新serviceTeTle.storewebaddress.参数。serviceTeTle.是您希望订阅者看到的有意义的名称,例如“StoreFront EU”。storewebaddress.是Web或网关URL的接收器的完整路径。以下示例包括三个店面倒退URL:

    设置WorkspaceFallbackConfiguration-WorkspaceUrl$YourCustomerURL`-ClientId$YourCustomerAPI`-ClientSecret$YourCustomerSecretKey`-Configuration@{“ServiceTitle”=“StoreFront EU”;“StoreWebAddress”=”https://storefront-eu.example.com/Citrix/StoreWeb/“},`@{“ServiceTitle”=“StoreFront US”;“StoreWebAddress”="https://storefront-us.domain.com/Citrix/StoreWeb/},`@{“ServiceTitle”=“亚太地区店面”;“StoreWebAddress”=”https://storefront-apac.domain.com/Citrix/StoreWeb/“}<!--NeedCopy-->
  8. 要验证StoreFront回退URL已正确配置,请遵循下面的说明查看StoreFront回退url

查看StoreFront回退url

要查看已配置的StoreFront返回URL,请运行Get-WorkspaceFallbackConfigurationcmdlet。

Get-WorkspaceFallbackConfiguration -WorkspaceUrl $YourCustomerURL ' -ClientId $YourCustomerAPIKey ' -ClientSecret $YourCustomerAPIKey ' -Verbose 

删除StoreFront回退url

要删除已配置的店面倒退URL,请运行删除工作空间回退配置cmdlet。使用此CMDlet时,所有URL都被删除。

remove-workspacefallbackconfiguration -workspaceurl $ yourcustomerurl` -clientid $ yourcustomerapikey`-clientret $ $ yourcustomersecretkey` -verbose <! -  callcopy  - >

示例脚本

示例脚本包括您可能需要添加,查看和删除StoreFront倒退URL的命令。您无需运行所有命令以执行任何单个函数。对于运行的脚本,始终包含第1-27行。如果您的Citrix Cloud Customer在日本,也取消注释并运行第29-43行。之后,您只能仅包含要执行的功能的命令。

【净。ServicePointManager]:: SecurityProtocol =[净。SecurityProtocolType]:: Tls12 [System.Net。ServicePointManager]:: SecurityProtocol = [System.Net.SecurityProtocolType]:: Tls12;#您的证书从Citrix云身份和访问管理[string]$YourCustomerAPIKey = " " [string]$YourCustomerSecretKey = " " # Commercial US,欧盟或AP-S [string] $ YourCustomerURL = " https:// < yourcustomer > .cloud.com”#或#摩根大通地区# [string] $ YourCustomerURL = " https:// < yourcustomer > .citrixcloud.jp”#包含PowerShell模块的. zip文件解压到一个文件夹# Citrix.Workspace.FallbackConfiguration Import-Module指向相同的路径。$STFFallbackPath = "$Env:UserProfile\Desktop\Fallback" if(Test-Path -Path "$STFFallbackPath\Citrix.Workspace.FallbackConfiguration.psm1") {Write-Host " import STFFallback Powershell Module…"-ForegroundColor "Green" Import-Module -Name "$STFFallbackPath\Citrix.Workspace.FallbackConfiguration. "psm1" -verbose} else {Write-Host "STF Fallback Powershell Module not found inside $STFFallbackPath" - foregroundcolor "Red"} <#取消注释行29 - 43,如果你的Citrix Cloud客户在日本#使用jsp -production。$EnvironmentConfigFile = " js -production. json ",配置$env:CTXSWSPOSHSETTINGS变量。json" if(Test-Path -Path "$STFFallbackPath\$EnvironmentConfigFile") {Write-Host "Setting STFFallback Environment Variables using $EnvironmentConfigFile…"-ForegroundColor "Green" $env:CTXSWSPOSHSETTINGS = "$STFFallbackPath\$EnvironmentConfigFile"} else {Write-Host "Path to $EnvironmentConfigFile config file not found."-ForegroundColor“红色”}# > #显示详细的PowerShell帮助后备cmdlets得到帮助Get-WorkspaceFallbackConfiguration充分得到帮助Set-WorkspaceFallbackConfiguration充分得到帮助Remove-WorkspaceFallbackConfiguration完整#执行回滚管理任务# Get-WorkspaceFallbackConfiguration得到您现有的配置 -WorkspaceUrl $YourCustomerURL ` -ClientId $YourCustomerAPIKey ` -ClientSecret $YourCustomerAPIKey ` -Verbose # Add a new or overwrite/update the existing fallback config Set-WorkspaceFallbackConfiguration -WorkspaceUrl $YourCustomerURL ` -ClientId $YourCustomerAPIKey ` -ClientSecret $YourCustomerSecretKey ` -Configuration @{ "ServiceTitle" = "StoreFront EU"; "StoreWebAddress" = "https://storefront-eu.example.com/Citrix/StoreWeb/"}, ` @{ "ServiceTitle" = "StoreFront US"; "StoreWebAddress" = "https://storefront-us.domain.com/Citrix/StoreWeb/" }, ` @{ "ServiceTitle" = "StoreFront APAC"; "StoreWebAddress" = "https://storefront-apac.domain.com/Citrix/StoreWeb/" } # Remove the existing Fallback configuration Remove-WorkspaceFallbackConfiguration -WorkspaceUrl $YourCustomerURL ` -ClientId $YourCustomerAPIKey ` -ClientSecret $YourCustomerSecretKey ` -Verbose 

额外的帮助和支持

有关帮助或问题的故障排除,请联系Citrix销售代表或Citrix支持

退回店面