public void ExecuteCommand() { ValidateParameters(); WriteObject(new ExtensionConfigurationInput { CertificateThumbprint = CertificateThumbprint, ThumbprintAlgorithm = ThumbprintAlgorithm, ProviderNameSpace = ExtensionNameSpace, Type = ExtensionType, PublicConfiguration = string.Format(PublicConfigurationXmlTemplate.ToString(), Credential.UserName, Expiration.ToString("yyyy-MM-dd")), PrivateConfiguration = string.Format(PrivateConfigurationXmlTemplate.ToString(), Credential.Password.ConvertToUnsecureString()), X509Certificate = X509Certificate, Roles = Role != null && Role.Any() ? Role.Select(r => new ExtensionRole(r)).ToList() : new ExtensionRole[] { new ExtensionRole() }.ToList() }); }
public void ExecuteCommand() { ValidateParameters(); WriteObject(new ExtensionConfigurationInput { CertificateThumbprint = CertificateThumbprint, ThumbprintAlgorithm = ThumbprintAlgorithm, ProviderNameSpace = ExtensionNameSpace, Type = ExtensionType, PublicConfiguration = string.Format(PublicConfigurationXmlTemplate.ToString(), ConnectionQualifiers, DefaultEndpointsProtocol, StorageAccountName, DiagnosticsConfiguration != null ? DiagnosticsConfiguration.InnerXml : ""), PrivateConfiguration = string.Format(PrivateConfigurationXmlTemplate.ToString(), StorageKey), X509Certificate = X509Certificate, Roles = Role != null && Role.Any() ? Role.Select(r => new ExtensionRole(r)).ToList() : new ExtensionRole[] { new ExtensionRole() }.ToList() }); }
public void ExecuteCommand() { ValidateParameters(); ExtensionConfigurationInput context = new ExtensionConfigurationInput { ProviderNameSpace = ExtensionNameSpace, Type = ExtensionType, CertificateThumbprint = CertificateThumbprint, ThumbprintAlgorithm = ThumbprintAlgorithm, X509Certificate = X509Certificate, PublicConfiguration = string.Format(PublicConfigurationXmlTemplate.ToString(), ConnectionQualifiers, DefaultEndpointsProtocol, StorageAccountName, DiagnosticsConfiguration != null ? DiagnosticsConfiguration.InnerXml : ""), PrivateConfiguration = string.Format(PrivateConfigurationXmlTemplate.ToString(), StorageKey), Roles = Role != null && Role.Any() ? Role.Select(r => new ExtensionRole(r)).ToList() : new ExtensionRole[] { new ExtensionRole() }.ToList() }; var extConfig = ExtensionManager.InstallExtension(context, Slot, Deployment.ExtensionConfiguration); ChangeDeployment(extConfig); }
public void ExecuteCommand() { ValidateParameters(); ExtensionConfigurationInput context = new ExtensionConfigurationInput { ProviderNameSpace = ExtensionNameSpace, Type = ExtensionType, CertificateThumbprint = CertificateThumbprint, ThumbprintAlgorithm = ThumbprintAlgorithm, X509Certificate = X509Certificate, PublicConfiguration = string.Format(PublicConfigurationXmlTemplate.ToString(), Credential.UserName, Expiration.ToString("yyyy-MM-dd")), PrivateConfiguration = string.Format(PrivateConfigurationXmlTemplate.ToString(), Credential.Password.ConvertToUnsecureString()), Roles = Role != null && Role.Any() ? Role.Select(r => new ExtensionRole(r)).ToList() : new ExtensionRole[] { new ExtensionRole() }.ToList() }; var extConfig = ExtensionManager.InstallExtension(context, Slot, Deployment.ExtensionConfiguration); ChangeDeployment(extConfig); }