Skip to content

Commit 9e53a7f

Browse files
authored
Merge pull request #214518 from maertendMSFT/patch-7
Update ssh-arc-overview.md to include Azure PowerShell
2 parents b73bed1 + 56bd2d0 commit 9e53a7f

File tree

1 file changed

+38
-35
lines changed

1 file changed

+38
-35
lines changed

articles/azure-arc/servers/ssh-arc-overview.md

Lines changed: 38 additions & 35 deletions
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ allowing existing management tools to have a greater impact on Azure Arc-enabled
1919
SSH access to Arc-enabled servers provides the following key benefits:
2020
- No public IP address or open SSH ports required
2121
- Access to Windows and Linux machines
22-
- Ability to log-in as a local user or an [Azure user (Linux only)](../../active-directory/devices/howto-vm-sign-in-azure-ad-linux.md)
22+
- Ability to log in as a local user or an [Azure user (Linux only)](../../active-directory/devices/howto-vm-sign-in-azure-ad-linux.md)
2323
- Support for other OpenSSH based tooling with config file support
2424

2525
## Prerequisites
@@ -42,32 +42,54 @@ SSH access to Arc-enabled servers is currently supported in the following region
4242
- Ubuntu Server: Ubuntu Server 16.04 to Ubuntu Server 20.04
4343

4444
## Getting started
45-
### Register the HybridConnectivity resource provider
45+
46+
### Install local command line tool
47+
This functionality is currently packaged in an Azure CLI extension and an Azure PowerShell module.
48+
#### [Install Azure CLI extension](#tab/azure-cli)
49+
50+
```az extension add --name ssh```
51+
4652
> [!NOTE]
47-
> This is a one-time operation that needs to be performed on each subscription.
53+
> The Azure CLI extension version must be greater than 1.1.0.
4854
49-
Check if the HybridConnectivity resource provider (RP) has been registered:
55+
#### [Install Azure PowerShell module](#tab/azure-powershell)
5056

51-
```az provider show -n Microsoft.HybridConnectivity```
57+
```Install-Module -Name AzPreview -Scope CurrentUser -Repository PSGallery -Force```
5258

53-
If the RP has not been registered, run the following:
59+
### Enable functionality on your Arc-enabled server
60+
In order to use the SSH connect feature, you must enable connections on the hybrid agent.
5461

55-
```az provider register -n Microsoft.HybridConnectivity```
62+
> [!NOTE]
63+
> The following actions must be completed in an elevated terminal session.
5664
57-
This operation can take 2-5 minutes to complete. Before moving on, check that the RP has been registered.
65+
View your current incoming connections:
5866

59-
### Install az CLI extension
60-
This functionality is currently package in an az CLI extension.
61-
In order to install this extension, run:
67+
```azcmagent config list```
6268

63-
```az extension add --name ssh```
69+
If you have existing ports, you'll need to include them in the following command.
6470

65-
If you already have the extension installed, it can be updated by running:
71+
To add access to SSH connections, run the following:
6672

67-
```az extension update --name ssh```
73+
```azcmagent config set incomingconnections.ports 22<,other open ports,...>```
74+
75+
If you're using a non-default port for your SSH connection, replace port 22 with your desired port in the previous command.
6876

6977
> [!NOTE]
70-
> The Azure CLI extension version must be greater than 1.1.0.
78+
> The following steps will not need to be run for most users.
79+
80+
### Register the HybridConnectivity resource provider
81+
> [!NOTE]
82+
> This is a one-time operation that needs to be performed on each subscription.
83+
84+
Check if the HybridConnectivity resource provider (RP) has been registered:
85+
86+
```az provider show -n Microsoft.HybridConnectivity```
87+
88+
If the RP hasn't been registered, run the following:
89+
90+
```az provider register -n Microsoft.HybridConnectivity```
91+
92+
This operation can take 2-5 minutes to complete. Before moving on, check that the RP has been registered.
7193

7294
### Create default connectivity endpoint
7395
> [!NOTE]
@@ -86,24 +108,5 @@ Validate endpoint creation:
86108
az rest --method get --uri https://management.azure.com/subscriptions/<subscription>/resourceGroups/<resourcegroup>/providers/Microsoft.HybridCompute/machines/<arc enabled server name>/providers/Microsoft.HybridConnectivity/endpoints/default?api-version=2021-10-06-preview
87109
```
88110

89-
### Enable functionality on your Arc-enabled server
90-
In order to use the SSH connect feature, you must enable connections on the hybrid agent.
91-
92-
> [!NOTE]
93-
> The following actions must be completed in an elevated terminal session.
94-
95-
View your current incoming connections:
96-
97-
```azcmagent config list```
98-
99-
If you have existing ports, you will need to include them in the following command.
100-
101-
To add access to SSH connections, run the following:
102-
103-
```azcmagent config set incomingconnections.ports 22<,other open ports,...>```
104-
105-
> [!NOTE]
106-
> If you are using a non-default port for your SSH connection, replace port 22 with your desired port in the previous command.
107-
108111
## Examples
109-
To view examples of using the ```az ssh arc``` command, view the az CLI documentation page for [az ssh](/cli/azure/ssh).
112+
To view examples, view the Az CLI documentation page for [az ssh](/cli/azure/ssh) or the Azure PowerShell documentation page for [Az.Ssh](/powershell/module/az.ssh).

0 commit comments

Comments
 (0)