asp.net - IIS 7.5 Powershell script - Management service & Configure Web Deploy Publishing -


i creating script automate iis install on server 2012,

having script near completed can't find information on following 2 topics: - management service - configure web deploy publishing

specifically within management service looking set ip automatically using pre-set parameter within script ,is possible? forums/articles have read have yet mention area within powershell

secondly within configure web deploy publishing, looking change default username, again using pre-set parameter within script.

if point me in right direction perfect.

thanks!

about iis management service, looked @ own server setup scripts few years old , not exclusively powershell:

it seems there 2 registry locations need change, here's part of script:

sc.exe config wmsvc start= delayed-auto reg.exe add hkey_local_machine\software\microsoft\webmanagement\server /v enableremotemanagement /t reg_dword /d 1 /f net start wmsvc 

in same registry key there reg_sz ipaddress can set.

there also: hklm:\system\currentcontrolset\services\http\parameters\sslbindinginfo\0.0.0.0:8172

you need have new key own ip, rather doing manually, should use netsh instead:

$thumb = (ls cert:\localmachine\my | where-object { $_.friendlyname -like "*wmsvc*" } | select-object -first 1).thumbprint $guid = [guid]::newguid()  & netsh http delete sslcert ipport=0.0.0.0:8172 & netsh http add sslcert ipport=192.168.10.10:8172 certhash=$thumb appid=`{$guid`} 

i haven't tested because never had change default 0.0.0.0, expect should work.


Comments

Popular posts from this blog

c++ - Difference between pre and post decrement in recursive function argument -

php - Nothing but 'run(); ' when browsing to my local project, how do I fix this? -

php - How can I echo out this array? -