LoginSignup
0
0

More than 5 years have passed since last update.

IISで一括でサイトとアプリケーションプールを削除する

Last updated at Posted at 2018-09-13

Default Siteも消えます。

$appcmd = "C:\Windows\System32\inetsrv\appcmd.exe"
$sites = & $appcmd list site
foreach ($site in $sites){
    $site = $site.split("`"")[1] # sitename
    & $appcmd delete site $site
}

$apppools = & $appcmd list apppool
foreach ($apppool in $apppools){
    $apppool = $apppool.split("`"")[1] # apppool
    & $appcmd delete apppool $apppool
}

メモ:サイトに与えたユーザが消えない…。

0
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
0