免互動安裝Podman、解除安裝,以及在部署工具中偵測安裝狀態所用的指令。只列出確定可用的指令:來自資訊清單,或是安裝程式技術的官方預設參數。
相關教學: 靜默安裝參數總整理:MSI、NSIS、Inno Setup · 用登錄檔或PowerShell解除安裝程式
使用winget
PowerShell
winget install --id RedHat.Podman -e --silent --accept-package-agreements --accept-source-agreementswinget upgrade --id RedHat.Podman -e --silentwinget uninstall --id RedHat.Podman -e --silent依安裝檔
64位元 · EXE(WiX Burn) · 所有使用者
靜默安裝
podman-installer-windows-amd64.exe /quiet /norestart解除安裝
msiexec /x {A1EC0C19-E860-4554-9787-72ECCE3E9ED7} /qn /norestart- MSI產品代碼
- {A1EC0C19-E860-4554-9787-72ECCE3E9ED7}
- 解除安裝登錄機碼
- HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\{A1EC0C19-E860-4554-9787-72ECCE3E9ED7}
- UpgradeCode
- {F3E1F40A-A791-49B7-9BC6-050975293353}
- 安裝資料夾
- %ProgramFiles%\RedHat\Podman
- DisplayVersion
- 5.8.10
ARM64 · EXE(WiX Burn) · 所有使用者
靜默安裝
podman-installer-windows-arm64.exe /quiet /norestart解除安裝
msiexec /x {96CE5B76-18C5-4ECE-8BE7-9431E39F1070} /qn /norestart- MSI產品代碼
- {96CE5B76-18C5-4ECE-8BE7-9431E39F1070}
- 解除安裝登錄機碼
- HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\{96CE5B76-18C5-4ECE-8BE7-9431E39F1070}
- UpgradeCode
- {F3E1F40A-A791-49B7-9BC6-050975293353}
- 安裝資料夾
- %ProgramFiles%\RedHat\Podman
- DisplayVersion
- 5.8.10
PowerShell:下載、驗證、安裝
下載官方檔案,驗證SHA256後靜默安裝。
install-podman.ps1
$url = 'https://github.com/podman-container-tools/podman/releases/download/v5.8.10/podman-installer-windows-amd64.exe'
$sha256 = '1D4AD41B58F8881C30272CD70E1C05570F272EF74338848C1B776C668C427E7A'
$file = Join-Path $env:TEMP 'podman-installer-windows-amd64.exe'
Invoke-WebRequest -Uri $url -OutFile $file -UseBasicParsing
if ((Get-FileHash $file -Algorithm SHA256).Hash -ne $sha256) { throw 'SHA256 mismatch' }
Start-Process -FilePath $file -ArgumentList '/quiet /norestart' -Wait install-podman.ps1
$url = 'https://github.com/podman-container-tools/podman/releases/download/v5.8.10/podman-installer-windows-arm64.exe'
$sha256 = '063063F660AB382B9710B45D7895FD02DE506326C7124C5D7B2650D8D44E14E3'
$file = Join-Path $env:TEMP 'podman-installer-windows-arm64.exe'
Invoke-WebRequest -Uri $url -OutFile $file -UseBasicParsing
if ((Get-FileHash $file -Algorithm SHA256).Hash -ne $sha256) { throw 'SHA256 mismatch' }
Start-Process -FilePath $file -ArgumentList '/quiet /norestart' -Wait