11.Adding the Azure trial to the Office 365 account
Once you have signed up33 and established your (test) organization with an account in Office 365 Enterprise E3, you can then add an Azure trial subscription to your Office 365 account. This can be achieved by accessing the Azure Sign Up page at https://account.windowsazure.com/SignUp with your Office 365 global administrator account. You need to select Sign in with your organizational account for that purpose.
Note You can log into the Office 365 administrator portal and go to the Azure Signup page or go directly to the signup page, select sign in with an organizational account and log in with your Office 365 global administrator credentials. Once you have completed your trial tenant signup you will be redirected to the Azure account portal34 and can proceed to the Azure management portal by clicking Portal at the top right corner of your screen.
At this stage, you should have an Office 365 Enterprise E3 trial subscription with an Azure trial subscription.
12.Preparing the local environment for Azure
Microsoft Azure PowerShell is the module for Windows PowerShell that you can use to control and automate the deployment and management of the Moodle workload in Azure.
The configuration of Azure PowerShell on a local computer consists in:
-
Installing Azure PowerShell,
-
Verifying that Azure PowerShell can run scripts, and enabling scripts to run in Windows PowerShell,
-
Verifying that WinRM allows Windows PowerShell to connect, and configuring WinRM to support basic authentication.
Note that this local computer must have Internet connectivity.
To install the Azure PowerShell module, proceed with the following steps:
-
Open a browsing session and navigate to the Azure Downloads35 page.
-
Scroll down to Command line tools.
-
Click Install.
-
When prompted to run or save the .exe installation file (WindowsAzurePowerShell.3f.3.3fnew.exe), click Run. A Web Platform Installer 5.0 dialog opens up.
-
Click Install to continue.
-
Click I Accept.
-
At the end of the installation, click Finish to close the Web Platform Installer 5.0 wizard.
-
Click Exit.
You can run then the cmdlets from the Azure PowerShell console.
14.Connecting to your Azure subscription
To connect to your Azure subscription with the Azure PowerShell console, proceed with the following steps:
-
On the local computer, type "power" in the search function in the Start screen.
This search will return the list of applications containing the word "power," including Microsoft Azure PowerShell. Click on the application to start the console of the same name.
-
Run the following command in the Microsoft Azure PowerShell console:
Add-AzureAccount
A sign-in dialog opens up.
-
Type the email address corresponding to your Azure account and click Continue. You’re redirected to a Sign In page.
-
Type the password associated with your account and click Sign in. Azure authenticates you, saves the credential information, and then closes the dialog. A message states that your subscription is now selected as the default subscription.
-
Once connected to your default subscription, you can use the built-in Help system to list and get help about the cmdlets in the Azure PowerShell module. To list the available cmdlets, run the following command:
help azure
You can then display help about a specific cmdlet by typing help followed by the name of the cmdlet, for example “help New-AzureVM”.
Note For instructions, see the Microsoft TechNet articles How to install and configure Azure PowerShell36 and Get Started with Azure Cmdlets37.
Note For more information about the cmdlets in the Azure PowerShell module, see the Microsoft MSDN article Azure Management Cmdlets38.
15.Enabling Windows PowerShell scripts
To verify that Azure PowerShell can run scripts, proceed with the following steps;
-
Open an elevated Azure PowerShell command prompt, and run the following command:
Get-ExecutionPolicy
-
If the value returned is anything other than RemoteSigned, you need to change the value to RemoteSigned.
Note A digital signature is required from a trusted publisher on scripts and configuration files that are downloaded from the Internet (including email and instant messaging programs) so that they can run. However, a digital signature isn’t required on scripts that you have written on the local computer (not downloaded from the Internet). Finally, you can run scripts that are downloaded from the Internet and not signed, if the scripts are unblocked, such as by using the Unblock-File cmdlet. For more information, see the Microsoft TechNet article about_Execution_Policies39.
Run the following command if needed:
Set-ExecutionPolicy RemoteSigned
When asked, press “Y” to confirm the operation.
To verify that WinRM allows Windows PowerShell to connect, proceeds as follows:
-
In the above elevated Azure PowerShell session, run the following command to check the status of the WinRM service:
sc query winrm
-
If the WinRM service isn’t running, start it with the following command:
net start winrm
-
Run the following command:
winrm get winrm/config/client/auth
-
In the results, look for the value “Basic =”. If the value is “Basic = false”, you must change the value to “Basic = true”.
If the value has to be changed, run the following command:
winrm set winrm/config/client/auth @{Basic="true"}
The value between the braces { } is case-sensitive. In the command output, verify the value “Basic = true”.
-
If you started the WinRM service in step 2, run the following command to stop it:
net stop winrm
You are now ready to setup the virtual machines needed for the Moodle platform.
This is the purpose of the next section.
Share with your friends: |