
Serie · Instalando Podman en Windows 10 · Guía 3 de 4
Podman en Windows ejecuta los contenedores dentro de una máquina virtual Linux basada en WSL 2, llamada Podman Machine. Hasta que no la creas e inicias, el comando podman no tiene un motor al que hablarle.
En esta guía creas e inicias la máquina, compruebas el motor, controlas su inicio y detención, configuras Podman Desktop y haces tus primeras consultas con un contenedor de prueba.
Los nombres de equipo, versiones, identificadores y datos de las pantallas son de ejemplo: en tu equipo serán distintos.
Abrir PowerShell como administrador y comprobar el CLI
Abre PowerShell como administrador: pulsa Win + X y elige Windows PowerShell (administrador). Si Windows pide confirmar en Control de cuentas de usuario, acepta. Comprueba que la sesión tiene esos privilegios: Después confirma que el comando podman responde:
([Security.Principal.WindowsPrincipal][Security.Principal.WindowsIdentity]::GetCurrent()).IsInRole([Security.Principal.WindowsBuiltInRole]::Administrator) podman --version Get-Command podman | Select-Object Name, Version
PS C:\Windows\system32> ([Security.Principal.WindowsPrincipal][Security.Principal.WindowsIdentity]::GetCurrent()).IsInRole([Security.Principal.WindowsBuiltInRole]::Administrator)TruePS C:\Windows\system32> podman --versionpodman version 5.6.0PS C:\Windows\system32> Get-Command podman | Select-Object Name, Version Name Version---- -------podman.exe 5.6.0.0PS C:\Windows\system32>
podman no se reconoce, cierra PowerShell y ábrelo de nuevo, o repite la guía 2.Crear la máquina virtual de Podman
podman machine init descarga la imagen del sistema y la importa a WSL. Tarda unos minutos y se hace una sola vez:
podman machine init
PS C:\Windows\system32> podman machine initLooking up Podman Machine image at quay.io/podman/machine-os-wsl:5.6 to create VMGetting image source signaturesCopying blob 3d1f7a5b9c20 done |Copying config 44136fa355 done |Writing manifest to image destinationExtracting compressed file: podman-machine-default-amd64: doneImporting operating system into WSL (this may take a few minutes on a new WSL install)...Configuring system...Machine init completeTo start your machine run: podman machine startPS C:\Windows\system32>
podman-machine-default.Iniciar Podman Machine
Inicia la máquina y revisa su estado:
podman machine start podman machine list
PS C:\Windows\system32> podman machine startStarting machine "podman-machine-default"API forwarding listening on: npipe:////./pipe/docker_engineMachine "podman-machine-default" started successfullyPS C:\Windows\system32> podman machine listNAME VM TYPE CREATED LAST UP CPUS MEMORY DISK SIZEpodman-machine-default* wsl 2 minutes ago Currently running 6 2GiB 100GiBPS C:\Windows\system32>
Currently running indica que está en marcha.Comprobar el motor de contenedores
podman version muestra el cliente (Windows) y el servidor (Linux dentro de la máquina). Si aparecen los dos, el motor responde:
podman version
PS C:\Windows\system32> podman versionClient: Podman EngineVersion: 5.6.0API Version: 5.6.0Go Version: go1.24.6OS/Arch: windows/amd64 Server: Podman EngineVersion: 5.6.0API Version: 5.6.0Go Version: go1.24.6OS/Arch: linux/amd64PS C:\Windows\system32>
Server, la máquina no está iniciada: vuelve al paso 3.Configurar el inicio y detención de Podman
Detén la máquina cuando no la uses para liberar memoria y CPU, y vuelve a iniciarla cuando la necesites:
podman machine stop podman machine start
PS C:\Windows\system32> podman machine stopWaiting for VM to exit...Machine "podman-machine-default" stopped successfullyPS C:\Windows\system32> podman machine startStarting machine "podman-machine-default"Machine "podman-machine-default" started successfullyPS C:\Windows\system32>
Configuración de Podman Desktop
Podman Desktop es la interfaz gráfica. Confirma que Windows lo reconoce como aplicación instalada:
Get-StartApps | Where-Object Name -like *Podman* | Select-Object Name
PS C:\Windows\system32> Get-StartApps | Where-Object Name -like *Podman* | Select-Object Name Name----Podman DesktopPS C:\Windows\system32>
- Abre Podman Desktop desde el menú Inicio.
- En la pantalla de bienvenida acepta la configuración recomendada.
- Si pide permisos de administrador, acepta.
- Espera a que el panel muestre que Podman está en ejecución.
Verificar la conexión con Podman Engine
Podman Desktop y el CLI usan la misma conexión al motor. Lístala:
podman system connection list
PS C:\Windows\system32> podman system connection listName URI Default ReadWritepodman-machine-default ssh://user@127.0.0.1:52341/run/user/1000/podman/podman.sock true truepodman-machine-default-root ssh://root@127.0.0.1:52341/run/podman/podman.sock false truePS C:\Windows\system32>
Configurar los componentes adicionales
El asistente de Podman Desktop ofrece instalar Compose y kubectl. Puedes aceptarlos allí o instalar kubectl con Winget:
winget install -e --id Kubernetes.kubectl --accept-package-agreements --accept-source-agreements kubectl version --client
PS C:\Windows\system32> winget install -e --id Kubernetes.kubectl --accept-package-agreements --accept-source-agreementsFound Kubernetes CLI [Kubernetes.kubectl] Version 1.34.1This application is licensed to you by its owner.Microsoft is not responsible for, nor does it grant any licenses to, third-party packages.Downloading https://dl.k8s.io/release/v1.34.1/bin/windows/amd64/kubectl.exe ██████████████████████████████ 58.0 MB / 58.0 MBSuccessfully verified installer hashStarting package install...Successfully installedPS C:\Windows\system32> kubectl version --clientClient Version: v1.34.1Kustomize Version: v5.7.1PS C:\Windows\system32>
kubectl no se reconoce justo después de instalarlo.compose.yaml con podman compose. Instálalo desde el asistente de Podman Desktop si lo necesitas; no es obligatorio en esta serie.Configurar la interfaz gráfica
En Settings → Preferences de Podman Desktop eliges el tema (claro, oscuro o el del sistema), el inicio con Windows y si se abre minimizado. Comprueba que la aplicación está en ejecución:
Get-Process -Name *podman* | Select-Object ProcessName, Id
PS C:\Windows\system32> Get-Process -Name *podman* | Select-Object ProcessName, Id ProcessName Id----------- --Podman Desktop 8412PS C:\Windows\system32>
Descargar una imagen de prueba
hello-world es una imagen mínima pensada para probar que el motor funciona:
podman pull docker.io/library/hello-world
PS C:\Windows\system32> podman pull docker.io/library/hello-worldTrying to pull docker.io/library/hello-world:latest...Getting image source signaturesCopying blob 17eec7bbc9d7 done |Copying config 74cc54e27d done |Writing manifest to image destination74cc54e27dc41bb10dc4b2226072d469509f2f22f1a3ce74f4a59661a1d44602PS C:\Windows\system32>
Ejecutar el contenedor
Crea y ejecuta un contenedor a partir de la imagen:
podman run hello-world
PS C:\Windows\system32> podman run hello-world Hello from Docker!This message shows that your installation appears to be working correctly. For more examples and ideas, visit: https://docs.docker.com/get-started/PS C:\Windows\system32>
Consultar los contenedores
Lista todos los contenedores, incluidos los que ya terminaron (-a):
podman ps -a
PS C:\Windows\system32> podman ps -aCONTAINER ID IMAGE COMMAND CREATED STATUS PORTS NAMES3f1c2a9b7d4e docker.io/library/hello-world:latest /hello 8 seconds ago Exited (0) 8 seconds ago happy_eulerPS C:\Windows\system32>
Exited (0) significa que el contenedor terminó sin errores.Consultar las imágenes
Lista las imágenes guardadas en la máquina:
podman images
PS C:\Windows\system32> podman imagesREPOSITORY TAG IMAGE ID CREATED SIZEdocker.io/library/hello-world latest 74cc54e27dc4 9 months ago 10.1 kBPS C:\Windows\system32>
Consultar los volúmenes
Los volúmenes guardan datos fuera del contenedor. Lista los existentes:
podman volume ls
PS C:\Windows\system32> podman volume lsDRIVER VOLUME NAMEPS C:\Windows\system32>
Consultar las redes
Podman crea una red por defecto para los contenedores:
podman network ls
PS C:\Windows\system32> podman network lsNETWORK ID NAME DRIVER2f259bab93aa podman bridgePS C:\Windows\system32>
podman es la que usan los contenedores si no indicas otra.Todos los comandos
La secuencia completa de esta guía, en PowerShell abierto como administrador.
([Security.Principal.WindowsPrincipal][Security.Principal.WindowsIdentity]::GetCurrent()).IsInRole([Security.Principal.WindowsBuiltInRole]::Administrator) podman --version Get-Command podman | Select-Object Name, Version podman machine init podman machine start podman machine list podman version podman machine stop podman machine start Get-StartApps | Where-Object Name -like *Podman* | Select-Object Name podman system connection list winget install -e --id Kubernetes.kubectl --accept-package-agreements --accept-source-agreements kubectl version --client Get-Process -Name *podman* | Select-Object ProcessName, Id podman pull docker.io/library/hello-world podman run hello-world podman ps -a podman images podman volume ls podman network ls
Con la máquina configurada y un primer contenedor ejecutado, ya puedes publicar un servicio real. En la guía 4 levantamos un servidor NGINX y lo abrimos desde el navegador de Windows.