GitXplorerGitXplorer
a

arconboard-psremote

public
0 stars
0 forks
0 issues

Commits

List of commits on branch main.
Verified
bc3b39be45a80acda665a5334e767b0500c456e3

Update README.md

aaurnovcy committed 3 years ago
Verified
676a8bfd63b38bec4b8ac22f1b098856e2b4c19f

Update README.md

aaurnovcy committed 3 years ago
Verified
e7706233591e96c7ea8dba4c9ecf43157cd6415a

Update README.md

aaurnovcy committed 3 years ago
Verified
4a8a340d1f664f8080ad46f4d318fdf58d732abc

Update README.md

aaurnovcy committed 3 years ago
Verified
2fa2cb3f5ffcdedb6b528ed781000d23c7454646

Update README.md

aaurnovcy committed 3 years ago
Verified
058422836f9f9615d9898e342dd6a531c5e4118c

Initial commit

aaurnovcy committed 3 years ago

README

The README file for this repository.

Onboard to Azure Arc-enabled servers with PowerShell Remoting

You can use the PowerShell cmdlet Connect-AzConnectedMachine to download the Connected Machine agent, install the agent, and register the machine with Azure Arc. The cmdlet downloads the Windows agent package (Windows Installer) from the Microsoft Download Center. You use this process to remotely onboard multiple Windows servers to Azure Arc at scale by using PowerShell remoting.

PowerShell Remoting Script

Run the following script with administrator privileges. Enter the names of the non-Azure machines to onboard within the array and details of the Azure landing zone (Subscription, Resource Group, and Region) to the placeholder variables. You will need to interactively provide Azure credentials once before deployment.

Note the Supported Environment, OS, and Software requirements as outlined on https://docs.microsoft.com/en-us/azure/azure-arc/servers/agent-overview#prerequisites must be met for each listed hybrid machine for successful onboarding.

Enable-PSRemoting
Install-Module -Name Az.ConnectedMachine

$Computers = @("INSERT-COMPUTER-NAME-1", "INSERT-COMPUTER-NAME-2")
$Subscription = "INSERT-SUBSCRIPTION-NAME"
$ResourceGroup = "INSERT-RESOURCE-GROUP-NAME"
$Region = "INSERT-REGION-NAME"
$SecureCredentials = Connect-AzAccount

ForEach($Computer in $Computers) 
{
  $Session = New-PSSession -ComputerName $Computer -Credential $SecureCredentials
  Connect-AzConnectedMachine -SubscriptionId $Subscription -ResourceGroupName $ResourceGroup -Name $Computer -Location $Region -PSSession $Session
  Remove-PSSession $Session
}