自
Web Deploy 3.5以来,使用以下标志支持连接字符串的自动加密:-EnableRule:EncryptWebConfig.但是,运行它时:
"C:\Program Files\IIS\Microsoft Web Deploy V3\msdeploy.exe" -source:package='C:\[...]\MyApp.WebDeployPackage.zip' -dest:auto,includeAcls="False" -verb:sync -disableLink:AppPoolExtension -disableLink:ContentExtension -disableLink:CertificateExtension -setParamFile:"C:\[...]\MyApp.SetParameters.xml" -EnableRule:EncryptWebConfig -verbose
我明白了:
Error Code: ERROR_Failed_TO_ENCRYPT_WEB_CONFIG More Information: Failed to encrypt destination web.config: C:\[...]\Web.config. Learn more at: http://go.microsoft.com/fwlink/?LinkId=221672#ERROR_Failed_TO_ENCRYPT_WEB_CONFIG. Error: The given key was not present in the dictionary.
Learn more-link指向过时的文档,我似乎无法在线找到任何信息.