Open gbeifuss opened 4 years ago
Powershell 7 (and before it, Powershell 6) are based on .NET CORE, which doesn't deliver a compiler anymore in its base installation.
https://github.com/MScholtes/PS2EXE/issues/14#issuecomment-658747358
Thank you, have not yet had the time to get into that.
Also see this error in pwsh 7.x, but not in 5.1
Validation
-Attempt...................: 1
Certificates
-Status....................: ****Export-PfxCertificate: Cannot export non-exportable private key.
*****Get-Content: D:\PS\GenLeCertForNS.ps1:4772
Line |
4772 | … :ToBase64String($(Get-Content $CertificatePfxFullPath -AsByteStream))
| ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
| Cannot find path 'D:\ns_certs\LECRT-20230125-144135-aaa.domain.com\LECRT-20230125-144135-aaa.domain.com.pfx' because it does not exist.
Write-Error: Certificate completion failed. Exception Message: Exception calling "ToBase64String" with "1" argument(s): "Value cannot be null. (Parameter 'inArray')"
ADC - Cleanup
-Cleanup type..............: Full
-Cleanup...................: ** Completed
Write-Error: There were 1 errors during the request for CN: "aaa.domain.com"!
Finished with Errors! There were one or more errors, please check the log or rerun with the "-LogLevel Debug" option!
Running this script under PS 7 generates this error:
I launched PS 5.1 and everything completed successfully. I'm opening this request so that PS 7 compatibility can be introduced eventually.