Skip to content

Commit f6b70b4

Browse files
George WallaceGeorge Wallace
George Wallace
authored and
George Wallace
committed
automation : adding note about connect-azurermaccount
1 parent 9f70abc commit f6b70b4

9 files changed

+30
-4
lines changed

articles/automation/automation-connections.md

+3
Original file line numberDiff line numberDiff line change
@@ -90,6 +90,9 @@ $Conn = Get-AutomationConnection -Name AzureRunAsConnection
9090
Connect-AzureRmAccount -ServicePrincipal -Tenant $Conn.TenantID -ApplicationId $Conn.ApplicationID -CertificateThumbprint $Conn.CertificateThumbprint
9191
```
9292

93+
> [!IMPORTANT]
94+
> **Add-AzureRmAccount** is now an alias for **Connect-AzureRMAccount**. When searching your library items, if you do not see **Connect-AzureRMAccount**, you can use **Add-AzureRmAccount**, or you can update your modules in your Automation Account.
95+
9396
### Graphical runbook samples
9497

9598
You add a **Get-AutomationConnection** activity to a graphical runbook by right-clicking on the connection in the Library pane of the graphical editor and selecting **Add to canvas**.

articles/automation/automation-create-runas-account.md

+3
Original file line numberDiff line numberDiff line change
@@ -244,6 +244,9 @@ This PowerShell script includes support for the following configurations:
244244
}
245245
```
246246
247+
> [!IMPORTANT]
248+
> **Add-AzureRmAccount** is now an alias for **Connect-AzureRMAccount**. When searching your library items, if you do not see **Connect-AzureRMAccount**, you can use **Add-AzureRmAccount**, or you can update your modules in your Automation Account.
249+
247250
2. On your computer, start **Windows PowerShell** from the **Start** screen with elevated user rights.
248251
3. From the elevated command-line shell, go to the folder that contains the script you created in step 1.
249252
4. Execute the script by using the parameter values for the configuration you require.

articles/automation/automation-first-runbook-textual-powershell.md

+6-3
Original file line numberDiff line numberDiff line change
@@ -82,13 +82,16 @@ You've tested and published your runbook, but so far it doesn't do anything usef
8282
1. Open the textual editor by clicking **Edit** on the MyFirstRunbook-PowerShell page.
8383
2. You don't need the **Write-Output** line anymore, so go ahead and delete it.
8484
3. Type or copy and paste the following code that handles the authentication with your Automation Run As account:
85-
86-
```
85+
86+
```powershell
8787
$Conn = Get-AutomationConnection -Name AzureRunAsConnection
8888
Connect-AzureRmAccount -ServicePrincipal -Tenant $Conn.TenantID `
8989
-ApplicationId $Conn.ApplicationID -CertificateThumbprint $Conn.CertificateThumbprint
9090
```
91-
<br>
91+
92+
> [!IMPORTANT]
93+
> **Add-AzureRmAccount** and **Login-AzureRmAccount** are now aliases for **Connect-AzureRMAccount**. If the **Connect-AzureRMAccount** cmdlet does not exist, you can use **Add-AzureRmAccount** or **Login-AzureRmAccount**, or you can update your modules in your Automation Account to the latest versions.
94+
9295
4. Click **Test pane** so that you can test the runbook.
9396
5. Click **Start** to start the test. Once it completes, you should receive output similar to the following, displaying basic information from your account. This confirms that the credential is valid.<br><br> ![Authenticate](media/automation-first-runbook-textual-powershell/runbook-auth-output.png)
9497

articles/automation/automation-first-runbook-textual.md

+4
Original file line numberDiff line numberDiff line change
@@ -105,6 +105,10 @@ you've tested and published your runbook, but so far it doesn't do anything usef
105105
Connect-AzureRmAccount -ServicePrincipal -Tenant $Conn.TenantID `
106106
-ApplicationId $Conn.ApplicationID -CertificateThumbprint $Conn.CertificateThumbprint
107107
```
108+
109+
> [!IMPORTANT]
110+
> **Add-AzureRmAccount** and **Login-AzureRmAccount** are now aliases for **Connect-AzureRMAccount**. If the **Connect-AzureRMAccount** cmdlet does not exist, you can use **Add-AzureRmAccount** or **Login-AzureRmAccount**, or you can update your modules in your Automation Account to the latest versions.
111+
108112
5. Click **Test pane** so that you can test the runbook.
109113
6. Click **Start** to start the test. Once it completes, you should receive output similar to the following, displaying basic information from your account. This confirms that the credential is valid.<br><br> ![Authenticate](media/automation-first-runbook-textual/runbook-auth-output.png)
110114

articles/automation/automation-graphical-authoring-intro.md

+3
Original file line numberDiff line numberDiff line change
@@ -284,6 +284,9 @@ The next activity, Connect-AzureRmAccount, adds the authenticated Run As account
284284

285285
![Connect-AzureRmAccount Parameter Set](media/automation-graphical-authoring-intro/authenticate-conn-to-azure-parameter-set.png)
286286

287+
> [!IMPORTANT]
288+
> **Add-AzureRmAccount** is now an alias for **Connect-AzureRMAccount**. When searching your library items, if you do not see **Connect-AzureRMAccount**, you can use **Add-AzureRmAccount**, or you can update your modules in your Automation Account.
289+
287290
For the parameters **APPLICATIONID**, **CERTIFICATETHUMBPRINT**, and **TENANTID** you need to specify the name of the property for the Field path because the activity outputs an object with multiple properties. Otherwise when you execute the runbook, it fails attempting to authenticate. This is what you need at a minimum to authenticate your runbook with the Run As account.
288291

289292
To maintain backwards compatibility for subscribers who have created an Automation account using an [Azure AD User account](automation-create-aduser-account.md) to manage Azure classic deployment or for Azure Resource Manager resources, the method to authenticate is the Add-AzureAccount cmdlet with a [credential asset](automation-credentials.md) that represents an Active Directory user with access to the Azure account.

articles/automation/automation-hrw-run-runbooks.md

+3
Original file line numberDiff line numberDiff line change
@@ -145,6 +145,9 @@ Set-AzureRmContext -SubscriptionId $RunAsConnection.SubscriptionID | Write-Verbo
145145
Get-AzureRmAutomationAccount | Select-Object AutomationAccountName
146146
```
147147

148+
> [!IMPORTANT]
149+
> **Add-AzureRmAccount** is now an alias for **Connect-AzureRMAccount**. When searching your library items, if you do not see **Connect-AzureRMAccount**, you can use **Add-AzureRmAccount**, or you can update your modules in your Automation Account.
150+
148151
Save the *Export-RunAsCertificateToHybridWorker* runbook to your computer with a `.ps1` extension. Import it into your Automation account and edit the runbook, changing the value of the variable `$Password` with your own password. Publish and then run the runbook targeting the Hybrid Worker group that run and authenticate runbooks using the Run As account. The job stream reports the attempt to import the certificate into the local machine store, and follows with multiple lines depending on how many Automation accounts are defined in your subscription and if authentication is successful.
149152

150153
## Job behavior

articles/automation/automation-pass-json-string.md

+4
Original file line numberDiff line numberDiff line change
@@ -83,6 +83,10 @@ Run the following PowerShell commands:
8383
Connect-AzureRmAccount
8484
```
8585
You are prompted to enter your Azure credentials.
86+
87+
> [!IMPORTANT]
88+
> **Add-AzureRmAccount** is now an alias for **Connect-AzureRMAccount**. When searching your library items, if you do not see **Connect-AzureRMAccount**, you can use **Add-AzureRmAccount**, or you can update your modules in your Automation Account.
89+
8690
1. Get the contents of the JSON file and convert it to a string:
8791
```powershell
8892
$json =  (Get-content -path 'JsonPath\test.json' -Raw) | Out-string

articles/automation/automation-powershell-workflow.md

+3
Original file line numberDiff line numberDiff line change
@@ -280,6 +280,9 @@ workflow CreateTestVms
280280
}
281281
```
282282

283+
> [!IMPORTANT]
284+
> **Add-AzureRmAccount** is now an alias for **Connect-AzureRMAccount**. When searching your library items, if you do not see **Connect-AzureRMAccount**, you can use **Add-AzureRmAccount**, or you can update your modules in your Automation Account.
285+
283286
This is not required if you are authenticating using a Run As account configured with a service principal.
284287

285288
For more information about checkpoints, see [Adding Checkpoints to a Script Workflow](http://technet.microsoft.com/library/jj574114.aspx).

articles/automation/automation-verify-runas-authentication.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -58,7 +58,7 @@ Use the sample code below to [create a PowerShell runbook](automation-creating-i
5858
Notice the cmdlet used for authenticating in the runbook - **Connect-AzureRmAccount**, uses the *ServicePrincipalCertificate* parameter set. It authenticates by using service principal certificate, not credentials.
5959

6060
> [!IMPORTANT]
61-
> **Add-AzureRmAccount** is now an alias for **Connect-AzureRMAccount**. if you do not see **Connect-AzureRMAccount**, you can use **Add-AzureRmAccount**, or you can update your modules in your Automation Account.
61+
> **Add-AzureRmAccount** is now an alias for **Connect-AzureRMAccount**. When searching your library items, if you do not see **Connect-AzureRMAccount**, you can use **Add-AzureRmAccount**, or you can update your modules in your Automation Account.
6262
6363
When you [run the runbook](automation-starting-a-runbook.md#starting-a-runbook-with-the-azure-portal) to validate your Run As account, a [runbook job](automation-runbook-execution.md) is created, the job page is displayed, and the job status displayed in the **Job Summary** tile. The job status will start as *Queued* indicating that it is waiting for a runbook worker in the cloud to become available. It will then move to *Starting* when a worker claims the job, and then *Running* when the runbook actually starts running. When the runbook job completes, we should see a status of **Completed**.
6464

0 commit comments

Comments
 (0)