Skip to content

Commit 226a1e6

Browse files
Merge pull request #734 from code4clouds/code4clouds-support-message
Add support messaging
2 parents 90223b6 + 324d1aa commit 226a1e6

File tree

2 files changed

+50
-1
lines changed

2 files changed

+50
-1
lines changed

deployment/Deploy.ps1

Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,31 @@
1010
# -Location "<region>" `
1111
# -PublisherAdminUsers "<[email protected]>"
1212

13+
# Define the warning message
14+
$message = @"
15+
The SaaS Accelerator is offered under the MIT License as open source software and is not supported by Microsoft.
16+
17+
If you need help with the accelerator or would like to report defects or feature requests use the Issues feature on the GitHub repository at https://aka.ms/SaaSAccelerator
18+
19+
Do you agree? (Y/N)
20+
"@
21+
22+
# Display the message in yellow
23+
Write-Host $message -ForegroundColor Yellow
24+
25+
# Prompt the user for input
26+
$response = Read-Host
27+
28+
# Check the user's response
29+
if ($response -ne 'Y' -and $response -ne 'y') {
30+
Write-Host "You did not agree. Exiting..." -ForegroundColor Red
31+
exit
32+
}
33+
34+
# Proceed if the user agrees
35+
Write-Host "Thank you for agreeing. Proceeding with the script..." -ForegroundColor Green
36+
37+
1338
Param(
1439
[string][Parameter(Mandatory)]$WebAppNamePrefix, # Prefix used for creating web applications
1540
[string][Parameter()]$ResourceGroupForDeployment, # Name of the resource group to deploy the resources

deployment/Upgrade.ps1

Lines changed: 25 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,30 @@
55
# Powershell script to deploy the resources - Customer portal, Publisher portal and the Azure SQL Database
66
#
77

8+
# Define the message
9+
$message = @"
10+
The SaaS Accelerator is offered under the MIT License as open source software and is not supported by Microsoft.
11+
12+
If you need help with the accelerator or would like to report defects or feature requests use the Issues feature on the GitHub repository at https://aka.ms/SaaSAccelerator
13+
14+
Do you agree? (Y/N)
15+
"@
16+
17+
# Display the message in yellow
18+
Write-Host $message -ForegroundColor Yellow
19+
20+
# Prompt the user for input
21+
$response = Read-Host
22+
23+
# Check the user's response
24+
if ($response -ne 'Y' -and $response -ne 'y') {
25+
Write-Host "You did not agree. Exiting..." -ForegroundColor Red
26+
exit
27+
}
28+
29+
# Proceed if the user agrees
30+
Write-Host "Thank you for agreeing. Proceeding with the script..." -ForegroundColor Green
31+
832
Param(
933
[string][Parameter(Mandatory)]$WebAppNamePrefix, # Prefix used for creating web applications
1034
[string][Parameter(Mandatory)]$ResourceGroupForDeployment # Name of the resource group to deploy the resources
@@ -124,4 +148,4 @@ Write-host "#### Code deployment complete ####"
124148
Write-host ""
125149
Write-host "#### Warning!!! ####"
126150
Write-host "#### If the upgrade is to >=7.5.0, MeterScheduler feature is pre-enabled and changed to DB config instead of the App Service configuration. Please update the IsMeteredBillingEnabled value accordingly in the Admin portal -> Settings page. ####"
127-
Write-host "#### "
151+
Write-host "#### "

0 commit comments

Comments
 (0)