@SET /P A_ans=please type the Account for the Identity=
@SET /P P_ans=please type the password for the Identity=
powershell Expand-Archive "%~dp0Web.zip" -DestinationPath "%~dp0Web"
robocopy "%~dp0Web" "D:\temp" /E
REM add application pool
%WINDIR%\system32\inetsrv\appcmd.exe set config -section:system.applicationHost/applicationPools /+"[name='NewAppPool',autoStart='True',managedPipelineMode='Integrated']" /commit:apphost
%WINDIR%\system32\inetsrv\appcmd.exe set config /section:applicationPools /[name='NewAppPool'].processModel.identityType:SpecificUser /[name='NewAppPool'].processModel.userName:%A_ans% /[name='NewAppPool'].processModel.password:%P_ans%
REM add app
%WINDIR%\system32\inetsrv\appcmd.exe add app /site.name:"Default Web Site" /path:/NewWeb /physicalPath:"D:\temp\Web" /applicationPool:NewAppPool
沒有留言:
張貼留言