-
Notifications
You must be signed in to change notification settings - Fork 2
Powershell Changes for Security Type #37
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
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.
| } | ||
|
|
||
| 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.mdand reviewed the following information:generationbranch.ChangeLog.mdfile(s) appropriatelyChangeLog.mdfile can be found atsrc/{{SERVICE}}/{{SERVICE}}/ChangeLog.md## Upcoming Releaseheader in the past tense. Add changelog in description section if PR goes intogenerationbranch.ChangeLog.mdif no new release is required, such as fixing test case only.