你当前正在访问 Microsoft Azure Global Edition 技术文档网站。 如果需要访问由世纪互联运营的 Microsoft Azure 中国技术文档网站,请访问 https://docs.azure.cn。
Start-AzAksDashboard
创建指向托管群集仪表板的 Kubectl SSH 隧道。
语法
Start-AzAksDashboard
[-ResourceGroupName] <String>
[-Name] <String>
[-DisableBrowser]
[-ListenPort <Int32>]
[-PassThru]
[-DefaultProfile <IAzureContextContainer>]
[-SubscriptionId <String>]
[<CommonParameters>]
Start-AzAksDashboard
[-InputObject] <PSKubernetesCluster>
[-DisableBrowser]
[-ListenPort <Int32>]
[-PassThru]
[-DefaultProfile <IAzureContextContainer>]
[-SubscriptionId <String>]
[<CommonParameters>]
Start-AzAksDashboard
[-Id] <String>
[-DisableBrowser]
[-ListenPort <Int32>]
[-PassThru]
[-DefaultProfile <IAzureContextContainer>]
[-SubscriptionId <String>]
[<CommonParameters>]
说明
创建指向托管群集仪表板的 Kubectl SSH 隧道。 SSH 隧道是在名为 Kubectl-Tunnel 的 PowerShell 作业中设置的,可以通过运行 Get-Job
找到。 隧道应可通过 http://127.0.0.1:8001访问。
示例
启动 SSH 隧道并打开浏览器到 Kubernetes 仪表板
Start-AzAksDashboard -ResourceGroupName group -Name myCluster
参数
-DefaultProfile
用于与 Azure 通信的凭据、帐户、租户和订阅。
类型: | IAzureContextContainer |
别名: | AzContext, AzureRmContext, AzureCredential |
Position: | Named |
默认值: | None |
必需: | False |
接受管道输入: | False |
接受通配符: | False |
-DisableBrowser
建立 kubectl 端口转发后不要弹出浏览器。
类型: | SwitchParameter |
Position: | Named |
默认值: | None |
必需: | False |
接受管道输入: | False |
接受通配符: | False |
-Id
托管 Kubernetes 群集的 ID
类型: | String |
别名: | ResourceId |
Position: | 0 |
默认值: | None |
必需: | True |
接受管道输入: | True |
接受通配符: | False |
-InputObject
PSKubernetesCluster 对象,通常通过管道传递。
类型: | PSKubernetesCluster |
Position: | 0 |
默认值: | None |
必需: | True |
接受管道输入: | True |
接受通配符: | False |
-ListenPort
仪表板的侦听端口。 默认值为 8003。
类型: | Int32 |
Position: | Named |
默认值: | None |
必需: | False |
接受管道输入: | False |
接受通配符: | False |
-Name
托管 Kubernetes 群集的名称
类型: | String |
Position: | 1 |
默认值: | None |
必需: | True |
接受管道输入: | False |
接受通配符: | False |
-PassThru
Cmdlet 返回 KubeTunnelJob(如果传递)。
类型: | SwitchParameter |
Position: | Named |
默认值: | None |
必需: | False |
接受管道输入: | False |
接受通配符: | False |
-ResourceGroupName
资源组名称
类型: | String |
Position: | 0 |
默认值: | None |
必需: | True |
接受管道输入: | False |
接受通配符: | False |
-SubscriptionId
订阅的 ID。 默认情况下,cmdlet 在当前上下文中设置的订阅中执行。 如果用户指定另一个订阅,则当前 cmdlet 在用户指定的订阅中执行。 重写订阅仅在当前 cmdlet 的生命周期内生效。 它不会更改上下文中的订阅,并且不会影响后续 cmdlet。
类型: | String |
Position: | Named |
默认值: | None |
必需: | False |
接受管道输入: | True |
接受通配符: | False |