Added a prerequisite step for the Add-AzureAccount cmdlet. Sometimes, the script may not run correctly (resources not found) if you have the wrong subscription saved in your PS session profile.
Added a warning in the deployment script if the service bus namespace is not found in the subscription. Added debugging options in the iisnode.yml configuration file.
This commit is contained in:
parent
f2819a0799
commit
a1988489e2
|
@ -82,13 +82,20 @@ Try {
|
||||||
|
|
||||||
# Check if the namespace already exists or needs to be created
|
# Check if the namespace already exists or needs to be created
|
||||||
if ($CurrentNamespace) {
|
if ($CurrentNamespace) {
|
||||||
# Set the Web Applicatio settings
|
|
||||||
|
Write-Host -ForegroundColor Magenta "Set application settings for service bus connection..."
|
||||||
|
|
||||||
|
# Set the Web Application settings
|
||||||
$AppSettings = New-Object Hashtable
|
$AppSettings = New-Object Hashtable
|
||||||
$AppSettings["AZURE_SERVICEBUS_ACCESS_KEY"]=$CurrentNamespace.ConnectionString
|
$AppSettings["AZURE_SERVICEBUS_ACCESS_KEY"]=$CurrentNamespace.ConnectionString
|
||||||
|
|
||||||
# Set application settings and enable WebSockets
|
# Set application settings and enable WebSockets
|
||||||
Set-AzureWebsite -Name $AzureWebAppName -AppSettings $AppSettings
|
Set-AzureWebsite -Name $AzureWebAppName -AppSettings $AppSettings
|
||||||
|
} else {
|
||||||
|
|
||||||
|
Write-Warning "Azure Service Bus namespace '$AzureSBNamespace' not found. Make sure you've selected the right Azure subscription (forgot to run the Add-AzureAccount cmdlet?)"
|
||||||
}
|
}
|
||||||
|
|
||||||
Write-Host -ForegroundColor Green "Done!"
|
Write-Host -ForegroundColor Green "Done!"
|
||||||
|
|
||||||
# Deploy the code to the Web Application using Local Git
|
# Deploy the code to the Web Application using Local Git
|
||||||
|
|
|
@ -33,6 +33,7 @@ Here is the solution overview:
|
||||||
Before starting, you'll need to install some prerequisites:
|
Before starting, you'll need to install some prerequisites:
|
||||||
|
|
||||||
- Install the [Azure PowerShell SDK](https://azure.microsoft.com/en-us/documentation/articles/powershell-install-configure/). Make sure you've installed the AzureRM module as well.
|
- Install the [Azure PowerShell SDK](https://azure.microsoft.com/en-us/documentation/articles/powershell-install-configure/). Make sure you've installed the AzureRM module as well.
|
||||||
|
Run the `Add-AzureAccount` cmdlet and optionaly select the correct Azure subscription to work with by running the `Select-AzureSubscription` cmdlet.
|
||||||
- Install the latest release of [PnP PowerShell cmdlets 'SharePointPnPPowerShellOnline'](https://github.com/OfficeDev/PnP-PowerShell/releases) or a version compatible with the 201605 PnP schema version.
|
- Install the latest release of [PnP PowerShell cmdlets 'SharePointPnPPowerShellOnline'](https://github.com/OfficeDev/PnP-PowerShell/releases) or a version compatible with the 201605 PnP schema version.
|
||||||
- Install [Node.js](https://nodejs.org/en/) on your machine.
|
- Install [Node.js](https://nodejs.org/en/) on your machine.
|
||||||
- Install [Git for Windows](https://git-scm.com/download/win).
|
- Install [Git for Windows](https://git-scm.com/download/win).
|
||||||
|
|
|
@ -1 +1,3 @@
|
||||||
debuggingEnabled: true
|
debuggingEnabled: true
|
||||||
|
loggingEnabled: true
|
||||||
|
devErrorsEnabled: true
|
Loading…
Reference in New Issue