-
Notifications
You must be signed in to change notification settings - Fork 2
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Powershell Changes for Security Type #37
base: generation
Are you sure you want to change the base?
Powershell Changes for Security Type #37
Conversation
if ($HasTargetSecurityType -and $TargetSecurityType -ne "Standard") { | ||
$ProviderSpecificDetails.TargetVMSecurityProfileTargetVmsecurityType = $TargetSecurityType | ||
$ProviderSpecificDetails.TargetVMSecurityProfileIsTargetVmtpmEnabled = $true | ||
} elseif($HasTargetVMSecureBootEnabled) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
nit: Space after elseif.
$ProviderSpecificDetails.TargetVMSecurityProfileIsTargetVmsecureBootEnabled = $TargetVMSecureBootEnabled | ||
} | ||
|
||
if ($HasTargetSecurityType -and $TargetSecurityType -ne "Standard") { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
What if SecureBoot is not passed and SecurityType is TrustedLaunch?
Do we need to keep default value of SecureBoot as True or throw error asking user to provide SecureBoot input? Check with PM.
$ProviderSpecificDetails.TargetVMSecurityProfileTargetVmsecurityType = $TargetSecurityType | ||
$ProviderSpecificDetails.TargetVMSecurityProfileIsTargetVmtpmEnabled = $true | ||
} elseif($HasTargetVMSecureBootEnabled) { | ||
throw "SecureBoot when security type is trusted launch virtual machine." |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Get the error message reviewed from PM.
@@ -639,6 +668,7 @@ public static int hashForArtifact(String artifact) | |||
} | |||
|
|||
Import-Module Az.Resources | |||
Import-Module Az.Compute |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Remove if not required.
Description
Checklist
CONTRIBUTING.md
and reviewed the following information:generation
branch.ChangeLog.md
file(s) appropriatelyChangeLog.md
file can be found atsrc/{{SERVICE}}/{{SERVICE}}/ChangeLog.md
## Upcoming Release
header in the past tense. Add changelog in description section if PR goes intogeneration
branch.ChangeLog.md
if no new release is required, such as fixing test case only.